[Rpm-maint] [rpm-software-management/rpm] OpenPGP: Function `pgpParsePkts` supports only "PGP PUBLIC KEY BLOCK" block, "PGP SIGNATURE" is needed (Issue #2512)
Jaroslav Rohel
notifications at github.com
Fri May 19 11:55:31 UTC 2023
@mlschroe
In this case, sequoia is fine. But the internal implementation is incomplete. But in my opinion, there was no pressure to complete the support. We used GpgMe instead of this API.
Details:
The `pgpReadPkts` function returns the `pgpArmor` enum, which since its creation in 2001, contains an entry for the signature `PGPARMOR_SIGNATURE` (and other entries). And the function is described: "Parse armored OpenPGP packets from a file." And it returns "type of armor found".
In fact, it only parses one type `PGPARMOR_PUBKEY`.
```
/** \ingroup rpmpgp
* Parse armored OpenPGP packets from a file.
* @param fn file name
* @param[out] pkt dearmored OpenPGP packet(s) (malloced)
* @param[out] pktlen dearmored OpenPGP packet(s) length in bytes
* @return type of armor found
*/
pgpArmor pgpReadPkts(const char * fn, uint8_t ** pkt, size_t * pktlen);
```
```
PGPARMOR_MESSAGE = 1, /*!< MESSAGE */
PGPARMOR_PUBKEY = 2, /*!< PUBLIC KEY BLOCK */
PGPARMOR_SIGNATURE = 3, /*!< SIGNATURE */
PGPARMOR_SIGNED_MESSAGE = 4, /*!< SIGNED MESSAGE */
PGPARMOR_FILE = 5, /*!< ARMORED FILE */
PGPARMOR_PRIVKEY = 6, /*!< PRIVATE KEY BLOCK */
PGPARMOR_SECKEY = 7 /*!< SECRET KEY BLOCK */
```
--
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/issues/2512#issuecomment-1554461685
You are receiving this because you are subscribed to this thread.
Message ID: <rpm-software-management/rpm/issues/2512/1554461685 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20230519/6254fb9d/attachment.html>
More information about the Rpm-maint
mailing list