pub enum SecAlg {
Show 18 variants
DeleteDs,
RsaMd5,
Dh,
Dsa,
RsaSha1,
DsaNsec3Sha1,
RsaSha1Nsec3Sha1,
RsaSha256,
RsaSha512,
EccGost,
EcdsaP256Sha256,
EcdsaP384Sha384,
Ed25519,
Ed448,
Indirect,
PrivateDns,
PrivateOid,
Int(u8),
}
Expand description
Security Algorithm Numbers.
These numbers are used in various security related record types.
For the currently registered values see the IANA registration.
Variants§
DeleteDs
Delete DS
This algorithm is used in RFC 8087 to signal to the parent that a certain DS record should be deleted. It is not an actual algorithm and can neither be used in zone nor transaction signing.
RsaMd5
RSA/MD5
This algorithm was described in RFC 2537 and since has been deprecated due to weaknesses of the MD5 hash algorithm by RFC 3110 which suggests to use RSA/SHA1 instead.
This algorithm may not be used for zone signing but may be used for transaction security.
Dh
Diffie-Hellman
This algorithm is described in RFC 2539 for storing Diffie-Hellman (DH) keys in DNS resource records. It can not be used for zone signing but only for transaction security.
Dsa
DSA/SHA1
This algorithm is described in RFC 2536. It may be used both for zone signing and transaction security.
RsaSha1
RSA/SHA-1
This algorithm is described in RFC 3110. It may be used both for zone signing and transaction security. It is mandatory for DNSSEC implementations.
DsaNsec3Sha1
DSA-NSEC3-SHA1
This value is an alias for Dsa
for use within NSEC3 records.
RsaSha1Nsec3Sha1
RSASHA1-NSEC3-SHA1
This value is an alias for RsaSha1
for use within NSEC3 records.
RsaSha256
RSA/SHA-256
This algorithm is described in RFC 5702. It may be used for zone signing only.
RsaSha512
RSA/SHA-512
This algorithm is described in RFC 5702. It may be used for zone signing only.
EccGost
GOST R 34.10-2001
This algorithm is described in RFC 5933. It may be used for zone signing only.
EcdsaP256Sha256
ECDSA Curve P-256 with SHA-256
This algorithm is described in RFC 6605. It may be used for zone signing only.
EcdsaP384Sha384
ECDSA Curve P-384 with SHA-384
This algorithm is described in RFC 6605. It may be used for zone signing only.
Ed25519
ED25519
This algorithm is described in RFC 8080.
Ed448
ED448
This algorithm is described in RFC 8080.
Indirect
Reserved for Indirect Keys
This value is reserved by RFC 4034.
PrivateDns
A private algorithm identified by a domain name.
This value is defined in RFC 4034.
PrivateOid
A private algorithm identified by a ISO OID.
This value is defined in RFC 4034.
Int(u8)
A raw value given through its integer.
Implementations§
source§impl SecAlg
impl SecAlg
sourcepub fn from_mnemonic(m: &[u8]) -> Option<Self>
pub fn from_mnemonic(m: &[u8]) -> Option<Self>
Returns a value from a well-defined mnemonic.
sourcepub const fn to_mnemonic(self) -> Option<&'static [u8]>
pub const fn to_mnemonic(self) -> Option<&'static [u8]>
Returns the mnemonic for this value if there is one.
This will also return a mnemonic if a well-defined variant
is hidden in a Int
variant.
pub fn parse<'a, Octs: AsRef<[u8]> + ?Sized>( parser: &mut Parser<'a, Octs>, ) -> Result<Self, ParseError>
pub const COMPOSE_LEN: u16 = 1u16
pub fn compose<Target: OctetsBuilder + ?Sized>( &self, target: &mut Target, ) -> Result<(), Target::AppendError>
Trait Implementations§
source§impl Ord for SecAlg
impl Ord for SecAlg
source§impl PartialOrd<SecAlg> for u8
impl PartialOrd<SecAlg> for u8
source§impl PartialOrd<u8> for SecAlg
impl PartialOrd<u8> for SecAlg
source§impl PartialOrd for SecAlg
impl PartialOrd for SecAlg
impl Copy for SecAlg
impl Eq for SecAlg
Auto Trait Implementations§
impl Freeze for SecAlg
impl RefUnwindSafe for SecAlg
impl Send for SecAlg
impl Sync for SecAlg
impl Unpin for SecAlg
impl UnwindSafe for SecAlg
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)source§impl<T> CloneToUninit for Twhere
T: Copy,
impl<T> CloneToUninit for Twhere
T: Copy,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)