summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2021-10-31 16:49:04 +0100
committerAnton Khirnov <anton@khirnov.net>2021-10-31 16:49:04 +0100
commita994a08a2901fb8c8c541053e8b968d6f7d78bd4 (patch)
tree3b457bed34db6cdf2f688a9dcd919d8703ef645f
parent82c708cb0ed45809f7b1d64d29b7b8c539219cc2 (diff)
Xsession: show an error if adding a FIDO key fails
-rw-r--r--dotfiles/Xsession3
1 files changed, 2 insertions, 1 deletions
diff --git a/dotfiles/Xsession b/dotfiles/Xsession
index ab17699..72065a5 100644
--- a/dotfiles/Xsession
+++ b/dotfiles/Xsession
@@ -17,7 +17,8 @@ run_if_exists parcellite
# on FIDO HW key add/remove, update the SSH agent
udev_match --subsystem=hidraw --match=ACTION=remove --match=ID_FIDO_TOKEN=1 ssh_sk_clean &
-udev_match --subsystem=hidraw --match=ACTION=add --match=ID_FIDO_TOKEN=1 "ssh-add -K" &
+udev_match --subsystem=hidraw --match=ACTION=add --match=ID_FIDO_TOKEN=1 \
+ "ssh-add -K || notify-send -u critical 'Error adding FIDO2 keys to SSH agent' 'Wrong PIN?'" &
# source the machine-local configuration
[ -r "$HOME/.config/Xsession_local" ] && . "$HOME/.config/Xsession_local"