Skip to content

Mirror Origin header back in CORS response #760

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

matthias-ccri
Copy link

Use corser's origins option to handle the access-control-allow-origin header. Passing a true function will make corser mirror the Origin header like we want.

I was not able to run the tests because my port 8080 is not available. I tried to make the tests configurable but I couldn't get the cors.test.js server to use the right port with the httpServer.listen() calls. Hopefully the tests pass, but if they don't, I'll need some help debugging/rewriting the tests.

Relevant issues

Resolves #729

Contributor checklist
  • Provide tests for the changes (unless documentation-only)
  • Documented any new features, CLI switches, etc. (if applicable)
    • Server --help output
    • README.md
    • doc/http-server.1 (use the same format as other entries)
  • The pull request is being made against the master branch
Maintainer checklist
  • Assign a version triage tag
  • Approve tests if applicable

@matthias-ccri
Copy link
Author

@thornjad can you approve the workflow?

@matthias-ccri
Copy link
Author

"First-time contributors need a maintainer to approve running workflows."

I'm dying to know if the tests pass :)

@thornjad
Copy link
Member

For some reason GH isn't giving me the option to approve, could you maybe try merging master again?

@matthias-ccri
Copy link
Author

matthias-ccri commented Dec 16, 2021

Here's what I did, but it seemed to already be up to date?:


$ git remote get-url origin
https://github.com/matthias-ccri/http-server.git
$ git remote add upstream https://github.com/http-party/http-server.git
$ git pull upstream master
From https://github.com/http-party/http-server
 * branch            master     -> FETCH_HEAD
 * [new branch]      master     -> upstream/master
Already up to date.
$ git push origin master
Everything up-to-date
$ git status
On branch master
Your branch is up to date with 'origin/master'.

nothing to commit, working tree clean

On the matthias-ccri/http-server repo it's showing:
image

Is the issue still there?

@matthias-ccri
Copy link
Author

Can this be merged?

@matthias-ccri
Copy link
Author

@thornjad is there a reason to not merge this?

@matthias-ccri
Copy link
Author

matthias-ccri commented Oct 28, 2022

@thornjad This MR has been ready to merge for 9 months.

@matthias-ccri
Copy link
Author

This PR has been open for 553 days (or 18 months). @thornjad is there hesitation to this change or is there an issue with the PR?

@matthias-ccri
Copy link
Author

@thornjad

@zbynek
Copy link
Contributor

zbynek commented Jul 28, 2023

@BigBlueHat is there any maintainer still interested in this package?

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.

Mirror domain in Access-Control-Allow-Origin header
3 participants