-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Sketch out mechanism for configuring WebSocket authentication from au…
- Loading branch information
Showing
10 changed files
with
206 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 31 additions & 0 deletions
31
src/KubeClient/Authentication/IClientAuthenticationConfig.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
using System.Security.Cryptography.X509Certificates; | ||
using System.Threading; | ||
using System.Threading.Tasks; | ||
|
||
namespace KubeClient.Authentication | ||
{ | ||
/// <summary> | ||
/// Represents configuration for client authentication to the Kubernetes API. | ||
/// </summary> | ||
public interface IClientAuthenticationConfig | ||
{ | ||
/// <summary> | ||
/// Add a client certificate for authentication to the Kubernetes API. | ||
/// </summary> | ||
/// <param name="certificate"> | ||
/// An <see cref="X509Certificate2"/> representing the client certificate to use. | ||
/// </param> | ||
void AddClientCertificate(X509Certificate2 certificate); | ||
|
||
/// <summary> | ||
/// Configure the HTTP "Authorization" header for authentication to the Kubernetes API. | ||
/// </summary> | ||
/// <param name="scheme"> | ||
/// The authentication scheme (e.g. "Basic", "Bearer", etc). | ||
/// </param> | ||
/// <param name="value"> | ||
/// The authentication value. | ||
/// </param> | ||
void SetAuthorizationHeader(string scheme, string value); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters