Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Check that all OpenPGP signatures are a single signature packet #2109

Closed
DemiMarie opened this issue Jun 27, 2022 · 6 comments
Closed

Check that all OpenPGP signatures are a single signature packet #2109

DemiMarie opened this issue Jun 27, 2022 · 6 comments
Assignees
Labels
crypto Signatures, keys, hashes and their verification

Comments

@DemiMarie
Copy link
Contributor

This is already implemented for the internal backend, but I am not sure if it is done by the Sequoia backend. For consistency, RPM should enforce this in all backends. The amount of code needed for this is very small.

I am willing to make a PR.

@nwalfield
Copy link
Contributor

You're probably right that this is only a couple of lines of code. The check needs to be added to rpm-sequoia. The test case needs to be added to rpm. If you create a test case for rpm, I'll add the code to rpm-sequoia (or merge a PR).

@nwalfield
Copy link
Contributor

There was some talk about supporting multiple signatures in issue #189 . So, I'd prefer an ack that this is correct behavior from @pmatilai before working on this.

@pmatilai
Copy link
Member

I think @DemiMarie is referring to this: 5ff8676
I don't know whether Sequoia allows that in the first place or not.

Issue #189 is about supporting multiple independent signatures on a package, not related.

@nwalfield
Copy link
Contributor

Looking at rpm-sequoia's code, it should reject multiple signatures. (A unit test would be good to confirm this and be useful for any future OpenPGP backend.)

@DemiMarie
Copy link
Contributor Author

I think @DemiMarie is referring to this: 5ff8676
I don't know whether Sequoia allows that in the first place or not.

This is correct. I was actually going to suggest enforcing this somewhere in RPM’s C code, so that all backends behave consistently. In particular, any backend based on GnuPG would need such a check badly.

Looking at rpm-sequoia's code, it should reject multiple signatures. (A unit test would be good to confirm this and be useful for any future OpenPGP backend.)

I will look at that when I get the time.

@pmatilai pmatilai added the crypto Signatures, keys, hashes and their verification label Sep 14, 2023
@pmatilai pmatilai self-assigned this Nov 29, 2023
@pmatilai
Copy link
Member

What's considered rpm-level C code no longer knows about such packet level details, backends will need to deal with RFC compliancy on their own.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
crypto Signatures, keys, hashes and their verification
Projects
None yet
Development

No branches or pull requests

3 participants