class Watobo::NTLM::Message::Type3
@private false
Public Class Methods
create(arg, opt ={})
click to toggle source
Builds a Type 3 packet @note All options must be properly encoded with either unicode or oem encoding @return [Type3] @option arg [String] :lm_response The LM hash @option arg [String] :ntlm_response The NTLM
hash @option arg [String] :domain The domain to authenticate to @option arg [String] :workstation The name of the calling workstation @option arg [String] :session_key The session key @option arg [Integer] :flag Flags for the packet
# File lib/watobo/utils/ntlm.rb, line 839 def create(arg, opt ={}) t = new t.lm_response = arg[:lm_response] t.ntlm_response = arg[:ntlm_response] t.domain = arg[:domain] t.user = arg[:user] if arg[:workstation] t.workstation = arg[:workstation] end if arg[:session_key] t.enable(:session_key) t.session_key = arg[session_key] end if arg[:flag] t.enable(:session_key) t.enable(:flag) t.flag = arg[:flag] end t end
parse(str)
click to toggle source
Parse a Type 3 packet @param [String] str A string containing Type 3 data @return [Type2]
# File lib/watobo/utils/ntlm.rb, line 824 def parse(str) t = new t.parse(str) t end