ildasm for .net2.0的一处修正

来源:互联网 发布:java文明5安卓汉化版 编辑:程序博客网 时间:2024/05/22 13:55

ildasm2.0在检测System.Runtime.CompilerServices.SuppressIldasmAttribute时会拒绝反编译。

于是把这处检测给patch了。

顺便说一下,sscli的多么的爽,下面的代码分别是ida反汇编出的和sscli中的,对比下看看。

.text:0042FB93                 call    HasSuppressingAttribute(void)
.text:0042FB98                 test    alal
.text:0042FB9A                 jz      short loc_42FBE7
.text:0042FB9C                 cmp     int g_fDumpHeader, edi
.text:0042FBA2                 jz      short loc_42FBB5
.text:0042FBA4                 push    _iobuf * g_pFile
.text:0042FBAA                 push    IMAGE_COR20_HEADER * g_CORHeader
.text:0042FBB0                 call    DumpHeader(IMAGE_COR20_HEADER *,void *)
.text:0042FBB5
.text:0042FBB5 loc_42FBB5:                             ; CODE XREF: DumpFile(char *)+43Fj
.text:0042FBB5                 cmp     int g_fDumpMetaInfo, edi
.text:0042FBBB                 jz      short loc_42FBCC
.text:0042FBBD                 push    _iobuf * g_pFile ; int
.text:0042FBC3                 push    edi             ; int
.text:0042FBC4                 push    [ebp+103Ch+lpMultiByteStr] ; char *
.text:0042FBC7                 call    DumpMetaInfo(char *,char *,void *)
.text:0042FBCC
.text:0042FBCC loc_42FBCC:                             ; CODE XREF: DumpFile(char *)+458j
.text:0042FBCC                 push    1EEh            ; lpString
.text:0042FBD1                 call    RstrUTF(uint)
.text:0042FBD6                 push    eax             ; lpMultiByteStr
.text:0042FBD7                 push    _iobuf * g_pFile ; FILE *
.text:0042FBDD                 call    printError(void *,char *)
.text:0042FBE2                 jmp     loc_4305A3

 


 

    if(HasSuppressingAttribute())
    
{
        
if (g_fDumpHeader)
            DumpHeader(g_CORHeader,g_pFile);
        
if(g_fDumpMetaInfo) 
            DumpMetaInfo(pszFilename,NULL,g_pFile);
        printError(g_pFile,RstrUTF(IDS_E_SUPPRESSED));
        
goto CloseFileAndExit;
    }

 

真希望sscli继续出3.0!

下载去这里http://bbs.pediy.com/showthread.php?s=&threadid=37914