#[non_exhaustive]pub struct MacAlgorithmDukpt {
pub key_serial_number: Option<String>,
pub dukpt_key_variant: Option<DukptKeyVariant>,
pub dukpt_derivation_type: Option<DukptDerivationType>,
}
Expand description
Parameters required for DUKPT MAC generation and verification.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.key_serial_number: Option<String>
The unique identifier known as Key Serial Number (KSN) that comes from an encrypting device using DUKPT encryption method. The KSN is derived from the encrypting device unique identifier and an internal transaction counter.
dukpt_key_variant: Option<DukptKeyVariant>
The type of use of DUKPT, which can be MAC generation, MAC verification, or both.
dukpt_derivation_type: Option<DukptDerivationType>
The key type derived using DUKPT from a Base Derivation Key (BDK) and Key Serial Number (KSN). This must be less than or equal to the strength of the BDK. For example, you can't use AES_128
as a derivation type for a BDK of AES_128
or TDES_2KEY
.
Implementations§
source§impl MacAlgorithmDukpt
impl MacAlgorithmDukpt
sourcepub fn key_serial_number(&self) -> Option<&str>
pub fn key_serial_number(&self) -> Option<&str>
The unique identifier known as Key Serial Number (KSN) that comes from an encrypting device using DUKPT encryption method. The KSN is derived from the encrypting device unique identifier and an internal transaction counter.
sourcepub fn dukpt_key_variant(&self) -> Option<&DukptKeyVariant>
pub fn dukpt_key_variant(&self) -> Option<&DukptKeyVariant>
The type of use of DUKPT, which can be MAC generation, MAC verification, or both.
sourcepub fn dukpt_derivation_type(&self) -> Option<&DukptDerivationType>
pub fn dukpt_derivation_type(&self) -> Option<&DukptDerivationType>
The key type derived using DUKPT from a Base Derivation Key (BDK) and Key Serial Number (KSN). This must be less than or equal to the strength of the BDK. For example, you can't use AES_128
as a derivation type for a BDK of AES_128
or TDES_2KEY
.
source§impl MacAlgorithmDukpt
impl MacAlgorithmDukpt
sourcepub fn builder() -> MacAlgorithmDukptBuilder
pub fn builder() -> MacAlgorithmDukptBuilder
Creates a new builder-style object to manufacture MacAlgorithmDukpt
.
Trait Implementations§
source§impl Clone for MacAlgorithmDukpt
impl Clone for MacAlgorithmDukpt
source§fn clone(&self) -> MacAlgorithmDukpt
fn clone(&self) -> MacAlgorithmDukpt
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for MacAlgorithmDukpt
impl Debug for MacAlgorithmDukpt
source§impl PartialEq<MacAlgorithmDukpt> for MacAlgorithmDukpt
impl PartialEq<MacAlgorithmDukpt> for MacAlgorithmDukpt
source§fn eq(&self, other: &MacAlgorithmDukpt) -> bool
fn eq(&self, other: &MacAlgorithmDukpt) -> bool
self
and other
values to be equal, and is used
by ==
.