Class SigningProxyEndpoint
Proxies RPCs to another endpoint, vouching for each caller: an outer authenticator verifies the identity named by each ticket, and an inner one signs the ticket for the next endpoint.
public sealed class SigningProxyEndpoint : IEndpoint
- Inheritance
-
SigningProxyEndpoint
- Implements
- Inherited Members
Remarks
Only the ticket's signature is replaced. Session tickets, session challenges and their answers, and all requests and responses pass through unchanged, so a session encrypted between the client and the next endpoint stays opaque to the proxy. The next endpoint should use VerifiedOperationsAndEncryptedSession with an EndpointSignedAuthentication.
Constructors
SigningProxyEndpoint(IEndpoint, IAuthentication, IAuthentication, IEnumerable<Procedure>?)
public SigningProxyEndpoint(IEndpoint inner, IAuthentication outerAuthentication, IAuthentication innerAuthentication, IEnumerable<Procedure>? procedures = null)
Parameters
innerIEndpointThe endpoint to proxy to.
outerAuthenticationIAuthenticationVerifies the caller's identity without credentials, such as
WebAuthenticationover Windows authentication.innerAuthenticationIAuthenticationSigns tickets for the inner endpoint without credentials, such as SharedSecretAuthentication.
proceduresIEnumerable<Procedure>Procedures that may be proxied; defaults to GetAll().
Properties
Description
Human-readable name.
public string Description { get; }
Property Value
Methods
ConnectAsync(byte[], CancellationToken)
Proves the client's identity to the server in exchange for a symmetric session key.
public Task<byte[]> ConnectAsync(byte[] ticketBuffer, CancellationToken cancellationToken)
Parameters
ticketBufferbyte[]cancellationTokenCancellationToken
Returns
- Task<byte[]>
Serialised Response<T>.
ExecuteAsync(string, EndpointMessage, byte[]?, CancellationToken)
Calls an untyped procedure - this may involve local lookup, passthrough or decoration.
public Task<EndpointMessage> ExecuteAsync(string name, EndpointMessage request, byte[]? ticket, CancellationToken cancellationToken)
Parameters
namestringrequestEndpointMessageticketbyte[]cancellationTokenCancellationToken
Returns
VisitAsync<T, U>(AnonymousProcedure<T, U>, EndpointMessage, CancellationToken)
Calls a typed procedure on a local or remote host.
public Task<EndpointMessage> VisitAsync<T, U>(AnonymousProcedure<T, U> proc, EndpointMessage request, CancellationToken token) where T : notnull
Parameters
procAnonymousProcedure<T, U>requestEndpointMessagetokenCancellationToken
Returns
- Task<EndpointMessage>
Serialised Response<T>.
Type Parameters
TU
VisitAsync<T, U>(Procedure<T, U>, EndpointMessage, byte[], CancellationToken)
Calls a typed procedure on a local or remote host.
public Task<EndpointMessage> VisitAsync<T, U>(Procedure<T, U> proc, EndpointMessage request, byte[] ticketBuffer, CancellationToken token) where T : notnull
Parameters
procProcedure<T, U>requestEndpointMessageticketBufferbyte[]tokenCancellationToken
Returns
- Task<EndpointMessage>
Serialised Response<T>.
Type Parameters
TU