rnp icon indicating copy to clipboard operation
rnp copied to clipboard

Support Photo IDs (User Attribute Packet (Tag 17)/The Image Attribute Subpacket)

Open antonsviridenko opened this issue 3 years ago • 1 comments

Description

PGP specification has additional optional way to represent and identify key holder by adding his photo to the key data.

The Image Attribute subpacket is used to encode an image, presumably (but not required to be) that of the key owner.

GnuPG supports these Photo IDs, can add and display these photos (using external image viewer). It would be nice if RNP could do the same. Now rnpkeys is only able to show presence of photo ID packet by printing (photo) string in the key description.

Steps to Reproduce

  1. Generate the new key using gpg
  2. Edit newly generated key by typing gpg --edit-key KEYID
  3. type addphoto, specify path to some JPEG image, press y then quit then again y
  4. export the key from gnupg, import into the rnp keystore
pub   3072/RSA b548769515f29bc2 2022-12-06 [SC] [EXPIRES 2024-12-05]
      ad5f866d9eab8e061074f3d9b548769515f29bc2
uid           photo id test key <photoid@test>
uid           (photo)
sub   3072/RSA 82185fc7972aee8d 2022-12-06 [E] [EXPIRES 2024-12-05]
      8c65135dfb3bac5e17928a1482185fc7972aee8d

Expected Behavior

rnpkeys CLI could be extended with additional commands & options like --edit-key --add-photo , --showphoto KEYID.

antonsviridenko avatar Dec 06 '22 19:12 antonsviridenko

There were some discussion in openpgp mailing list (cannot locate it now) about deprecating user attribute, so at least this one is not of high priority.

ni4 avatar Dec 07 '22 09:12 ni4