Skip to content
Snippets Groups Projects
Commit aa3ffa06 authored by Bert Palm's avatar Bert Palm :bug:
Browse files

Merge branch 'storeSSHkey' into 'main'

store encrypted ssh key in DB

See merge request !263
parents 7f1e8d04 01a48755
No related branches found
No related tags found
1 merge request!263store encrypted ssh key in DB
Pipeline #492898 passed
......@@ -46,9 +46,6 @@ def prepare_data_by_version(data: dict[str, Any]) -> dict[str, Any]:
parser.setdefault("name", "no-parser-name") # missing
elif data["version"] == 5:
# tsm-frontend/GL71
if d := data.get("external_sftp"):
d["private_key"] = "no-key-in-message-version-4" # always None
if d := data.get("mqtt"):
d.pop("uri", None) # unused
if d := data.get("database"):
......
......@@ -336,7 +336,7 @@ def upsert_table_ext_sftp(conn: Connection, values: dict, extftp_id) -> int:
# "password": thing.ext_sftp_password or None
# "sync_interval": thing.ext_sftp_sync_interval,
# "public_key": thing.ext_sftp_public_key,
# "private_key": None,
# "private_key": encrypted private ssh key or "" (empty string),
v = values.copy()
id_ = _upsert(
conn,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment