Methods

Class/Module Index [+]

Quicksearch

Rex::MachParsey::FatBase::FatArch

Attributes

cpu_subtype[RW]
cpu_type[RW]
offset[RW]
size[RW]

Public Class Methods

new(rawdata, endian) click to toggle source
# File lib/rex/machparsey/machbase.rb, line 378
def initialize(rawdata, endian)
        if endian == ENDIAN_LSB
                fat_arch = FAT_ARCH_LSB.make_struct
        else
                fat_arch = FAT_ARCH_MSB.make_struct
        end

        if !fat_arch.from_s(rawdata)
                raise FatHeaderError, "Could not parse arch from FAT header"
        end

        self.cpu_type = fat_arch.v['cpu_type']
        self.cpu_subtype = fat_arch.v['cpu_subtype']
        self.offset = fat_arch.v['offset']
        self.size = fat_arch.v['size']
        self.struct = fat_arch
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.