(mainly for fedora) '-s' gets a shell. Manual spot-testing only

also includes "use $USER if username not passed"
This commit is contained in:
Sitaram Chamarty 2012-04-03 09:44:43 +05:30
parent 81b503d2bd
commit ad77cef7de
2 changed files with 65 additions and 1 deletions

View file

@ -54,7 +54,7 @@ sub in_ssh {
my $ip;
( $ip = $ENV{SSH_CONNECTION} || '(no-IP)' ) =~ s/ .*//;
gl_log( 'ssh', "ARGV=" . join( ",", @ARGV ), "SOC=$ENV{SSH_ORIGINAL_COMMAND}", "FROM=$ip" );
gl_log( 'ssh', "ARGV=" . join( ",", @ARGV ), "SOC=" . ( $ENV{SSH_ORIGINAL_COMMAND} || ''), "FROM=$ip" );
$ENV{SSH_ORIGINAL_COMMAND} ||= '';
my $soc = $ENV{SSH_ORIGINAL_COMMAND};