Skip to content

Ensure random relay selection with fixed ohttp-keys config#1390

Open
benalleng wants to merge 1 commit intopayjoin:masterfrom
benalleng:randomize-relay-selection-with-key-config
Open

Ensure random relay selection with fixed ohttp-keys config#1390
benalleng wants to merge 1 commit intopayjoin:masterfrom
benalleng:randomize-relay-selection-with-key-config

Conversation

@benalleng
Copy link
Collaborator

Closes #1384

This fixes a bug whereby the relay selection was skipped if the config set a fixed value for the ohttp-keys.

Pull Request Checklist

Please confirm the following before requesting review:

This fixes a bug whereby the relay selection was skipped if the config
set a fixed value for the ohttp-keys.
@coveralls
Copy link
Collaborator

Pull Request Test Coverage Report for Build 22781790124

Details

  • 2 of 2 (100.0%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 82.497%

Totals Coverage Status
Change from base Build 22741440695: 0.0%
Covered Lines: 10638
Relevant Lines: 12895

💛 - Coveralls

@bc1cindy
Copy link
Contributor

bc1cindy commented Mar 6, 2026

tested ACK 6097008

all tests passing locally

the fix is minimal and reuses fetch_ohttp_keys randomization, that also preserves the e2e relay validation, even when keys are hardcoded in config

Copy link
Collaborator

@spacebear21 spacebear21 left a comment

Choose a reason for hiding this comment

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

utACK 6097008, though this makes me wonder if there is any benefit at all of having ohttp_keys in the cli config? We could just return the ValidatedOhttpKeys from fetch_ohttp_keys for the same effect, making the if/else block irrelevant?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Ohttp-relay selection should still be randomized even when ohttp-keys is hard coded in the config.

4 participants