AGWA / git-crypt

Transparent file encryption in git
https://www.agwa.name/projects/git-crypt/
GNU General Public License v3.0
8.1k stars 472 forks source link

gpgsm support #305

Closed btdonovan closed 5 months ago

btdonovan commented 5 months ago

gpgsm is a component of gpg2 that allows gpg style operations using x509 certificates.

It lacks the --fixed-list-mode option but that is the default output for --with-colons.

It uses certificates instead of public keys and those certificates are prefixed with crt: instead of pub:.

In gpg_get_uid we wrap the --fixed-list-mode option push in an if so it doesn't get added if gpg_get_executable() is gpgsm.

In gpg_lookup_key we add an if else to set is_pubkey to true for crt lines.

These changes enable git-crypt to make use of gpgsm for users that need to use x509 encryption.

resolves #306