blob: 22edc241be21e81bac9634a5bf1a54d3ca2d7128 (
plain)
1
2
3
4
5
6
7
8
9
10
11
|
#!/bin/sh
# remove all FIDO keys from the SSH agent
fido_keys=$(ssh-add -L|grep '^sk-')
if [ -n "${fido_keys}" ]; then
output=$(echo "${fido_keys}" | ssh-add -d /dev/stdin 2>&1)
if [ $? -eq 0 ]; then
notify-send -u low "FIDO keys cleaned"
else
notify-send -u critical "FIDO keys not cleaned" "${output}"
fi
fi
|