Internal
Public Access
Start Milestone 4 interactive SSH terminal and host-key flow
This commit is contained in:
@@ -32,7 +32,7 @@ void bindProfileFields(QSqlQuery& query, const Profile& profile)
|
||||
query.addBindValue(profile.authMode.trimmed());
|
||||
query.addBindValue(profile.privateKeyPath.trimmed());
|
||||
query.addBindValue(profile.knownHostsPolicy.trimmed().isEmpty()
|
||||
? QStringLiteral("Strict")
|
||||
? QStringLiteral("Ask")
|
||||
: profile.knownHostsPolicy.trimmed());
|
||||
}
|
||||
|
||||
@@ -49,7 +49,7 @@ Profile profileFromQuery(const QSqlQuery& query)
|
||||
profile.privateKeyPath = query.value(7).toString();
|
||||
profile.knownHostsPolicy = query.value(8).toString();
|
||||
if (profile.knownHostsPolicy.isEmpty()) {
|
||||
profile.knownHostsPolicy = QStringLiteral("Strict");
|
||||
profile.knownHostsPolicy = QStringLiteral("Ask");
|
||||
}
|
||||
return profile;
|
||||
}
|
||||
@@ -253,7 +253,7 @@ bool ProfileRepository::initializeDatabase()
|
||||
"protocol TEXT NOT NULL DEFAULT 'SSH',"
|
||||
"auth_mode TEXT NOT NULL DEFAULT 'Password',"
|
||||
"private_key_path TEXT NOT NULL DEFAULT '',"
|
||||
"known_hosts_policy TEXT NOT NULL DEFAULT 'Strict'"
|
||||
"known_hosts_policy TEXT NOT NULL DEFAULT 'Ask'"
|
||||
")"));
|
||||
|
||||
if (!created) {
|
||||
@@ -299,7 +299,7 @@ bool ProfileRepository::ensureProfileSchema() const
|
||||
{QStringLiteral("protocol"), QStringLiteral("ALTER TABLE profiles ADD COLUMN protocol TEXT NOT NULL DEFAULT 'SSH'")},
|
||||
{QStringLiteral("auth_mode"), QStringLiteral("ALTER TABLE profiles ADD COLUMN auth_mode TEXT NOT NULL DEFAULT 'Password'")},
|
||||
{QStringLiteral("private_key_path"), QStringLiteral("ALTER TABLE profiles ADD COLUMN private_key_path TEXT NOT NULL DEFAULT ''")},
|
||||
{QStringLiteral("known_hosts_policy"), QStringLiteral("ALTER TABLE profiles ADD COLUMN known_hosts_policy TEXT NOT NULL DEFAULT 'Strict'")}};
|
||||
{QStringLiteral("known_hosts_policy"), QStringLiteral("ALTER TABLE profiles ADD COLUMN known_hosts_policy TEXT NOT NULL DEFAULT 'Ask'")}};
|
||||
|
||||
for (const ColumnDef& column : required) {
|
||||
if (columns.contains(column.name)) {
|
||||
|
||||
Reference in New Issue
Block a user