mirror of
https://github.com/acedanger/shell.git
synced 2025-12-06 01:10:12 -08:00
16 lines
363 B
Bash
Executable File
16 lines
363 B
Bash
Executable File
#!/bin/bash
|
|
|
|
#
|
|
# This script is referenced in `/etc/pam.d/sshd`
|
|
# - at the end of the `sshd` file, add
|
|
# `session optional pam_exec.so /home/acedanger/shell/ssh-login.sh`
|
|
#
|
|
|
|
if [ "${PAM_TYPE}" = "open_session" ]; then
|
|
curl \
|
|
-H prio:high \
|
|
-H tags:warning \
|
|
-d "SSH login: ${PAM_USER} from ${PAM_RHOST}" \
|
|
https://notify.peterwood.rocks/lab
|
|
fi
|