Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix handling of empty user input in pinentry module
As it turns out, the pinentry program responds slightly differently to a request to enter a password/PIN when the user enters one vs. when he/she just continues, leaving the input empty, as is illustrated here: When the user enters 'hello': > $ gpg-connect-agent 'GET_PASSPHRASE --data cacheid errormsg prompt description' '/bye' > D hello > OK When the user enters nothing: > $ gpg-connect-agent 'GET_PASSPHRASE --data cacheid errormsg prompt description' '/bye' > OK So far we always expected a two line response, with the first line containing the 'D ' prefix, which prevents us from handling empty input properly. This change fixes this shortcoming by adding a case for it. Fixes #176
- Loading branch information