node/lib/metasm/metasm/cpu/ia32/decode.rb
def decode_instr_interpret(di, addr)
		if di.opcode.props[:setip] and di.instruction.args.last.kind_of? Expression and di.instruction.opname !~ /^i?ret/
			delta = di.instruction.args.last.reduce
			arg = Expression[[addr, :+, di.bin_length], :+, delta].reduce
			di.instruction.args[-1] = Expression[arg]
		end

		di
	end
# converts relative jump/call offsets to absolute addresses
# adds the eip delta to the offset +off+ of the instruction (may be an Expression) + its bin_length
# do not call twice on the same di !
converts relative jump/call offsets to absolute addresses
adds the eip delta to the offset +off+ of the instruction (may be an Expression) + its bin_length
do not call twice on the same di !
converts relative jump / call offsets to absolute addresses adds the eip delta to the offset + off + of the instruction ( may be an Expression ) + its bin_length do not call twice on the same di !
def decode_instr_interpret(di, addr)
		if di.opcode.props[:setip] and di.instruction.args.last.kind_of? Expression and di.instruction.opname !~ /^i?ret/
			delta = di.instruction.args.last.reduce
			arg = Expression[[addr, :+, di.bin_length], :+, delta].reduce
			di.instruction.args[-1] = Expression[arg]
		end
		di
	end
def decode_instr_interpret ( di , addr ) if di . opcode . props [ :setip ] and di . instruction . args . last . kind_of? Expression and di . instruction . opname !~ / ^i?ret / delta = di . instruction . args . last . reduce arg = Expression [ [ addr , :+ , di . bin_length ] , :+ , delta ] . reduce di . instruction . args [ - 1 ] = Expression [ arg ] end di end
converts relative jump/call offsets to absolute addresses
adds the eip delta to the offset +off+ of the instruction (may be an Expression) + its bin_length
do not call twice on the same di !
converts relative jump / call offsets to absolute addresses adds the eip delta to the offset + off + of the instruction ( may be an Expression ) + its bin_length do not call twice on the same di !
di
addr