-
-
Save lx78WyY0J5/3d061547ac21e19c1f5d93b0f2d1e452 to your computer and use it in GitHub Desktop.
Send discord webhook at ssh login (every user)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #/etc/ssh/sshrc | |
| ip=`echo $SSH_CONNECTION | cut -d " " -f 1` | |
| curl --silent -v \ | |
| -H "Content-Type: application/json" \ | |
| -X POST \ | |
| -d "{\"content\":\"new login $USER $ip \"}" \ | |
| https://discordapp.com/api/webhooks/_WEBOOK_URL > /dev/null 2>&1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment