keybase / keybase/client

pgp verify should echo the content just verified if its not detached

Open
#1,413 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
9.2k
Forks
1.3k
Avg merge
12h 58m
Merged PRs (30d)
56

Description

A common workflow is bootstraping some secure channel over an insecure channel. This may work like:

  • Hey my OTR signature is "PAULS_SIGNATURE". Here I signed it. : echo "PAULS_SIGNATURE" | keybase pgp sign
  • Other party takes the blob and runs "keybase pgp verify" on it. They see: "▶ NOTICE Signature verified. Signed by pearce 7 seconds ago (2015-11-29 12:56:27 -0800 PST)." and thinks everything is good.

Now the problem here is you have no idea WHAT you just verified. An attacker in control of the insecure medium could replay a different message that would also verify OK. With the existing flow the only way to do this is to both 'keybase pgp decrypt' and 'keybase pgp verify' separately. That's not ideal because the message could be swapped via the insecure medium in between those actions. The verify -> echoing of what was verified should be atomic WRT the content loaded (it should be read in from stdin / disk once).

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing the keybase pgp verify command and how it reads content from stdin or disk. Determine where verified non-detached content can be emitted from the same read, and consider the work complete when verification reports success together with the exact content verified without a second read.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
cli, cryptography, security
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.