|
Issue 351: Reimplement OAuth2 - Step 2 (Auth PCL)
Reimplement OAuth2 - Step 2 (Auth PCL)
The new code of creating a service using OAuth2 will look like that:
var credential = await GoogleWebAuthenticationBroker.AuthenticateAsync(
new FileStream("client_secrets.json", FileMode.Open,
FileAccess.Read),
new[] { BooksService.Scopes.Books.GetStringValue() },
"user", CancellationToken.None).ConfigureAwait(false);
// Create the service.
var service = new BooksService(new BaseClientService.Initializer()
{
ApplicationName = "Books API Sample",
HttpClientInitializer = credential
});
Total comments: 24
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats ( 1843 lines, -2 lines) |
Patch |
|
A |
Src/GoogleApis.Auth.DotNet4/GoogleApis.Auth.DotNet4.csproj
|
View
|
|
1 chunk |
115 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth.DotNet4/OAuth2/LocalServerCodeReceiver.cs
|
View
|
1
2
|
1 chunk |
125 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth.DotNet4/OAuth2/PromptCodeReceiver.cs
|
View
|
|
1 chunk |
63 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth.DotNet4/Properties/AssemblyInfo.cs
|
View
|
|
1 chunk |
40 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth.DotNet4/packages.config
|
View
|
|
1 chunk |
8 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/GoogleApis.Auth.csproj
|
View
|
|
1 chunk |
119 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/GoogleJsonWebSignature.cs
|
View
|
1
2
|
1 chunk |
42 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/JsonWebSignature.cs
|
View
|
1
2
|
1 chunk |
103 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/JsonWebToken.cs
|
View
|
1
2
|
1 chunk |
127 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/OAuth2/BearerToken.cs
|
View
|
|
1 chunk |
90 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/OAuth2/ClientSecrets.cs
|
View
|
|
1 chunk |
30 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/OAuth2/GoogleClientSecrets.cs
|
View
|
1
2
|
1 chunk |
58 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/OAuth2/GoogleConsts.cs
|
View
|
|
1 chunk |
37 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/OAuth2/IAccessMethod.cs
|
View
|
|
1 chunk |
25 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/OAuth2/IAuthorizationCodeFlow.cs
|
View
|
|
1 chunk |
70 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/OAuth2/IAuthorizationCodeInstalledApp.cs
|
View
|
|
1 chunk |
39 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/OAuth2/ICodeReceiver.cs
|
View
|
|
1 chunk |
38 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/OAuth2/Requests/AuthorizationCodeRequestUrl.cs
|
View
|
|
1 chunk |
54 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/OAuth2/Requests/AuthorizationCodeTokenRequest.cs
|
View
|
|
1 chunk |
45 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/OAuth2/Requests/AuthorizationRequestUrl.cs
|
View
|
1
2
|
1 chunk |
77 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/OAuth2/Requests/GoogleAssertionTokenRequest.cs
|
View
|
3
|
1 chunk |
39 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/OAuth2/Requests/GoogleAuthorizationCodeRequestUrl.cs
|
View
|
|
1 chunk |
61 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/OAuth2/Requests/RefreshTokenRequest.cs
|
View
|
|
1 chunk |
37 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/OAuth2/Requests/TokenRequest.cs
|
View
|
|
1 chunk |
50 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/OAuth2/Responses/AuthorizationCodeResponseUrl.cs
|
View
|
|
1 chunk |
107 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/OAuth2/Responses/TokenErrorResponse.cs
|
View
|
|
1 chunk |
63 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/OAuth2/Responses/TokenResponse.cs
|
View
|
|
1 chunk |
93 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/OAuth2/Responses/TokenResponseException.cs
|
View
|
|
1 chunk |
37 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/Properties/AssemblyInfo.cs
|
View
|
|
1 chunk |
38 lines, -0 lines |
0 comments
|
Download
|
|
A |
Src/GoogleApis.Auth/packages.config
|
View
|
|
1 chunk |
8 lines, -0 lines |
0 comments
|
Download
|
|
M |
Src/GoogleApis.DotNet4/Apis/Util/Store/FileDataStore.cs
|
View
|
1
2
|
1 chunk |
1 line, -1 line |
0 comments
|
Download
|
|
M |
Src/GoogleApis/Apis/Util/Utilities.cs
|
View
|
1
2
|
1 chunk |
3 lines, -1 line |
0 comments
|
Download
|
|
M |
Src/GoogleApis/Properties/AssemblyInfo.cs
|
View
|
|
1 chunk |
1 line, -0 lines |
0 comments
|
Download
|
Total messages: 7
|