Class: Rex::Proto::Kerberos::Pac::Krb5SignatureType

Inherits:
BinData::Uint32le
  • Object
show all
Defined in:
lib/rex/proto/kerberos/pac/krb5_pac.rb

Instance Method Summary collapse

Instance Method Details

#assign(val) ⇒ Object

Parameters:

  • val (Integer)

    The checksum value

See Also:



336
337
338
339
340
341
342
343
344
# File 'lib/rex/proto/kerberos/pac/krb5_pac.rb', line 336

def assign(val)
  # Handle the scenario of users setting the signature type to a negative value such as -138 for HMAC_RC4
  # Convert it to two's complement representation explicitly to bypass bindata's clamping logic in the super method:
  if val < 0
    val &= 0xffffffff
  end

  super(val)
end