Class: OdinFlex::MachO::LC_DYSYMTAB

Inherits:
Command
  • Object
show all
Defined in:
lib/odinflex/mach-o.rb

Constant Summary collapse

VALUE =
0xb
SIZE =
18 * 4

Instance Attribute Summary collapse

Attributes inherited from Command

#cmd, #size

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Command

#command?, from_offset

Methods included from SectionTypes

#command?, #section?, #segment?, #symtab?

Constructor Details

#initialize(cmd, size, ilocalsym, nlocalsym, iextdefsym, nextdefsym, iundefsym, nundefsym, tocoff, ntoc, modtaboff, nmodtab, extrefsymoff, nextrefsyms, indirectsymoff, nindirectsyms, extreloff, nextrel, locreloff, nlocrel) ⇒ LC_DYSYMTAB

Returns a new instance of LC_DYSYMTAB.



361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
# File 'lib/odinflex/mach-o.rb', line 361

def initialize cmd,
  size,
  ilocalsym,
  nlocalsym,
  iextdefsym,
  nextdefsym,
  iundefsym,
  nundefsym,
  tocoff,
  ntoc,
  modtaboff,
  nmodtab,
  extrefsymoff,
  nextrefsyms,
  indirectsymoff,
  nindirectsyms,
  extreloff,
  nextrel,
  locreloff,
  nlocrel
  super(cmd, size)

  @ilocalsym      = ilocalsym
  @nlocalsym      = nlocalsym
  @iextdefsym     = iextdefsym
  @nextdefsym     = nextdefsym
  @iundefsym      = iundefsym
  @nundefsym      = nundefsym
  @tocoff         = tocoff
  @ntoc           = ntoc
  @modtaboff      = modtaboff
  @nmodtab        = nmodtab
  @extrefsymoff   = extrefsymoff
  @nextrefsyms    = nextrefsyms
  @indirectsymoff = indirectsymoff
  @nindirectsyms  = nindirectsyms
  @extreloff      = extreloff
  @nextrel        = nextrel
  @locreloff      = locreloff
  @nlocrel        = nlocrel
end

Instance Attribute Details

#extrefsymoffObject (readonly)

Returns the value of attribute extrefsymoff.



342
343
344
# File 'lib/odinflex/mach-o.rb', line 342

def extrefsymoff
  @extrefsymoff
end

#extreloffObject (readonly)

Returns the value of attribute extreloff.



342
343
344
# File 'lib/odinflex/mach-o.rb', line 342

def extreloff
  @extreloff
end

#iextdefsymObject (readonly)

Returns the value of attribute iextdefsym.



342
343
344
# File 'lib/odinflex/mach-o.rb', line 342

def iextdefsym
  @iextdefsym
end

#ilocalsymObject (readonly)

Returns the value of attribute ilocalsym.



342
343
344
# File 'lib/odinflex/mach-o.rb', line 342

def ilocalsym
  @ilocalsym
end

#indirectsymoffObject (readonly)

Returns the value of attribute indirectsymoff.



342
343
344
# File 'lib/odinflex/mach-o.rb', line 342

def indirectsymoff
  @indirectsymoff
end

#iundefsymObject (readonly)

Returns the value of attribute iundefsym.



342
343
344
# File 'lib/odinflex/mach-o.rb', line 342

def iundefsym
  @iundefsym
end

#locreloffObject (readonly)

Returns the value of attribute locreloff.



342
343
344
# File 'lib/odinflex/mach-o.rb', line 342

def locreloff
  @locreloff
end

#modtaboffObject (readonly)

Returns the value of attribute modtaboff.



342
343
344
# File 'lib/odinflex/mach-o.rb', line 342

def modtaboff
  @modtaboff
end

#nextdefsymObject (readonly)

Returns the value of attribute nextdefsym.



342
343
344
# File 'lib/odinflex/mach-o.rb', line 342

def nextdefsym
  @nextdefsym
end

#nextrefsymsObject (readonly)

Returns the value of attribute nextrefsyms.



342
343
344
# File 'lib/odinflex/mach-o.rb', line 342

def nextrefsyms
  @nextrefsyms
end

#nextrelObject (readonly)

Returns the value of attribute nextrel.



342
343
344
# File 'lib/odinflex/mach-o.rb', line 342

def nextrel
  @nextrel
end

#nindirectsymsObject (readonly)

Returns the value of attribute nindirectsyms.



342
343
344
# File 'lib/odinflex/mach-o.rb', line 342

def nindirectsyms
  @nindirectsyms
end

#nlocalsymObject (readonly)

Returns the value of attribute nlocalsym.



342
343
344
# File 'lib/odinflex/mach-o.rb', line 342

def nlocalsym
  @nlocalsym
end

#nlocrelObject (readonly)

Returns the value of attribute nlocrel.



342
343
344
# File 'lib/odinflex/mach-o.rb', line 342

def nlocrel
  @nlocrel
end

#nmodtabObject (readonly)

Returns the value of attribute nmodtab.



342
343
344
# File 'lib/odinflex/mach-o.rb', line 342

def nmodtab
  @nmodtab
end

#ntocObject (readonly)

Returns the value of attribute ntoc.



342
343
344
# File 'lib/odinflex/mach-o.rb', line 342

def ntoc
  @ntoc
end

#nundefsymObject (readonly)

Returns the value of attribute nundefsym.



342
343
344
# File 'lib/odinflex/mach-o.rb', line 342

def nundefsym
  @nundefsym
end

#tocoffObject (readonly)

Returns the value of attribute tocoff.



342
343
344
# File 'lib/odinflex/mach-o.rb', line 342

def tocoff
  @tocoff
end

Class Method Details

.from_io(cmd, size, offset, io) ⇒ Object



338
339
340
# File 'lib/odinflex/mach-o.rb', line 338

def self.from_io cmd, size, offset, io
  new(cmd, size, *io.read(SIZE).unpack('L18'))
end

Instance Method Details

#dysymtab?Boolean

Returns:

  • (Boolean)


403
# File 'lib/odinflex/mach-o.rb', line 403

def dysymtab?; true; end