Skip to content
Commit 949e7cbc authored by Sergey Ponomarev's avatar Sergey Ponomarev Committed by Paul Donald
Browse files

luci-app-sshtunnel: ssh_keys: list keys without a corresponding .pub



The private keys doesn't have any extension so the only way to clearly say that this file is a key is a presence of the corresponding .pub file.
Most of time key files have a prefix id_ e.g. id_rsa etc.

The dropbearkey generates a key without a corresponding .pub file e.g. id_dropbearkey.

So we need to detect a key files by both .pub file or id_ prefix.
Key files without the id_ prefix won't be listed, sorry.

Signed-off-by: default avatarSergey Ponomarev <stokito@gmail.com>
parent 3933633d
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment