class SNMP::V3::Message

Defined in:

snmp/v3/message.cr

Constant Summary

AUTHNONE = Bytes.new(12)
MSG_MAX_SIZE = ASN1::BER.new.set_integer(65507)
MSG_VERSION = ASN1::BER.new.set_integer(Version::V3.to_i)
PRIVNONE = ASN1::BER.new.set_string("", tag: UniversalTags::OctetString)

Constructors

Instance Method Summary

Instance methods inherited from class SNMP::Message

build_reply build_reply, community : String community, community=(community : String) community=, error_index error_index, error_index=(value) error_index=, error_status error_status, error_status=(value) error_status=, expects_response? expects_response?, new_request_id new_request_id, oid oid, pdu : PDU | Trap | V1Trap pdu, request : Request request, request=(request : Request) request=, request_id request_id, request_id=(value) request_id=, to_ber(pdu = @pdu.to_ber(@request.to_u8)) to_ber, to_io(io : IO, format : IO::ByteFormat = IO::ByteFormat::SystemEndian) to_io, trap? trap?, value value, varbinds varbinds, varbinds=(value) varbinds=, version : Version version, version=(version : Version) version=

Constructor methods inherited from class SNMP::Message

new(community : String, request : SNMP::Request, varbind : VarBind | Nil | Array(VarBind) = nil, request_id = rand(2147483647), error_status = ErrorStatus::NoError, error_index = ErrorIndex::NoError, version : SNMP::Version = Version::V2C)
new(snmp : Array(ASN1::BER))
new

Class methods inherited from class SNMP::Message

from_io(io : IO, format : IO::ByteFormat = IO::ByteFormat::SystemEndian) from_io

Constructor Detail

def self.new(snmp : Array(ASN1::BER), security = nil) #

[View source]
def self.new(scoped_pdu : ScopedPDU, security_params : SecurityParams, security : Security | Nil = nil, security_model : SNMP::V3::SecurityModel = SecurityModel::User, id : Int32 = rand(2147483647)) #

[View source]
def self.new(snmp = ASN1::BER, security : Security | Nil = nil) #

[View source]

Instance Method Detail

def community=(id) #

[View source]
def engine_id #

[View source]
def engine_id=(id) #

[View source]
def flags : MessageFlags #

[View source]
def flags=(flags : MessageFlags) #

[View source]
def id : Int32 #

[View source]
def id=(id : Int32) #

[View source]
def max_size : Int32 #

[View source]
def max_size=(max_size : Int32) #

[View source]
def new_request_id #

[View source]
def pdu=(pdu) #

[View source]
def request=(type : Request) #

[View source]
def scoped_pdu : ScopedPDU #

[View source]
def scoped_pdu=(scoped_pdu : ScopedPDU) #

[View source]
def security_model : SecurityModel #

[View source]
def security_model=(security_model : SecurityModel) #

[View source]
def security_params : SecurityParams #

[View source]
def security_params=(security_params : SecurityParams) #

[View source]
def sign(security, scoped_pdu = @scoped_pdu.to_ber) #

[View source]
def to_ber(scoped_pdu = @scoped_pdu.to_ber) #

The scoped PDU can be passed in as a BER for passing in encrypted values


[View source]
def verify(security, scoped_pdu = @scoped_pdu.to_ber) #

[View source]