Limit ssh key lifetime to 12h in SSH sessions

This commit is contained in:
lachtan obecny
2026-10-22 10:59:34 +02:00
parent b3026487f0
commit 9630d412af
3 changed files with 19 additions and 1 deletions
+5
View File
@@ -156,3 +156,8 @@ function true_false() {
function is_wsl() {
grep -q -i wsl /proc/version
}
function is_ssh_session() {
# sshd sets SSH_CONNECTION only in sessions opened over SSH
[[ -n "${SSH_CONNECTION:-}" ]]
}