Skip to content

Conversation

@manu0401
Copy link

No description provided.

Comment on lines +2138 to +2140
if (token == NULL)
return ARC_STAT_INVALID;

Copy link
Contributor

Choose a reason for hiding this comment

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

This cannot happen. There will always be an initial token, because the case where the string is empty returns before this call.

Comment on lines +2148 to +2149
if (token == NULL)
return ARC_STAT_INVALID;
Copy link
Contributor

Choose a reason for hiding this comment

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

This was already fixed in #83 ; the develop branch (while itself having some major unaddressed issues) is a fair bit ahead of the default branch.

You might also be interested in https://github.com/flowerysong/OpenARC/, which incorporates fixes for all known issues and adds some additional features.

Copy link
Contributor

Choose a reason for hiding this comment

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

@manu0401 Since you've pushed this patch to NetBSD, I should maybe be a bit more strident: this change is incorrect. If no second token is found the code should default to simple canonicalization, as is done in the already existing fix that I pointed you at. See the definition of c in https://www.rfc-editor.org/rfc/rfc6376#section-3.5

Copy link
Author

Choose a reason for hiding this comment

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

Thank you for the reminder. I note I have to look at it again.

netbsd-srcmastr pushed a commit to NetBSD/pkgsrc that referenced this pull request Nov 18, 2025
@manu0401 manu0401 changed the title Cope with invalid input without rashing Cope with invalid input without crashing Nov 29, 2025
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.

2 participants