test: use old hsmsecret format for hardcoded onion message
What changed, and why it matters
This is a tiny test-only change. It updates one test to use an older format for a secret key so that a pre-recorded test message still works. There is no change to production code and no security issue.
No action needed; this is a test-only adjustment.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The commit modifies tests/test_connection.py, changing test_injectonionmessage to create nodes with opts={‘old_hsmsecret’: True}. The hardcoded onion message in the test was generated under the old hsmsecret format, so the test needs that option to remain deterministic. No production code is touched.
Changed components
tests/test_connection.pyInspect captured patch +2 / −1
diff --git a/tests/test_connection.py b/tests/test_connection.py
index 6bfe59e4..1d3ea7d1 100644
--- a/tests/test_connection.py
+++ b/tests/test_connection.py
@@ -4455,7 +4455,8 @@ def test_connect_transient_pending(node_factory, bitcoind, executor):
def test_injectonionmessage(node_factory):
"""Test for injectonionmessage API"""
- l1, l2 = node_factory.line_graph(2)
+ # Hardcoded onion message was created with old hsmsecret format
+ l1, l2 = node_factory.line_graph(2, opts={'old_hsmsecret': True})
# This is deterministic, so the onion message created by fetchinvoice can be replayed here
# manually
Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.