#!/bin/sh # remove all FIDO keys from the SSH agent fido_keys=$(ssh-add -L|grep '^sk-') if [ -n "${fido_keys}" ]; then echo "${fido_keys}" | ssh-add -d /dev/stdin fi