Skip to content

feat: implement RFC 6763 Section 4.3 escaping for instance names - #420

Merged
keepsimple1 merged 1 commit into
keepsimple1:mainfrom
pascal-audio:rcf6763_instance_name
Feb 6, 2026
Merged

keepsimple1 merged 1 commit into
keepsimple1:mainfrom
pascal-audio:rcf6763_instance_name

Conversation

@thibaut-pascal

Copy link
Copy Markdown
Contributor

Add proper escaping of dots and backslashes in DNS-SD instance names according to RFC 6763 Section 4.3:

  • '.' becomes '.'
  • '' becomes '\'

This ensures that literal dots in instance names (e.g., "My.Service") are not interpreted as DNS label separators when constructing the Service Instance Name.

Fixes improper handling of instance names containing dots or backslashes.

Add proper escaping of dots and backslashes in DNS-SD instance names
according to RFC 6763 Section 4.3:
- '.' becomes '\.'
- '\' becomes '\\'

This ensures that literal dots in instance names (e.g., "My.Service")
are not interpreted as DNS label separators when constructing the
Service Instance Name.

Fixes improper handling of instance names containing dots or backslashes.
Comment thread tests/mdns_test.rs Resolved
@keepsimple1

Copy link
Copy Markdown
Owner

The description section seems to be missing backslash in these:

  • . becomes \.
  • \ becomes \\

I think it's because of Markdown syntax, and should use ``, not '' for them.

@keepsimple1 keepsimple1 left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Thanks for your PR! LGTM, only a couple of minor comments inline.

Comment thread src/service_info.rs Resolved
Comment thread src/dns_parser.rs Resolved
Comment thread src/service_info.rs Resolved
@keepsimple1 keepsimple1 added the enhancement New feature or request label Jan 25, 2026
@keepsimple1

Copy link
Copy Markdown
Owner

Another small thing: could you please explicitly refer to the issue number in this PR description?

@keepsimple1 keepsimple1 left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Overall LGTM, so I will merge this before it's getting too old ;-)

For reference, this is to fix issue #418 .

@keepsimple1
keepsimple1 merged commit 3481b94 into keepsimple1:main Feb 6, 2026
keepsimple1 added a commit that referenced this pull request Feb 6, 2026
Update comments per unresolved comments in PR #420.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants