Skip to content

add trusted-origins cli argument - #6319

Merged
code-asher merged 5 commits into
coder:mainfrom
alexthillen:main
Jul 19, 2023
Merged

add trusted-origins cli argument#6319
code-asher merged 5 commits into
coder:mainfrom
alexthillen:main

Conversation

@alexthillen

Copy link
Copy Markdown
Contributor

Fixes#6064

@alexthillen
alexthillen requested a review from a team as a code ownerJuly 10, 2023 12:36
@code-asher

code-asher commented Jul 10, 2023

Copy link
Copy Markdown
Member

Thanks for the patch! Could we add a --trusted-proxy flag instead? Then if someone is dealing with a misconfigured proxy that cannot be fixed they can use --trusted-proxy 127.0.0.1 or whatever address their proxy is giving them.

@code-asher

Copy link
Copy Markdown
Member

Or maybe --trusted-origin could be better, not sure.

@alexthillen

Copy link
Copy Markdown
ContributorAuthor

Thanks for getting back to me. Added --trusted-origins flag instead.

@alexthillenalexthillen changed the title add disable-authenticate-origin flagadd trusted-origins cli argumentJul 11, 2023

@code-ashercode-asher left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks, this is great! The * is a nice touch too.

@code-asher

Copy link
Copy Markdown
Member

Ah right we will need to update the unit test as well.

@alexthillen

Copy link
Copy Markdown
ContributorAuthor

Thanks for the feedback!
Updated the unit tests accordingly. They are passing now.

@codecov

codecovBot commented Jul 19, 2023

Copy link
Copy Markdown

Codecov Report

Merging #6319 (5cfc0e3) into main (5c19962) will decrease coverage by 0.02%.
The diff coverage is 66.66%.

Additional details and impacted files

Impacted file tree graph

@@ Coverage Diff @@## main #6319 +/- ##
==========================================
- Coverage 73.67% 73.66% -0.02% 
==========================================
Files 31 31 Lines 1869 1872 +3 Branches 401 403 +2 ==========================================
+ Hits 1377 1379 +2 - Misses 415 416 +1 
Partials 77 77 
Impacted FilesCoverage Δ
src/node/cli.ts90.80% <ø> (ø)
src/node/http.ts70.71% <66.66%> (-0.09%)⬇️

Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 070a5a3...5cfc0e3. Read the comment docs.

@code-asher
code-asher merged commit 93e60f7 into coder:mainJul 19, 2023
@code-asher

Copy link
Copy Markdown
Member

Thanks again!

yiliang114 pushed a commit to yiliang114/code-server that referenced this pull request Jan 23, 2025
Sign up for freeto 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.

[Bug]: error Forbidden HttpError: Forbidden

2 participants

@alexthillen@code-asher