René's URL Explorer Experiment


Title: fix: fail service resolution fast when nsec denies the needed address types by bdraco · Pull Request #1827 · python-zeroconf/python-zeroconf · GitHub

Open Graph Title: fix: fail service resolution fast when nsec denies the needed address types by bdraco · Pull Request #1827 · python-zeroconf/python-zeroconf

X Title: fix: fail service resolution fast when nsec denies the needed address types by bdraco · Pull Request #1827 · python-zeroconf/python-zeroconf

Description: Summary Follow up to #1825. When an NSEC record at the host name denies every address type a request still needs, async_request now fails fast instead of waiting out the full timeout; RFC 6762 §6.1 makes such an NSEC an authoritative nonexistence assertion. Details NSEC records at the server name now set per family denial flags; the bitmap lists the types that exist, so an absent bit denies that family. A new _is_denied check derives the wanted families from _query_record_types, so AddressResolverIPv4, AddressResolverIPv6, AddressResolver, and plain ServiceInfo all share one definition with no overrides. Denials are re derived on every cache load, so a host that later gains the record resolves normally on the next request. _load_from_cache also consults a cached NSEC at the server name when the request is still incomplete, covering the case where the other address family already resolved. NSEC records are processed last within each update batch, so a denial for an SRV target learned later in the same response is not lost to wire ordering; when an SRV update changes the target host, denials are reset and re derived from the new host's cached NSEC. Each NSEC is treated as an authoritative snapshot, so a newer bitmap that includes a previously denied family clears the stale denial. Foreign NSEC records still bail on the key checks before any processing; the hot dispatch path is unchanged for other record types, confirmed against the Cython annotate output. Test plan poetry run pytest tests passes, 480 passed new tests cover both single family resolvers, a denial arriving mid request, partial denial with the other family present, denial reset on a later request, the all types denied case for plain ServiceInfo, NSEC and SRV arriving in either order in one batch, denial reset when the SRV target moves, a newer bitmap clearing a stale denial, and NSECs for unrelated names being ignored Cython annotate comparison against master shows untouched hot functions unchanged; the new cost sits only on NSEC record lines and cold paths verified on a live network; an IPv6 resolve of a real v4 only device now fails in about 120ms instead of the 10s timeout, while IPv4, either family, and dual stack resolves are unaffected

Open Graph Description: Summary Follow up to #1825. When an NSEC record at the host name denies every address type a request still needs, async_request now fails fast instead of waiting out the full timeout; RFC 6762 §6.1...

X Description: Summary Follow up to #1825. When an NSEC record at the host name denies every address type a request still needs, async_request now fails fast instead of waiting out the full timeout; RFC 6762 §6.1...

Opengraph URL: https://github.com/python-zeroconf/python-zeroconf/pull/1827

X: @github

direct link

Domain: github.com

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:c1cf6b7d-9d50-8022-aba6-879da303c9e7
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-id9B66:220721:39A6E0:4F74C0:6B008BF0
html-safe-nonce0f5e33f487538644432d6bf4a4b75c8babf3938cc12e5956c61614e45e531046
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5QjY2OjIyMDcyMTozOUE2RTA6NEY3NEMwOjZCMDA4QkYwIiwidmlzaXRvcl9pZCI6IjQxODI2MjE4NDk2NjM4Njc4ODgiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmacf63ec647b01d83d84f394d9cd910d80016027c622d1fc7dd7a0adef71e277b85
hovercard-subject-tagpull_request:4387032672
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/files
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/python-zeroconf/python-zeroconf/pull/1827/files
twitter:imagehttps://avatars.githubusercontent.com/u/663432?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/663432?s=400&v=4
og:image:altSummary Follow up to #1825. When an NSEC record at the host name denies every address type a request still needs, async_request now fails fast instead of waiting out the full timeout; RFC 6762 §6.1...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
Nonec710a5cb5c47be60abfe6e8410436d409906979dbed614ef09f29c60f5535b08
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/python-zeroconf/python-zeroconf git https://github.com/python-zeroconf/python-zeroconf.git
octolytics-dimension-user_id120192235
octolytics-dimension-user_loginpython-zeroconf
octolytics-dimension-repository_id21548731
octolytics-dimension-repository_nwopython-zeroconf/python-zeroconf
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id21548731
octolytics-dimension-repository_network_root_nwopython-zeroconf/python-zeroconf
turbo-body-classeslogged-out env-production page-responsive full-width
disable-turbotrue
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
releasebe616a2a6ec1c609d6e002896dff5352d5c5f28b
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/python-zeroconf/python-zeroconf/pull/1827/files#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython-zeroconf%2Fpython-zeroconf%2Fpull%2F1827%2Ffiles
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython-zeroconf%2Fpython-zeroconf%2Fpull%2F1827%2Ffiles
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=python-zeroconf%2Fpython-zeroconf
Reloadhttps://github.com/python-zeroconf/python-zeroconf/pull/1827/files
Reloadhttps://github.com/python-zeroconf/python-zeroconf/pull/1827/files
Reloadhttps://github.com/python-zeroconf/python-zeroconf/pull/1827/files
python-zeroconfhttps://github.com/python-zeroconf
python-zeroconfhttps://github.com/python-zeroconf/python-zeroconf
Codehttps://github.com/python-zeroconf/python-zeroconf
Issues50 (50)https://github.com/python-zeroconf/python-zeroconf/issues
Pull requests16 (16)https://github.com/python-zeroconf/python-zeroconf/pulls
Discussionshttps://github.com/python-zeroconf/python-zeroconf/discussions
Actionshttps://github.com/python-zeroconf/python-zeroconf/actions
Projectshttps://github.com/python-zeroconf/python-zeroconf/projects
Wikihttps://github.com/python-zeroconf/python-zeroconf/wiki
Security and quality5 (5)https://github.com/python-zeroconf/python-zeroconf/security
Insightshttps://github.com/python-zeroconf/python-zeroconf/insights
Sign up for GitHub https://github.com/signup?return_to=%2Fpython-zeroconf%2Fpython-zeroconf%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://github.com/login?return_to=%2Fpython-zeroconf%2Fpython-zeroconf%2Fissues%2Fnew%2Fchoose
bdracohttps://github.com/bdraco
masterhttps://github.com/python-zeroconf/python-zeroconf/tree/master
nsec_address_denialhttps://github.com/python-zeroconf/python-zeroconf/tree/nsec_address_denial
Conversation 11 https://github.com/python-zeroconf/python-zeroconf/pull/1827
Commits 2 https://github.com/python-zeroconf/python-zeroconf/pull/1827/commits
Checks 36 https://github.com/python-zeroconf/python-zeroconf/pull/1827/checks
Files changed https://github.com/python-zeroconf/python-zeroconf/pull/1827/files
Please reload this pagehttps://github.com/python-zeroconf/python-zeroconf/pull/1827/files
fix: fail service resolution fast when nsec denies the needed address types https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#top
Show all changes 2 commits https://github.com/python-zeroconf/python-zeroconf/pull/1827/files
ac3afd2 fix: fail service resolution fast when nsec denies the needed address… bdraco Aug 28, 2026 https://github.com/python-zeroconf/python-zeroconf/pull/1827/commits/ac3afd2da608dbb402b3ce328c5cbd7435010044
0ffc2ed address review nits: fix stale cython.locals and trim test docstring bdraco Aug 28, 2026 https://github.com/python-zeroconf/python-zeroconf/pull/1827/commits/0ffc2ed7f5e6782a37a52d589344649362404c20
Clear filters https://github.com/python-zeroconf/python-zeroconf/pull/1827/files
Please reload this pagehttps://github.com/python-zeroconf/python-zeroconf/pull/1827/files
Please reload this pagehttps://github.com/python-zeroconf/python-zeroconf/pull/1827/files
info.pxd https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-58f57e2931f03dd0eeb142a137a62905a24fd9b73dff07672becad788b17a5ba
info.py https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-1d9147eb9baf7756138dfa891475affa18bbe55d565efca5b039f301ab045fa4
test_info.py https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-60efc1967b54eee765e08a9d13b2acd7ebe19a0908157973d68cf847ec849205
src/zeroconf/_services/info.pxdhttps://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-58f57e2931f03dd0eeb142a137a62905a24fd9b73dff07672becad788b17a5ba
View file https://github.com/python-zeroconf/python-zeroconf/blob/0ffc2ed7f5e6782a37a52d589344649362404c20/src/zeroconf/_services/info.pxd
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/python-zeroconf/python-zeroconf/pull/1827/{{ revealButtonHref }}
https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-58f57e2931f03dd0eeb142a137a62905a24fd9b73dff07672becad788b17a5ba
https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-58f57e2931f03dd0eeb142a137a62905a24fd9b73dff07672becad788b17a5ba
https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-58f57e2931f03dd0eeb142a137a62905a24fd9b73dff07672becad788b17a5ba
https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-58f57e2931f03dd0eeb142a137a62905a24fd9b73dff07672becad788b17a5ba
https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-58f57e2931f03dd0eeb142a137a62905a24fd9b73dff07672becad788b17a5ba
src/zeroconf/_services/info.pyhttps://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-1d9147eb9baf7756138dfa891475affa18bbe55d565efca5b039f301ab045fa4
View file https://github.com/python-zeroconf/python-zeroconf/blob/0ffc2ed7f5e6782a37a52d589344649362404c20/src/zeroconf/_services/info.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/python-zeroconf/python-zeroconf/pull/1827/{{ revealButtonHref }}
https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-1d9147eb9baf7756138dfa891475affa18bbe55d565efca5b039f301ab045fa4
https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-1d9147eb9baf7756138dfa891475affa18bbe55d565efca5b039f301ab045fa4
https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-1d9147eb9baf7756138dfa891475affa18bbe55d565efca5b039f301ab045fa4
https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-1d9147eb9baf7756138dfa891475affa18bbe55d565efca5b039f301ab045fa4
https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-1d9147eb9baf7756138dfa891475affa18bbe55d565efca5b039f301ab045fa4
https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-1d9147eb9baf7756138dfa891475affa18bbe55d565efca5b039f301ab045fa4
https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-1d9147eb9baf7756138dfa891475affa18bbe55d565efca5b039f301ab045fa4
Please reload this pagehttps://github.com/python-zeroconf/python-zeroconf/pull/1827/files
https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-1d9147eb9baf7756138dfa891475affa18bbe55d565efca5b039f301ab045fa4
Please reload this pagehttps://github.com/python-zeroconf/python-zeroconf/pull/1827/files
https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-1d9147eb9baf7756138dfa891475affa18bbe55d565efca5b039f301ab045fa4
https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-1d9147eb9baf7756138dfa891475affa18bbe55d565efca5b039f301ab045fa4
https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-1d9147eb9baf7756138dfa891475affa18bbe55d565efca5b039f301ab045fa4
https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-1d9147eb9baf7756138dfa891475affa18bbe55d565efca5b039f301ab045fa4
https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-1d9147eb9baf7756138dfa891475affa18bbe55d565efca5b039f301ab045fa4
https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-1d9147eb9baf7756138dfa891475affa18bbe55d565efca5b039f301ab045fa4
https://github.com/python-zeroconf/python-zeroconf/pull/1827/files#diff-1d9147eb9baf7756138dfa891475affa18bbe55d565efca5b039f301ab045fa4
Please reload this pagehttps://github.com/python-zeroconf/python-zeroconf/pull/1827/files
Please reload this pagehttps://github.com/python-zeroconf/python-zeroconf/pull/1827/files
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.