jbeverly / pam_ssh_agent_auth

Moving pam_ssh_agent_auth to github as primary development location
Other
99 stars 29 forks source link

Add PAM_RUSER format specificier #7

Open msantos opened 7 years ago

msantos commented 7 years ago

Add a new "%r" format specifier to represent the PAM remote user:

auth sufficient pam_ssh_agent_auth.so file=/etc/keys/%r

This change allows programs, like su, that set RUSER to the origin user and USER to the destination user, to name the key according to the user calling the program:

# auser -> root
/etc/keys/%r # equivalent to /etc/keys/auser
/etc/keys/%u # equivalent to /etc/keys/root
msantos commented 5 years ago

specificier -> specifier