Commit Graph

2 Commits

Author SHA1 Message Date
Michael Schroeder 0c52a522e9 Support pubkey merging in the keyring code
The new rpmPubkeyMerge function will merge the certificate
material of two pubkeys describing the same key.

This is currently only implemented in the "legcay" backend.
2024-06-14 08:54:44 +03:00
Panu Matilainen 725ca51695 Allow building rpm without OpenPGP support
For bootstrapping purposes, having rpm depend on Rust is painful, but
directing people to unmaintained crypto code as an alternative is
hair-raising. As a middle ground, let rpm be built without OpenPGP
support at all, which at least gives you a functional rpm and rpm-build
even if you can't sign or verify signatures.

Achieving this is a moderately complex dance which can't meaningfully
be split into multiple commits because everything is interconnected:

Add a new WITH_SEQUOIA option to control use of Sequoia, on by default.
When Sequoia is disabled, default to a newly added dummy PGP implementation
instead which just returns error on everything. And finally, if the
older WITH_INTERNAL_OPENPGP is enabled, use the old PGP implementation.

As the intent is to cut out rpmpgp_legacy to a separate repository,
sanity requires that we also split the openssl/libgcrypt code at the
digest/signature fault line. It's not ideal, but the alternative of
having unused crypto code on which an external component depends on
is just not sustainable. This way, the signature side of things is
quite neatly cut off with the PGP stuff. The diff looks big but there
are no code/functional changes in the libgcrypt/openssl split.
2024-03-20 12:42:33 +02:00