I am pretty baffled by the fact that anyone relies on output parsing for verifying a signature. Is this common? I suspect that we will see more vulnerabilities like this in that case. If one relies on a command line tool for doing this, wouldn't it be safer to have a command line switch which lets the program exit with 0 if the verification succeeds and another value if it fails? Has anyone an elif what the fix would…
The GPL license might be part of why this is done; running GPG in a separate process avoids infecting your code with its license.
SigSpoof: Spoofing signatures in GnuPG, Enigmail, GPGTools and python-gnupg
11–20 of 20 posts
Re: SigSpoof: Spoofing signatures in GnuPG, Enigmail, GPGTools and python-gnupg
#12Earlier quoted context omitted.
As already suggested output parsing here is necessary due to multiple possible outcomes. I just want to add that if you have to parse command output, enforce the output format as well as you can. The --verbose bug really shouldn’t have happened.
As I am mainly a Java guy it has burnt into me to never rely on .toString() output for code flow. It seems to me that this is somewhat similar (or has the Unix world a gentlemans agreement that output has an API contract). I'd never touch anything where I couldn't enforce (preferably typed) output to rely on especially in a security context. I think I have already seen command line tools which can return structured c…
Re: SigSpoof: Spoofing signatures in GnuPG, Enigmail, GPGTools and python-gnupg
#13I am pretty baffled by the fact that anyone relies on output parsing for verifying a signature. Is this common? I suspect that we will see more vulnerabilities like this in that case. If one relies on a command line tool for doing this, wouldn't it be safer to have a command line switch which lets the program exit with 0 if the verification succeeds and another value if it fails? Has anyone an elif what the fix would…
Re: SigSpoof: Spoofing signatures in GnuPG, Enigmail, GPGTools and python-gnupg
#14Earlier quoted context omitted.
As already suggested output parsing here is necessary due to multiple possible outcomes. I just want to add that if you have to parse command output, enforce the output format as well as you can. The --verbose bug really shouldn’t have happened.
As I am mainly a Java guy it has burnt into me to never rely on .toString() output for code flow. It seems to me that this is somewhat similar (or has the Unix world a gentlemans agreement that output has an API contract). I'd never touch anything where I couldn't enforce (preferably typed) output to rely on especially in a security context. I think I have already seen command line tools which can return structured c…
That happens. It doesn't need to a standard format like that however. Some command like tools add a porcelain option that produces output for scripting (ie no ansi color codes, easy to parse, etc). That works well too.
Re: SigSpoof: Spoofing signatures in GnuPG, Enigmail, GPGTools and python-gnupg
#15I am pretty baffled by the fact that anyone relies on output parsing for verifying a signature. Is this common? I suspect that we will see more vulnerabilities like this in that case. If one relies on a command line tool for doing this, wouldn't it be safer to have a command line switch which lets the program exit with 0 if the verification succeeds and another value if it fails? Has anyone an elif what the fix would…
As already suggested output parsing here is necessary due to multiple possible outcomes. I just want to add that if you have to parse command output, enforce the output format as well as you can. The --verbose bug really shouldn’t have happened.
Re: SigSpoof: Spoofing signatures in GnuPG, Enigmail, GPGTools and python-gnupg
#16Re: SigSpoof: Spoofing signatures in GnuPG, Enigmail, GPGTools and python-gnupg
#17I am pretty baffled by the fact that anyone relies on output parsing for verifying a signature. Is this common? I suspect that we will see more vulnerabilities like this in that case. If one relies on a command line tool for doing this, wouldn't it be safer to have a command line switch which lets the program exit with 0 if the verification succeeds and another value if it fails? Has anyone an elif what the fix would…
Re: SigSpoof: Spoofing signatures in GnuPG, Enigmail, GPGTools and python-gnupg
#18I am pretty baffled by the fact that anyone relies on output parsing for verifying a signature. Is this common? I suspect that we will see more vulnerabilities like this in that case. If one relies on a command line tool for doing this, wouldn't it be safer to have a command line switch which lets the program exit with 0 if the verification succeeds and another value if it fails? Has anyone an elif what the fix would…
Elif?
Re: SigSpoof: Spoofing signatures in GnuPG, Enigmail, GPGTools and python-gnupg
#19Am I being naive here?
Re: SigSpoof: Spoofing signatures in GnuPG, Enigmail, GPGTools and python-gnupg
#20Earlier quoted context omitted.
The GPL license might be part of why this is done; running GPG in a separate process avoids infecting your code with its license.
This may or may not be true. Please ask your lawyer.