soerenschneider / ssh-login-notification

Sends a notification when a login via SSH occurs

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Go Report Card

sends a notification (preferably) via telegram when a successful SSH login event occurred.

configuration

Create a config file in either /etc/default/sshnotification.json or $HOME/.sshnotification/sshnotification.json:

{
    "telegram_token": "your-super-secret-bot-token",
    "telegram_id": 123456789
}

Add the following line as the last line in /etc/pam.d/sshd:

session optional pam_exec.so /path/to/sshloginnotification

screenshot

About

Sends a notification when a login via SSH occurs

License:Apache License 2.0


Languages

Language:Go 95.2%Language:Makefile 3.5%Language:Dockerfile 1.4%