Results 1 to 10 of 40

Thread: Reverse Engineering References

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #38
    Codesaurus Skarma's Avatar
    Join Date
    Apr 2009
    Location
    Columbus, OH
    Posts
    227

    Re: [INFO] Reverse Engineering References

    Reversed from Halo CE 1.08 using OllyDbg, IDA Pro, Hexrays, and msdn.

    Calculates a Crc32 from the inputed buffer, the buffer length, and the current Crc32 value. It first checks if a Crc32 lookup table has been created, then uses it in calculating the Crc32.

    Code:
    //----- (004D37E0) --------------------------------------------------------
    bool *Crc32TableInit = (bool *)0x006B4CA0;
    DWORD *Crc32Table = (DWORD *)0x00652968; // 256 dwords
     
    void CalcCrc32(DWORD *Crc32, constchar *Buffer, DWORD Length)
    {
     DWORD Crc = *Crc32;
     
     if(!*Crc32TableInit)
     {
       InitCrc32Table(Crc32Table);
       *Crc32TableInit = true;
     }
     
     for(DWORD i = 0; i < Length; i++)
     {
       Crc = (*Crc32 >> 8) ^ Crc32Table[(*Buffer++ ^ *Crc32) & 0xFF];
     }
     
     *Crc32 = Crc;
    }
    Last edited by Skarma; October 28th, 2009 at 11:00 PM.
    Reply With Quote

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •