flat assembler
Message board for the users of flat assembler.
Index
> Windows > Strange way of assembling SetUnhandledExceptionFilter |
Author |
|
LocoDelAssembly 09 Jan 2012, 07:32
Quote:
Code: format pe gui 4.0 include 'win32a.inc' section '.code' code readable executable mov eax, [SetUnhandledExceptionFilter] int3 section '.import' readable writable data import library kernel32,'KERNEL32.DLL' import kernel32,\ SetUnhandledExceptionFilter,'SetUnhandledExceptionFilter' end data |
|||
09 Jan 2012, 07:32 |
|
Igor1024 09 Jan 2012, 08:33
Because SetUnhandledExceptionFilter doesn't launnch at debugger (that's a trick), I just put a couple of MessageBox's before and after calling this api, and when I launched the program I saw only first MB, then (after clicking ok, of course) Olly launched because of unhandled exception.
_________________ The God is real,unless he is declared as integer. |
|||
09 Jan 2012, 08:33 |
|
LocoDelAssembly 09 Jan 2012, 14:41
Could you provide the complete code you have used to see that SetUnhandledExceptionFilter is resolved as 0x402068?
|
|||
09 Jan 2012, 14:41 |
|
Igor1024 10 Jan 2012, 04:35
Ok, i understood the mistake - I got used to use 'invoke' macros and forgot that call apiname gives control to the place where address of these api is putten; should use call [apiname], that's right. /facepalm
|
|||
10 Jan 2012, 04:35 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.