Skip to content

Commit

Permalink
default OAuth redirect URI to http://127.0.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
hickford committed Oct 23, 2023
1 parent 62eb6ab commit ee35d7b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
2 changes: 1 addition & 1 deletion docs/generic-oauth.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ following values in your Git configuration:

- Client ID
- Client Secret (optional)
- Redirect URL
- Redirect URL (optional, defaults to `http://127.0.0.1`)
- Scopes (optional)
- OAuth Endpoints
- Authorization Endpoint
Expand Down
4 changes: 1 addition & 3 deletions src/shared/Core/GenericOAuthConfig.cs
Original file line number Diff line number Diff line change
Expand Up @@ -81,9 +81,7 @@ public static bool TryGet(ITrace trace, ISettings settings, Uri remoteUri, out G
}
else
{
trace.WriteLine($"Invalid OAuth configuration - missing/invalid redirect URI: {redirectUrl}");
config = null;
return false;
config.RedirectUri = new Uri("http://127.0.0.1");
}

if (settings.TryGetSetting(
Expand Down

0 comments on commit ee35d7b

Please sign in to comment.