pub struct MockAuthenticationPlugin { /* private fields */ }Expand description
Mock-Implementation — akzeptiert alles, Handshake-Step-Count hard-coded.
Implementations§
Trait Implementations§
Source§impl AuthenticationPlugin for MockAuthenticationPlugin
impl AuthenticationPlugin for MockAuthenticationPlugin
Source§fn validate_local_identity(
&mut self,
_props: &PropertyList,
_participant_guid: [u8; 16],
) -> SecurityResult<IdentityHandle>
fn validate_local_identity( &mut self, _props: &PropertyList, _participant_guid: [u8; 16], ) -> SecurityResult<IdentityHandle>
Wird einmal beim Participant-Start aufgerufen: lokale Identity
validieren (Zertifikat, Key, Trust-Anchor) und einen Handle
zurueckgeben. Read more
Source§fn validate_remote_identity(
&mut self,
_local: IdentityHandle,
_remote_participant_guid: [u8; 16],
_remote_auth_token: &[u8],
) -> SecurityResult<IdentityHandle>
fn validate_remote_identity( &mut self, _local: IdentityHandle, _remote_participant_guid: [u8; 16], _remote_auth_token: &[u8], ) -> SecurityResult<IdentityHandle>
Wird aufgerufen, sobald via SPDP ein Remote-Participant entdeckt
wurde. Plugin validiert das Remote-Cert (aus
remote_auth_token)
gegen seinen Trust-Store. Read moreSource§fn begin_handshake_request(
&mut self,
_initiator: IdentityHandle,
_replier: IdentityHandle,
) -> SecurityResult<(HandshakeHandle, HandshakeStepOutcome)>
fn begin_handshake_request( &mut self, _initiator: IdentityHandle, _replier: IdentityHandle, ) -> SecurityResult<(HandshakeHandle, HandshakeStepOutcome)>
Startet den Handshake. Liefert das erste Token, das an den
Peer gesendet werden muss. Read more
Source§fn begin_handshake_reply(
&mut self,
_replier: IdentityHandle,
_initiator: IdentityHandle,
request_token: &[u8],
) -> SecurityResult<(HandshakeHandle, HandshakeStepOutcome)>
fn begin_handshake_reply( &mut self, _replier: IdentityHandle, _initiator: IdentityHandle, request_token: &[u8], ) -> SecurityResult<(HandshakeHandle, HandshakeStepOutcome)>
Peer-Seite des Handshake-Starts.
request_token ist was der
Initiator per begin_handshake_request geschickt hat. Read moreSource§fn process_handshake(
&mut self,
handshake: HandshakeHandle,
token: &[u8],
) -> SecurityResult<HandshakeStepOutcome>
fn process_handshake( &mut self, handshake: HandshakeHandle, token: &[u8], ) -> SecurityResult<HandshakeStepOutcome>
Folge-Nachrichten des Handshakes durchreichen. Read more
Beendet den Handshake und liefert den finalen SharedSecret.
Fehlschlag bricht ab. Wird nach
Complete-Outcome durch den
Caller aufgerufen, um den Secret aus dem Plugin zu ziehen. Read moreSource§fn plugin_class_id(&self) -> &str
fn plugin_class_id(&self) -> &str
Identity-Plugin-Name (z.B. “DDS:Auth:PKI-DH:1.2”). Wird in SPDP als
dds.sec.auth.plugin_class annonciert.Source§fn get_identity_token(&self, _local: IdentityHandle) -> SecurityResult<Vec<u8>>
fn get_identity_token(&self, _local: IdentityHandle) -> SecurityResult<Vec<u8>>
Liefert das
IdentityToken fuer eine Local-Identity (Spec
§9.3.2.4). Wird im SPDP-Announce als PID_IDENTITY_TOKEN (0x1001)
publiziert. Default: leerer Token (= Plugin unterstuetzt das
Feature nicht). Read moreSource§fn get_identity_status_token(
&self,
_local: IdentityHandle,
) -> SecurityResult<Vec<u8>>
fn get_identity_status_token( &self, _local: IdentityHandle, ) -> SecurityResult<Vec<u8>>
Liefert das
IdentityStatusToken fuer eine Local-Identity
(Spec §9.3.2.5.1.2). Default: leer. Read moreSource§fn set_permissions_credential_and_token(
&mut self,
_local: IdentityHandle,
_permissions_credential: &[u8],
_permissions_token: &[u8],
) -> SecurityResult<()>
fn set_permissions_credential_and_token( &mut self, _local: IdentityHandle, _permissions_credential: &[u8], _permissions_token: &[u8], ) -> SecurityResult<()>
Setzt das Permissions-Credential und das Permissions-Token an
einer Local-Identity (Spec §9.3.2.4 + §9.3.2.5.4). Wird vom
Caller-Layer mit dem Output des AccessControlPlugin gespeist. Read more
Source§fn get_authenticated_peer_credential_token(
&self,
_handshake: HandshakeHandle,
) -> SecurityResult<Vec<u8>>
fn get_authenticated_peer_credential_token( &self, _handshake: HandshakeHandle, ) -> SecurityResult<Vec<u8>>
Liefert das
AuthenticatedPeerCredentialToken (Spec §9.3.2.5.6).
Wird nach erfolgreichem Handshake vom AccessControl-Layer
abgeholt, um den Caller-Subject-Match durchzufuehren.
Default: leer. Read moreSource§impl Debug for MockAuthenticationPlugin
impl Debug for MockAuthenticationPlugin
Source§impl Default for MockAuthenticationPlugin
impl Default for MockAuthenticationPlugin
Source§fn default() -> MockAuthenticationPlugin
fn default() -> MockAuthenticationPlugin
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl !Freeze for MockAuthenticationPlugin
impl RefUnwindSafe for MockAuthenticationPlugin
impl Send for MockAuthenticationPlugin
impl Sync for MockAuthenticationPlugin
impl Unpin for MockAuthenticationPlugin
impl UnsafeUnpin for MockAuthenticationPlugin
impl UnwindSafe for MockAuthenticationPlugin
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more