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

string.Equals in AccountController will not match * #23

Open
O-Mutt opened this issue Dec 31, 2015 · 0 comments
Open

string.Equals in AccountController will not match * #23

O-Mutt opened this issue Dec 31, 2015 · 0 comments

Comments

@O-Mutt
Copy link

O-Mutt commented Dec 31, 2015

AccountController ~line 270
 if (!string.Equals(client.AllowedOrigin, redirectUri.GetLeftPart(UriPartial.Authority), StringComparison.OrdinalIgnoreCase))

This line does not match origin of * to any origin as string.Equals doe not account for regex.

Maybe something more like

Regex allowOriginRegex = new Regex(client.AllowedOrigin, RegexOptions.IgnoreCase);
if (!string.Equals(client.AllowedOrigin, redirectUri.GetLeftPart(UriPartial.Authority), StringComparison.OrdinalIgnoreCase) || allowOriginRegex.match( redirectUri.GetLeftPart(UriPartial.Authority))
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