3 namespace dangerous {
namespace snmp {
namespace encoding {
8 std::string msgAuthoritativeEngineID;
10 int32_t msgAuthoritativeEngineBoots;
12 int32_t msgAuthoritativeEngineTime;
14 std::string msgUserName;
16 std::string msgAuthenticationParameters;
18 std::string msgPrivacyParameters;
26 static constexpr
const char* NAME =
"UsmSecurityParameters";
27 static const int TYPE = asn1::helper::SEQUENCE::TYPE;
30 static unsigned int length(
const value_type& parameters ) {
31 unsigned int size = 0;
33 size += asn1::encodedSize<encoding::OCTET_STRING>( parameters.msgAuthoritativeEngineID );
34 size += asn1::encodedSize<encoding::INTEGER>( parameters.msgAuthoritativeEngineBoots );
35 size += asn1::encodedSize<encoding::INTEGER>( parameters.msgAuthoritativeEngineTime );
36 size += asn1::encodedSize<encoding::OCTET_STRING>( parameters.msgUserName );
37 size += asn1::encodedSize<encoding::OCTET_STRING>( parameters.msgAuthenticationParameters );
38 size += asn1::encodedSize<encoding::OCTET_STRING>( parameters.msgPrivacyParameters );
43 static bool write(
const value_type& parameters,
char* buffer,
unsigned int bufferSize ) {
84 static bool read(
value_type& parameters,
char* buffer,
unsigned int bufferSize ) {
bool write(const typename EncodingClass::value_type &value)
This performs a full, logical write of a kind of encoded data.
Definition: berstream.hpp:207
This is the encoder/decoder for the "UsmSecurityParameters" class.
Definition: usmsecurityparameters.hpp:24
A ByteStream is an object that is basically a big wrapper around a character buffer.
Definition: bytestream.hpp:30
Definition: encoding.hpp:20
Only read operations may be performed.
Definition: bytestream.hpp:38
A BerStream represents a BER-encoded stream of data.
Definition: berstream.hpp:16
Both read and write operations may be performed.
Definition: bytestream.hpp:40
void linkFrom(char *bytes, unsigned int bytesSize, Access access)
This links the bytes given to the ByteStream's character buffer.
Definition: encoding.hpp:25
bool read(typename EncodingClass::value_type &value)
This performs a full, logical read of a kind of encoded data.
Definition: berstream.hpp:145
Definition: usmsecurityparameters.hpp:5