mirror of
https://github.com/bitcoin/bitcoin
synced 2026-12-04 09:38:38 +00:00
netaddress: make .onion suffix check case-insensitive #36636
Labels
No labels
Android
Backport
Block storage
Brainstorming
Bug
Build system
CI failed
Consensus
Data corruption
Descriptors
Docs
DrahtBot Guix build requested
Feature
Fuzzing
GUI
Good First Review
IPC
Insufficient Review
Kernel
Linux/Unix
Mempool
Mining
Needs Backport (31.x)
Needs Backport (32.x)
Needs Benchmark
Needs Conceptual Review
Needs backport (30.x)
Needs rebase
Needs release note
Net
P2P
PSBT
Privacy
Private Broadcast
Questions and Help
RPC/REST/ZMQ
Refactoring
Resource usage
Review club
Scripts and tools
Settings
TX fees and policy
Tests
Tracking Issue
UTXO Db and Indexes
Up for grabs
Upstream
Utils/log/libs
Validation
Waiting for author
Wallet
Windows
good first issue
interfaces
macOS
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
bitcoin/bitcoin!36636
Loading…
Reference in a new issue
No description provided.
Delete branch "onion-check"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Makes the suffix/TLD check case-insensitive when parsing
.onionaddresses, as is already done for I2P hostnames. With the current code, a name like<addr>.ONIONwill not be parsed as a Tor address, and will instead fall through to regular hostname resolution.The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.
External sites
Reviews
See the guideline and AI policy for information on the review process.
If your review is incorrectly listed, please copy-paste
<!--meta-tag:bot-skip-->into the comment that the bot should ignore.Base:
2b5b6fe231ff45a09d9e24411e4420d51ed45cabHead:
0574f096abf0cfe75501542efe1787679340d3d3I found no actionable issues in this static review.
Full review report
ACK
0574f096abShow Signature
vasild's public key is on openpgp.org
ACK
0574f096abBuilt and ran net_tests, netbase_tests, and base32_tests successfully. Confirmed the new test fails with the parent’s netaddress.cpp.
ACK 0574f09
One non-blocking nit
ToLower(addr.substr(...))creates a temporarystd::string(though 6 chars fits within SSO).Using
CaseInsensitiveEqual(addr.substr(addr.size() - suffix.size()), suffix)fromutil/strencodings.havoids the temporary string entirely.It would be nice to use that here (and similarly in SetI2P()) for consistency,
tested ACK
0574f096absuccessfully built and tested on: Windows
10/MSVC19.51.36257/x86_64. changes LGTM and the intent is pragmaticACK
0574f096ab