pub struct ConnectionMetadata {
pub connection_id: String,
pub environment: Option<HashMap<String, MetadataValue>>,
pub files: Option<HashMap<String, BinaryMetadataValue>>,
pub metadata: Option<HashMap<String, MetadataValue>>,
pub remote_address: String,
}Expand description
ConnectionMetadata holds a metadata structure passed around with a metadata. Its main purpose is to allow an authentication or authorization module to configure data exposed to the configuration server or the backend.
Fields§
§connection_id: StringConnectionID is an opaque ID to identify the SSH connection in question.
environment: Option<HashMap<String, MetadataValue>>Environment is a set of key-value pairs provided by the authentication or configuration system and may be exposed by the backend.
files: Option<HashMap<String, BinaryMetadataValue>>Files is a key-value pair of file names and their content set by the authentication or configuration system and consumed by the backend.
metadata: Option<HashMap<String, MetadataValue>>Metadata is a set of key-value pairs that carry additional information from the authentication and configuration system to the backends. Backends can expose this information as container labels, environment variables, or other places.
remote_address: StringRemoteAddress is the IP address and port of the user trying to authenticate.
Implementations§
Source§impl ConnectionMetadata
impl ConnectionMetadata
pub fn new(connection_id: String, remote_address: String) -> ConnectionMetadata
Trait Implementations§
Source§impl Clone for ConnectionMetadata
impl Clone for ConnectionMetadata
Source§fn clone(&self) -> ConnectionMetadata
fn clone(&self) -> ConnectionMetadata
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ConnectionMetadata
impl Debug for ConnectionMetadata
Source§impl<'de> Deserialize<'de> for ConnectionMetadata
impl<'de> Deserialize<'de> for ConnectionMetadata
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl FromStr for ConnectionMetadata
Converts Query Parameters representation (style=form, explode=false) to a ConnectionMetadata value
as specified in https://swagger.io/docs/specification/serialization/
Should be implemented in a serde deserializer
impl FromStr for ConnectionMetadata
Converts Query Parameters representation (style=form, explode=false) to a ConnectionMetadata value as specified in https://swagger.io/docs/specification/serialization/ Should be implemented in a serde deserializer
Source§impl PartialEq for ConnectionMetadata
impl PartialEq for ConnectionMetadata
Source§fn eq(&self, other: &ConnectionMetadata) -> bool
fn eq(&self, other: &ConnectionMetadata) -> bool
self and other values to be equal, and is used by ==.Source§impl Serialize for ConnectionMetadata
impl Serialize for ConnectionMetadata
impl StructuralPartialEq for ConnectionMetadata
Source§impl ToString for ConnectionMetadata
Converts the ConnectionMetadata value to the Query Parameters representation (style=form, explode=false)
specified in https://swagger.io/docs/specification/serialization/
Should be implemented in a serde serializer
impl ToString for ConnectionMetadata
Converts the ConnectionMetadata value to the Query Parameters representation (style=form, explode=false) specified in https://swagger.io/docs/specification/serialization/ Should be implemented in a serde serializer