Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: improve rpc.skip-auth #3152

Merged
merged 3 commits into from
Feb 6, 2024
Merged

fix: improve rpc.skip-auth #3152

merged 3 commits into from
Feb 6, 2024

Conversation

distractedm1nd
Copy link
Collaborator

@distractedm1nd distractedm1nd commented Jan 31, 2024

In the current skip-auth implementation, there was an issue: Authentication could be skipped, but it still required the Authentication header to be set (it just wouldn't check it).

This PR improves the devex by removing this requirement. I missed it the first time because I tested by using the CLI, which always sets the header regardless of what you pass. This came up while implementing eigerco/lumina#210, since the wasm client cannot set headers.

I also think the solution is cleaner than the original.

api/rpc/server.go Outdated Show resolved Hide resolved
@codecov-commenter
Copy link

Codecov Report

Attention: 9 lines in your changes are missing coverage. Please review.

Comparison is base (625cdf3) 51.68% compared to head (b24a706) 51.76%.

Files Patch % Lines
nodebuilder/rpc/constructors.go 0.00% 9 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3152      +/-   ##
==========================================
+ Coverage   51.68%   51.76%   +0.07%     
==========================================
  Files         178      178              
  Lines       11284    11284              
==========================================
+ Hits         5832     5841       +9     
+ Misses       4951     4938      -13     
- Partials      501      505       +4     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@distractedm1nd distractedm1nd enabled auto-merge (squash) February 1, 2024 19:37
@ramin ramin self-requested a review February 5, 2024 12:32
@distractedm1nd distractedm1nd merged commit e55e1c8 into main Feb 6, 2024
22 of 23 checks passed
@distractedm1nd distractedm1nd deleted the skipauth branch February 6, 2024 11:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:rpc kind:fix Attached to bug-fixing PRs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants