Class SshAgentRequest
- Namespace
- SshSharp
- Assembly
- SshSharp.dll
One request that a program on the server makes of a forwarded agent, as ForwardAgentFilter sees it: which key, what for, and what is known of where the signature goes.
public sealed class SshAgentRequest
- Inheritance
-
SshAgentRequest
- Inherited Members
Remarks
Everything here comes from the server's side except ForwardingHostKeys' first key, which is the host key of the server
this client forwarded the agent to. DestinationHostKey and the other forwarding hops are host keys whose signatures
over their sessions the agent protocol's session binding (session-bind@openssh.com) proved; UserName and
Namespace are whatever the request says.
Constructors
- SshAgentRequest(SshAgentOperation, SshPublicKey, SshCertificate?, IReadOnlyList<SshPublicKey>?, SshPublicKey?)
Creates a request (SshSharp makes them; this is for testing a filter).
Properties
- Certificate
The certificate when the agent's identity is one (a key paired with it, WithCertificate(SshCertificate)); otherwise null.
- DestinationHostKey
The host key of the server the program on the server is logging in to, when the agent connection was bound to that session (
session-bind@openssh.com, which OpenSSH 8.9 and later send) and the host key's signature over the session verified; null when it is not known. For Sign the signed login request must be for that same session, or the request is refused before the filter is asked.
- ForwardingHostKeys
The host keys of the servers the agent was forwarded through, in order: first the server this client connected to, then each further hop that forwarded it on and bound its connection (
ssh -Afrom OpenSSH 8.9 and later). Empty when not known.
- Key
The key: the agent's key itself, or for a certificate (Certificate) the key it certifies.
- Namespace
For a FileSignature, its namespace (for example
gitorfile); otherwise null.
- Operation
Listing the keys, or signing with one.
- Purpose
For Sign, what the signature is for, as the data to sign shows it: logging in to a server (Authentication), an SSH signature over a file or commit (FileSignature, with its Namespace), or issuing a certificate (Certificate). Null for a listing, and null for a signature over data of none of these forms: programs sign their own formats through agents (pam_ssh_agent_auth, for one), so whether to sign such data is the filter's decision. A filter that allows only the purposes it knows refuses it.
- UserName
For an Authentication signature, the user name the program on the server logs in as, as the server sent it (clean it before showing or logging it); otherwise null.