comparison svr-chansession.c @ 1882:2839daa507b3

set envvar SSH_PUBKEYINFO if authstate.pubkey_info contains information
author HansH111 <hans@atbas.org>
date Sun, 13 Mar 2022 17:38:38 +0000
parents bfa92efd814b
children 284c3837891c
comparison
equal deleted inserted replaced
1881:d39cfedaf015 1882:2839daa507b3
1028 } 1028 }
1029 1029
1030 if (chansess->original_command) { 1030 if (chansess->original_command) {
1031 addnewvar("SSH_ORIGINAL_COMMAND", chansess->original_command); 1031 addnewvar("SSH_ORIGINAL_COMMAND", chansess->original_command);
1032 } 1032 }
1033 if (ses.authstate.pubkey_info != NULL) {
1034 addnewvar("SSH_PUBKEYINFO", ses.authstate.pubkey_info);
1035 }
1033 1036
1034 /* change directory */ 1037 /* change directory */
1035 if (chdir(ses.authstate.pw_dir) < 0) { 1038 if (chdir(ses.authstate.pw_dir) < 0) {
1036 int e = errno; 1039 int e = errno;
1037 if (chdir("/") < 0) { 1040 if (chdir("/") < 0) {