mirror of
https://github.com/shazow/ssh-chat.git
synced 2025-04-19 18:27:41 +03:00
add and document --keynames options
This commit is contained in:
parent
233898fd13
commit
aba5ca03fb
@ -38,6 +38,7 @@ type Options struct {
|
||||
Version bool `long:"version" description:"Print version and exit."`
|
||||
Allowlist string `long:"allowlist" description:"Optional file of public keys who are allowed to connect."`
|
||||
Whitelist string `long:"whitelist" dexcription:"Old name for allowlist option"`
|
||||
Keynames bool `long:"keynames" description:"Reserve usernames by appending them (after a space) to their keys in the admin or allowlist files."`
|
||||
Passphrase string `long:"unsafe-passphrase" description:"Require an interactive passphrase to connect. Allowlist feature is more secure."`
|
||||
}
|
||||
|
||||
@ -157,6 +158,8 @@ func main() {
|
||||
}
|
||||
auth.SetAllowlistMode(options.Allowlist != "")
|
||||
|
||||
auth.SetKeynamesMode(options.Keynames)
|
||||
|
||||
if options.Motd != "" {
|
||||
host.GetMOTD = func() (string, error) {
|
||||
motd, err := ioutil.ReadFile(options.Motd)
|
||||
|
Loading…
x
Reference in New Issue
Block a user