Skip to content

fix: parsedn not handling attributes with equal char in value#425

Merged
cpuschma merged 1 commit intogo-ldap:masterfrom
james-d-elliott:fix-parsedn-double-equals
Mar 27, 2023
Merged

fix: parsedn not handling attributes with equal char in value#425
cpuschma merged 1 commit intogo-ldap:masterfrom
james-d-elliott:fix-parsedn-double-equals

Conversation

@james-d-elliott
Copy link
Contributor

This fixes an issue where attributes with equal chars in the value would not be correctly parsed. As we only set the AttributeTypeAndValue's Type field once and we reset it on the step to the next AttributeTypeAndValue we can assume if this field already has a value that it should not consider it the type/value separator.

Fixes #416

This fixes an issue where attributes with equal chars in the value would not be correctly parsed. As we only set the AttributeTypeAndValue's Type field once and we reset it on the step to the next AttributeTypeAndValue we can assume if this field already has a value that it should not consider it the type/value separator.

Fixes go-ldap#416
@james-d-elliott
Copy link
Contributor Author

Please note the test was designed using TDD. i.e. it fails before the fix, and passes after the fix.

@cpuschma
Copy link
Member

Thank you for your PR! 👍

@cpuschma cpuschma merged commit 32d292e into go-ldap:master Mar 27, 2023
@james-d-elliott james-d-elliott deleted the fix-parsedn-double-equals branch March 27, 2023 18:57
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.

ParseDN does not correctly handle base64 encoded values

2 participants