node/lib/metasm/metasm/exe_format/elf_decode.rb
def decode_program_header(off = @header.phoff)
		raise InvalidExeFormat, "Invalid elf program header size: #{@header.phentsize}" if Segment.size(self) != @header.phentsize
		@encoded.add_export new_label('program_header'), off
		@encoded.ptr = off
		@segments = []
		@header.phnum.times { @segments << Segment.decode(self) }

		if @header.entry != 0
			add_label('entrypoint', @header.entry)
		end
	end
# decodes the program header table
# marks the elf entrypoint as an export of +self.encoded+
decodes the program header table
marks the elf entrypoint as an export of +self.encoded+
decodes the program header table marks the elf entrypoint as an export of + self . encoded +
def decode_program_header(off = @header.phoff)
		raise InvalidExeFormat, "Invalid elf program header size: #{@header.phentsize}" if Segment.size(self) != @header.phentsize
		@encoded.add_export new_label('program_header'), off
		@encoded.ptr = off
		@segments = []
		@header.phnum.times { @segments << Segment.decode(self) }
		if @header.entry != 0
			add_label('entrypoint', @header.entry)
		end
	end
def decode_program_header ( off = @header . phoff ) raise InvalidExeFormat , "Invalid elf program header size: #{@header.phentsize}" if Segment . size ( self ) != @header . phentsize @encoded . add_export new_label ( 'program_header' ) , off @encoded . ptr = off @segments = [ ] @header . phnum . times { @segments << Segment . decode ( self ) } if @header . entry != 0 add_label ( 'entrypoint' , @header . entry ) end end
decodes the program header table
marks the elf entrypoint as an export of +self.encoded+
decodes the program header table marks the elf entrypoint as an export of + self . encoded +
off
phoff