Exemplo n.º 1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ClientBase"/> class.
 /// </summary>
 /// <param name="authorizationServer">The token issuer.</param>
 /// <param name="clientIdentifier">The client identifier.</param>
 /// <param name="clientCredentialApplicator">
 /// The tool to use to apply client credentials to authenticated requests to the Authorization Server.
 /// May be <c>null</c> for clients with no secret or other means of authentication.
 /// </param>
 protected ClientBase(AuthorizationServerDescription authorizationServer, string clientIdentifier = null, ClientCredentialApplicator clientCredentialApplicator = null)
 {
     this.AuthorizationServer        = authorizationServer;
     this.Channel                    = new OAuth2ClientChannel();
     this.ClientIdentifier           = clientIdentifier;
     this.ClientCredentialApplicator = clientCredentialApplicator;
 }
Exemplo n.º 2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="WebServerClient"/> class.
 /// </summary>
 /// <param name="authorizationServer">The authorization server.</param>
 /// <param name="clientIdentifier">The client identifier.</param>
 /// <param name="clientCredentialApplicator">
 /// The tool to use to apply client credentials to authenticated requests to the Authorization Server.
 /// May be <c>null</c> for clients with no secret or other means of authentication.
 /// </param>
 public WebServerClient(AuthorizationServerDescription authorizationServer, string clientIdentifier, ClientCredentialApplicator clientCredentialApplicator)
     : base(authorizationServer, clientIdentifier, clientCredentialApplicator)
 {
 }
Exemplo n.º 3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="WebServerClient"/> class.
 /// </summary>
 /// <param name="authorizationServer">The authorization server.</param>
 /// <param name="clientIdentifier">The client identifier.</param>
 /// <param name="clientSecret">The client secret.</param>
 public WebServerClient(AuthorizationServerDescription authorizationServer, string clientIdentifier = null, string clientSecret = null)
     : this(authorizationServer, clientIdentifier, DefaultSecretApplicator(clientSecret))
 {
 }