SSH-AUTHORIZEDKEYS-COMMAND(1)

NAME
ssh-authorizedkeys-command - meta-command to get a users public key for authentication with openssh-server

SYNOPSIS
ssh-authorizedkeys-command USER

DESCRIPTION

ssh-authorizedkeys-command executes the user configured command in /etc/default/ssh-authorizedkeys-command.

The configured command in /etc/default/ssh-authorizedkeys-command can be manually edited, by calling dpkg-reconfigure open-infrastructure-openssh-tools (if available), or by editing /etc/default/ssh-authorizedkeys-command directly.

The configured command can use first argument given to ssh-authorizedkeys-command which is the user that the login is performed for by openssh. The command needs to return a valid public key (e.g. 'ssh-ed22519 [...]') which then gets used by openssh.

EXAMPLE

When using LDAP with the sshPublicKey attribute, a valid command could look like this:
$(ldapsearch -LLL -x -o ldif-wrap=no -H ldaps://ldap.example.org:636 -b dc=example uid="${1}" 'sshPublicKey' |
awk '/^sshPublicKey: / { print $2, $3 }')

FILES

The following files are used:

/etc/ssh/sshd_config.d/ssh-authorizedkeys-command:
    openssh-server configuration to enable ssh-authorizedkeys-command.

/etc/default/ssh-authorizedkeys-command
    configuration file that contains the user configured command to be executed.

/usr/bin/ssh-authorizedkeys-command:
    script that executes the user configured command to return the users public keys.

SEE ALSO
sshd_config(5)

HOMEPAGE

More information about service-tools and the Open Infrastructure project can be found on the homepage ( <https://open-infrastructure.net> ).

CONTACT

Bug reports, feature requests, help, patches, support and everything else are welcome on the Open Infrastructure Software Mailing List < <software@lists.open-infrastructure.net> >.

Debian specific bugs can also be reported in the Debian Bug Tracking System ( <https://bugs.debian.org> ).

AUTHORS

service-tools were written by Daniel Baumann < <daniel.baumann@open-infrastructure.net> > and others.