2 suggestions
Earlier concerns neither republished nor resolved: 1 minor finding. See the Run archive for their assessments.
Optional improvements
[suggestion] · Quoted authentication retains an avoidable escaping dependency
The new escaping is correct, but sending the password as hex would avoid the order-dependent replacements and keep password bytes out of the line-based command syntax.
Location: src/torcontrol.cpp:696 (head).
Details and suggested fix
Use "AUTHENTICATE " + HexStr(torpassword) instead of the two replacements and quoted argument. The control specification permits an unquoted hex encoding of the same password specifically to avoid escaping issues. This file already uses hex for SAFECOOKIE, and HexStr accepts character spans. Besides removing the ordering dependency, hex would handle an LF supplied through argv, which Command currently sends raw and therefore splits the command line. That limitation predates this PR, concerns the operator's own setting, and cannot arise within a single bitcoin.conf value because configuration parsing splits on LF. HASHEDPASSWORD acceptance of hex rests here on the specification, not inspected Tor implementations; the reported live test covered only the quoted form. Switching would also require updating the new exact-line assertion and the nearby password-format comment.
[suggestion] · Backslash-workaround configurations need upgrade guidance
Operators who doubled backslashes in -torpassword as a workaround can lose their automatic onion service after upgrading; no affected configuration has been identified.
Location: src/torcontrol.cpp:696 (head).
Details and suggested fix
Previously, only quotes were escaped, so Tor decoded doubled backslashes in the configured value to single backslashes. Configuration parsing does not unescape them. This change correctly sends the configured text literally, but an unchanged workaround value now supplies a different password to HASHEDPASSWORD authentication. If Tor rejects it, auth_cb logs tor: Authentication failed and never requests ADD_ONION. Add a release note explaining that backslashes are now literal and operators should remove any compensating doubling, using the clear-text password described in doc/tor.md. This is compatibility guidance for the corrected behavior, not a request to retain the old decoding.
Earlier concerns
Earlier reports raised these, with the titles and severities shown there. This review neither republished nor resolved them.
- [minor]: Exercise the successful hashed-password flow in the mock