Class: Rex::Proto::MsDtyp::MsDtypSystemAuditObjectAceBody
- Inherits:
-
MsDtypAceObjectBody
- Object
- BinData::Record
- MsDtypAceObjectBody
- Rex::Proto::MsDtyp::MsDtypSystemAuditObjectAceBody
- Defined in:
- lib/rex/proto/ms_dtyp.rb
Overview
[2.4.4.11 SYSTEM_AUDIT_OBJECT_ACE](learn.microsoft.com/en-us/openspecs/windows_protocols/ms-dtyp/c8da72ae-6b54-4a05-85f4-e2594936d3d5)
Instance Method Summary collapse
Instance Method Details
#calc_app_data_length ⇒ Object
190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 |
# File 'lib/rex/proto/ms_dtyp.rb', line 190 def calc_app_data_length ace_header = parent&.header return 0 if ace_header.nil? ace_size = ace_header&.ace_size return 0 if ace_size.nil? or (ace_size == 0) ace_header_length = ace_header.to_binary_s.length body = parent&.body if body.nil? return 0 # Read no data as there is no body, so either we have done some data misalignment or we shouldn't be reading data. else ace_body_length = body.to_binary_s.length return ace_size - (ace_header_length + ace_body_length) end end |