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

Add UnparseablePacket to properly deal with key blocks that include malformed/unsupported packets #1522

Merged
merged 4 commits into from May 24, 2022

Conversation

larabr
Copy link
Collaborator

@larabr larabr commented May 23, 2022

Fix #1420 : when parsing errors are being ignored, packets that fail to parse are now included in the resulting packet list as UnparseablePackets . This way, when parsing keys that contain unparsable (sub)key, we avoid associating the following non-key packets to the wrong key entity.

On serialization, UnparseablePackets are also included by writing their raw packet body as it was read.

@larabr larabr requested a review from twiss May 23, 2022 12:21
Copy link
Member

@twiss twiss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, except one nitpick below

openpgp.d.ts Outdated Show resolved Hide resolved
@larabr larabr requested a review from twiss May 24, 2022 17:28
@larabr larabr changed the title Add UnparsablePacket to properly deal with key blocks that include malformed/unsupported packets Add UnparseablePacket to properly deal with key blocks that include malformed/unsupported packets May 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Unexpected parsing result when reading a key block that includes some unparsable key packets
2 participants