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

[allowed_origins] don't work #113

Open
abcbarryn opened this issue Dec 28, 2024 · 2 comments
Open

[allowed_origins] don't work #113

abcbarryn opened this issue Dec 28, 2024 · 2 comments

Comments

@abcbarryn
Copy link

It either allows everything or denies everything. If I leave the list blank everything is allowed as expected, but if I add https://myserver.dom:8001 it is denied. If I change that to *://myserver.dom:8001 then everything is allowed.

@abcbarryn abcbarryn changed the title [allowed_origins] work [allowed_origins] don't work Dec 28, 2024
@abcbarryn
Copy link
Author

Seems like this code is not working right...

        if !t.gateway.IsClientOriginAllowed(origin) {
                err = fmt.Errorf("Origin %#v not allowed", origin)
                t.gateway.Log(2, "%s. Closing connection", err)
                return err
        }

@abcbarryn
Copy link
Author

It seems to work "properly" only if I put the origin string in quotes??

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

No branches or pull requests

1 participant