Allow SSH keys on multiple accounts
Update validation and duplicate checks to scope key uniqueness per account, and clarify the console error message. Document cross-account key assignment and authentication testing.
This commit is contained in:
+1
-1
@@ -357,7 +357,7 @@ static int add_key(const char *username)
|
||||
secure_wipe(line, sizeof(line));
|
||||
if (error != ESP_OK) {
|
||||
if (error == USER_DATABASE_ERR_DUPLICATE_SSH_KEY) {
|
||||
printf("Could not add SSH key: that public key is already assigned to an account.\n");
|
||||
printf("Could not add SSH key: that public key is already assigned to this account.\n");
|
||||
} else if (error == ESP_ERR_NO_MEM) {
|
||||
printf("Could not add SSH key: the account already has %u keys.\n",
|
||||
USER_DATABASE_MAX_SSH_KEYS_PER_USER);
|
||||
|
||||
Reference in New Issue
Block a user