diff options
author | Andrew Arnott <andrewarnott@gmail.com> | 2010-07-05 17:51:36 -0700 |
---|---|---|
committer | Andrew Arnott <andrewarnott@gmail.com> | 2010-07-05 17:51:36 -0700 |
commit | 3430556132a2ef3eeb0f4660ef057c88a88258e8 (patch) | |
tree | 36adb59049ec934703d51fb1556d8bed6a8eaa0d /src | |
parent | 801e0f986b3ce6495237b7378d53a46c63e0e614 (diff) | |
download | DotNetOpenAuth-3430556132a2ef3eeb0f4660ef057c88a88258e8.zip DotNetOpenAuth-3430556132a2ef3eeb0f4660ef057c88a88258e8.tar.gz DotNetOpenAuth-3430556132a2ef3eeb0f4660ef057c88a88258e8.tar.bz2 |
Simplified OAuth 2 client sample.
Diffstat (limited to 'src')
-rw-r--r-- | src/DotNetOpenAuth/OAuth2/WebServerClient.cs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/DotNetOpenAuth/OAuth2/WebServerClient.cs b/src/DotNetOpenAuth/OAuth2/WebServerClient.cs index 467d7d3..ff63f46 100644 --- a/src/DotNetOpenAuth/OAuth2/WebServerClient.cs +++ b/src/DotNetOpenAuth/OAuth2/WebServerClient.cs @@ -38,6 +38,17 @@ namespace DotNetOpenAuth.OAuth2 { /// <summary> /// Prepares a request for user authorization from an authorization server. /// </summary> + /// <param name="scope">The scope of authorized access requested.</param> + /// <returns>The authorization request as an HTTP response that causes a redirect.</returns> + public OutgoingWebResponse RequestUserAuthorization(string scope = null) { + var response = this.PrepareRequestUserAuthorization(scope); + return this.Channel.PrepareResponse(response); + } + + /// <summary> + /// Prepares a request for user authorization from an authorization server. + /// </summary> + /// <param name="scope">The scope of authorized access requested.</param> /// <returns>The authorization request.</returns> public EndUserAuthorizationRequest PrepareRequestUserAuthorization(string scope = null) { var authorizationState = new AuthorizationState { Scope = scope }; |