12 ms·
This is done via profile.d and can be circumvented by executing anything else than a login shell: ssh host /bin/sh -i Better would be enabling PAM via sshd_
by blueflow 3y ago
This is done via profile.d and can be circumvented by executing anything else than a login shell:
ssh host /bin/sh -i
Better would be enabling PAM via sshd_config and generating the message from there.
- e12e 3y agoSee eg this for inspiration: https://askubuntu.com/questions/179889/how-do-i-set-up-an-email-alert-when-a-ssh-login-is-successful https://askubuntu.com/questions/179889/how-do-i-set-up-an-em...
- Ajunne 3y agoOr to actually get a login shell, but without loading the profile: > ssh host -t "bash --noprofile"
- deleted 3y ago[deleted]
- zokier 3y agothere is also sshd ForceCommand that could be used here