pub enum DecodeErrorKind {
Show 27 variants
UnexpectedTag {
expected: u8,
actual: u8,
},
TruncatedData,
InvalidLength,
IndefiniteLength,
IntegerOverflow,
ZeroLengthInteger,
InvalidOidEncoding,
UnknownVersion(i32),
UnknownPduType(u8),
ConstructedOctetString,
MissingPdu,
InvalidMsgFlags,
UnknownSecurityModel(i32),
MsgMaxSizeTooSmall {
value: i32,
minimum: i32,
},
MsgMaxSizeTooLarge {
value: i32,
},
InvalidMsgId {
value: i32,
},
InvalidNull,
UnexpectedEncryption,
ExpectedEncryption,
InvalidIpAddressLength {
length: usize,
},
LengthTooLong {
octets: usize,
},
LengthExceedsMax {
length: usize,
max: usize,
},
Integer64TooLong {
length: usize,
},
EmptyResponse,
TlvOverflow,
InsufficientData {
needed: usize,
available: usize,
},
InvalidOid,
}Expand description
BER decode error kinds.
Variants§
UnexpectedTag
Expected different tag.
TruncatedData
Data truncated unexpectedly.
InvalidLength
Invalid BER length encoding.
IndefiniteLength
Indefinite length not supported.
IntegerOverflow
Integer value overflow.
ZeroLengthInteger
Zero-length integer.
InvalidOidEncoding
Invalid OID encoding.
UnknownVersion(i32)
Unknown SNMP version.
UnknownPduType(u8)
Unknown PDU type.
ConstructedOctetString
Constructed OCTET STRING not supported.
MissingPdu
Missing required PDU.
InvalidMsgFlags
Invalid msgFlags (priv without auth).
UnknownSecurityModel(i32)
Unknown security model.
MsgMaxSizeTooSmall
msgMaxSize below RFC 3412 minimum (484 octets).
MsgMaxSizeTooLarge
msgMaxSize above RFC 3412 maximum (2147483647).
InvalidMsgId
msgID outside RFC 3412 range (0..2147483647).
InvalidNull
NULL with non-zero length.
UnexpectedEncryption
Expected plaintext, got encrypted.
ExpectedEncryption
Expected encrypted, got plaintext.
InvalidIpAddressLength
Invalid IP address length.
LengthTooLong
Length field too long.
LengthExceedsMax
Length exceeds maximum.
Integer64TooLong
Integer64 too long.
EmptyResponse
Empty response.
TlvOverflow
TLV extends past end of data.
InsufficientData
Insufficient data for read.
InvalidOid
Invalid OID in notification varbinds.
Trait Implementations§
Source§impl Clone for DecodeErrorKind
impl Clone for DecodeErrorKind
Source§fn clone(&self) -> DecodeErrorKind
fn clone(&self) -> DecodeErrorKind
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more