snapcraft validate and sign-build are inconsistent when there are multiple keys
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Snapcraft |
New
|
Undecided
|
Unassigned |
Bug Description
When there are multiple signing keys, snapcraft sign-build shows a wizard-like text and lets you enter a number to select the key you want. snapcraft validate instead uses the default key.
I'm not sure what's the right behaviour, but they should be consistent.
$ snapcraft list-keys
Name SHA3-384 fingerprint
* default pvqbQVTvSgeMIuU
* test 5bsceVZqUkv01S4
$ snapcraft validate u1test20161026 ubuntu-core=4
Getting details for ubuntu-core
Signing validation ubuntu-core=4
You need a passphrase to unlock the secret key for
user: "default"
4096-bit RSA key, ID D017FEB3, created 2016-01-01
$ snapcraft sign-build *.snap
Select a key:
Number Name SHA3-384 fingerprint
1 default pvqbQVTvSgeMIuU
2 test 5bsceVZqUkv01S4
Key number: 1
You need a passphrase to unlock the secret key for
user: "default"
4096-bit RSA key, ID D017FEB3, created 2016-01-01