7 ms·
In the extended example it does actually use the SSH_ORIGINAL_COMMAND, will update the simple version too
by moomerman 15y ago
In the extended example it does actually use the SSH_ORIGINAL_COMMAND, will update the simple version too
- pedrocr 15y agoIn the extended example you're falling back to exec(SHELL) if SSH_ORIGINAL_COMMAND doesn't exist. Does sshd not set that to the login shell if no command is specified by the client?
- moomerman 15y agoSSH_ORIGINAL_COMMAND isn't in the ENV at all if no command was passed through
- pedrocr 15y agoRight, that was what I asked in my other post. I assumed sshd would fill in the login shell there if nothing was passed as that is effectively what is being called but it seems not. I see you're doing exec(SHELL) to fix that.