944,009 Members | Top Members by Rank

Ad:
  • Assembly Discussion Thread
  • Unsolved
  • Views: 538
  • Assembly RSS
Oct 17th, 2009
0

need help how about assebly error

Expand Post »
i just want to ask how can i add a another value in this code
this is for educational purpose and im not familiar with asm
i know java programming but this is far different

mov eax,[000003E8+100] crash my system

honestly i dont know how to add in asm
any one can help me here

d97aede:
add eax,00
alloc(newmem,256)
label(returnhere)
0D97AC8C:
jmp newmem
nop
returnhere:
newmem:
label(empiesa)
label(setea)
label(sigue)
label(resetea)
alloc(Patiniox,4)
jmp empiesa
empiesa:
cmp [Patiniox],00000000
je setea
jmp sigue
setea:
mov [Patiniox],00000001
jmp empiesa
sigue:
inc [Patiniox]
cmp [Patiniox],00000004
je resetea
jmp d97ac92
resetea:
mov [Patiniox],00000000
jmp d97b2e4
alloc(newmem2,128)
label(returnhere2)
label(originalcode2)
label(exit2)
d97afb5:
jmp newmem2
nop
returnhere2:
newmem2: 
mov eax,000003E8 <-- this part of the code how am i able to add another 100 value here its 1000 so i want to add 100 
mov ecx,000003E8
originalcode2:
add esp,08
mov ecx,[edi+08]
exit2:
jmp returnhere2
Similar Threads
Reputation Points: 10
Solved Threads: 0
Newbie Poster
wilen is offline Offline
3 posts
since Oct 2009
Oct 18th, 2009
0
Re: need help how about assebly error
To change,
newmem2:
mov eax,0x3e8
so that EAX will be loaded with the value
0x3e8+0x100 replace with:
mov eax,0x3e8+0x100
This varient of mov instruction has immediate as the source
operand, and this has memory operand as source:
mov eax,[0x3e8+0x100]
Using a hardwired offset could cause an Access Violation.
Once you have a dissassembled source listing of a
executable image you can change offsets to labels
and add in any opcodes you wish.
Last edited by NotNull; Oct 18th, 2009 at 1:36 am.
Reputation Points: 36
Solved Threads: 19
Junior Poster
NotNull is offline Offline
198 posts
since Oct 2008
Oct 19th, 2009
0
Re: need help how about assebly error
thank's for the reply it works like a charm but you mention i could change offsets to label and add in any opcodes could you help me how to do that
Reputation Points: 10
Solved Threads: 0
Newbie Poster
wilen is offline Offline
3 posts
since Oct 2009

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in Assembly Forum Timeline: help with MIPS snprintf function?
Next Thread in Assembly Forum Timeline: Question about arrays





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC