php8.5
Home/ Manual/ rnp / functions/ rnp_key_revoke

rnp_key_revoke

PHP function Edit on GitHub ✎

(PECL rnp >= 0.1.1)

Revoke a key or subkey by generating and adding revocation signature

Description

rnp_key_revoke(RnpFFI $ffi, string $key_fp, int $flags, [array $options]): bool

Note: you need to call rnp_save_keys() to write updated keyring(s) out.

Parameters

ffi

Ffi-description

key_fp

Key fingerprint.

flags

Currently must be 0.

options

An associative array with options.

KeyData typeDescription
"hash"stringSet hash algorithm used during signature calculation.
"code"stringCode reason for revocation code. Possible values: 'no', 'superseded', 'compromised', 'retired'. If not defined, then value 'no' will be used by default.
"reason"stringTextual representation of the reason for revocation.

Return Values

Returns true on successFalseforfailure.

Source: reference/rnp/functions/rnp-key-revoke.xml · from the official PHP manual (php/doc-en)