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

Improve support for IPNS double-hashed entries #41

Merged
merged 7 commits into from
Dec 13, 2024

Conversation

hsanjuan
Copy link
Collaborator

@hsanjuan hsanjuan commented Dec 11, 2024

Fixes #40. This ensures that double-hashed IPNS entries both in modern and legacy forms are correctly supported, including both:

  • /ipns/<domain>
  • /ipns/key

Before, only the modern form with /ipns/ was correctly supported for double-hashed entries.

Testcases have been added for all forms.

The double-hashing check code that was duplicated in several functions has been consolidated.

Fixes #40. This ensures that double-hashed IPNS entries both in modern and legacy
forms are correctly supported, including both:
  * /ipns/<domain>
  * /ipns/key

Before, only the modern form with /ipns/<domain> was correctly supported for
double-hashed entries.

Testcases have been added for all forms.
It was repeated in all check functions
@hsanjuan hsanjuan requested a review from lidel December 11, 2024 12:59
Copy link
Member

@lidel lidel left a comment

Choose a reason for hiding this comment

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

lgtm, small cosmetics inline, but feel free to merge + maybe also make a release and PR kubo and rainbow so we don't forget?

denylist.go Outdated Show resolved Hide resolved
denylist.go Outdated Show resolved Hide resolved
denylist.go Outdated Show resolved Hide resolved
denylist.go Outdated Show resolved Hide resolved
hsanjuan and others added 5 commits December 13, 2024 10:37
Co-authored-by: Marcin Rataj <lidel@lidel.org>
Co-authored-by: Marcin Rataj <lidel@lidel.org>
Co-authored-by: Marcin Rataj <lidel@lidel.org>
Co-authored-by: Marcin Rataj <lidel@lidel.org>
@hsanjuan hsanjuan merged commit db00015 into master Dec 13, 2024
6 checks passed
@hsanjuan hsanjuan deleted the fix/40-ipns-double-hashed branch December 13, 2024 09:55
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.

Support legacy double-hash entries for IPNS CIDs and DNSLink
2 participants