table of contents
| RPMSIGN(1) | General Commands Manual | RPMSIGN(1) |
NAME¶
rpmsign - RPM Package Signing
SYNOPSIS¶
rpmsign {--addsign|--resign} [options] [sign-options] PACKAGE_FILE ...
rpmsign --delsign [options] PACKAGE_FILE ...
rpmsign --delfilesign [options] PACKAGE_FILE ...
DESCRIPTION¶
rpmsign is used to manipulate digital OpenPGP signatures on rpm package files.
To create a signature rpmsign needs to verify the package's checksum. As a result V4 packages with MD5/SHA1 checksums cannot be signed in FIPS mode.
OPERATIONS¶
--addsign
--resign
--delsign
--delfilesign
ARGUMENTS¶
PACKAGE_FILE
OPTIONS¶
See rpm-common(8) for the options common to all rpm executables.
SIGN OPTIONS¶
--certpath CERT
--fskpath KEY
--key-id KEYID
--rpmv3
Has no effect when signing V6 packages.
--rpmv4
V4 compatibility signatures are only ever added if the signing algorithm is one of those known to V4: RSA, EcDSA, EdDSA (and original DSA). Only one V4 signature can be present in a package, so this is added only on the first --addsign with a V4 compatible algorithm, and ignored otherwise.
Has no effect when signing V4 packages.
--rpmv6
This generally always succeeds as there can be arbitrary number of V6 signatures on a package. A V3/V4 compatibility signatures are added usign the same logic as --rpmv4 on a V6 package.
Has no effect when signing V6 packages.
--signfiles
--signverity
--verityalgo ALG
CONFIGURATION¶
In order to sign packages, you need to create your own OpenPGP key pair (aka certificate) and configure rpm(8) to use it. The following macros are available:
%_openpgp_sign_id
%_openpgp_sign
Implementation specific macros:
%_gpg_path
%_gpg_name
%_sq_path
EXAMPLES¶
For example, to configure rpm to sign with Sequoia PGP using a key with fingerprint of 7B36C3EE0CCE86EDBC3EFF2685B274E29F798E08 you would include
%_openpgp_sign sq %_openpgp_signer 7B36C3EE0CCE86EDBC3EFF2685B274E29F798E08
in a macro configuration file, typically ~/.config/rpm/macros. See Macro Configuration in rpm-common(8) for more details.
rpmsign --addsign hello-2.0-1.x64_rpm
rpmsign --resign --key-id 771b18d3d7baa28734333c424344591e1964c5fc hello-2.0-1.x64_rpm
rpmsign --delsign --delfilesign hello-2.0-1.x64_rpm
EXIT STATUS¶
On success, 0 is returned, a non-zero failure code otherwise.
SEE ALSO¶
popt(3), rpm(8), rpm-common(8), rpmkeys(8), rpmbuild(1)
rpmsign --help - as rpm supports customizing the options via popt aliases it's impossible to guarantee that what's described in the manual matches what's available.
| 2025-11-07 | RPM 6.0.0 |