If Environment variable PIV_PIN is set, the PIN is read from the environment rather then Prompting the user.
On macOS this would allow us to:
$ export PIV_PIN=$( /usr/bin/osascript -e 'Tell application "System Events" to display dialog "Enter PIN:" with hidden answer default answer ""' -e 'text returned of result')
$ cat $KEYFILE | pivy-box key unlock testme2
$ unset PIV_PIN
If Environment variable PIV_PIN is set, the PIN is read from the environment rather then Prompting the user.
On macOS this would allow us to: $ export PIV_PIN=$( /usr/bin/osascript -e 'Tell application "System Events" to display dialog "Enter PIN:" with hidden answer default answer ""' -e 'text returned of result') $ cat $KEYFILE | pivy-box key unlock testme2
$ unset PIV_PIN