pinentry-dmenu (363B)
1 #!/bin/sh 2 3 printf "OK Pleased to meet you\n" 4 5 # shellcheck disable=SC2162 6 while read stdin; do 7 command="$(printf "$stdin\n" | tr '[:lower:]' '[:upper:]')" 8 if [ "$command" = "BYE" ] ; then 9 break 10 elif [ "$command" = "GETPIN" ] ; then 11 printf "D $(DISPLAY=:0 pinentry-dmenu-core -P -p "Passphrase:")\n" 12 printf "OK\n" 13 else 14 printf "OK\n" 15 fi 16 done 17 18 return 0