ASN1::BER::Length
Constants
ENDIAN = ["big"]
KLASS_NAME = [ASN1::BER::Length]
PARTS = [{type: "bitfield", name: 2, cls: ASN1::BER::Length,
onlyif: nil, verify: nil}, {type: "array", name: long_bytes, cls: UInt8, onlyif: nil, verify: nil, length: -> do
if long && (!indefinite?)
if length_indicator > 4
raise("invalid ASN.1 BER length. Number of length bytes: #{length_indicator}")
end
0 | length_indicator
else
0
end
end,
value: nil}] of Nil
REMAINING = [] of Nil
Class methods
bit_fields
SourceInstance methods
__format__
Sourceindefinite?
Sourcelength
We can pretty much safely assume no protocol is implementing more than positive Int32 length datagrams
length=(length : Int32)
We can pretty much safely assume no protocol is implementing more than positive Int32 length datagrams
length_indicator
length_indicator=(length_indicator : UInt8)
long
Sourcelong=(long : UInt8)
long_bytes
Macros
asn1_ber(name, onlyif = nil, verify = nil, value = nil)
Sourceasn1_ber_extended_identifier(name, onlyif = nil, verify = nil, value = nil)
Sourceasn1_ber_identifier(name, onlyif = nil, verify = nil, value = nil)
Sourceasn1_ber_length(name, onlyif = nil, verify = nil, value = nil)
Sourceber(name, onlyif = nil, verify = nil, value = nil)
Source