Jump to content
Tuts 4 You
Sign in to follow this  
ragdog

Drizz Cryptohash RCRC32

Recommended Posts

ragdog

Hello all


 


I try to use from Cryptohash library the RCRC32 procedur


gives any exmaple or info how to use it?


 


Regards,


Share this post


Link to post
kao

Just look at the source, it says all you need to know



RCRC32 proc uses ebx esi edi pData:dword,dwDataLen:dword,dwOffset:dword,dwWantCrc:dword

Quick sample app you can play with:



.486
.model flat, stdcall
option casemap:none
 
include windows.inc
include kernel32.inc
include cryptohash.inc 
includelib kernel32.lib
includelib cryptohash.lib
 
.DATA
 
dummyData db 021h, 03Ch, 061h, 072h, 063h, 068h, 03Eh, 00Ah, 02Fh, 020h, 020h, 020h, 020h, 020h, 020h, 020h
db 020h, 020h, 020h, 020h, 020h, 020h, 020h, 020h, 031h, 032h, 034h, 037h, 034h, 031h, 033h, 034h
db 031h, 034h, 020h, 020h, 020h, 020h, 020h, 020h, 020h, 020h, 020h, 020h, 020h, 020h, 020h, 020h
db 030h, 020h, 020h, 020h, 020h, 020h, 020h, 020h, 032h, 033h, 032h, 030h, 020h, 020h, 020h, 020h
db 020h, 020h, 060h, 00Ah, 000h, 000h, 000h, 079h, 000h, 000h, 012h, 0B0h, 000h, 000h, 012h, 0B0h
db 000h, 000h, 012h, 0B0h, 000h, 000h, 017h, 00Ah, 000h, 000h, 017h, 00Ah, 000h, 000h, 017h, 00Ah
db 000h, 000h, 017h, 00Ah, 000h, 000h, 06Ah, 090h, 000h, 000h, 06Ah, 090h, 000h, 000h, 06Ah, 090h
db 000h, 001h, 030h, 08Eh, 000h, 001h, 030h, 08Eh, 000h, 001h, 030h, 08Eh, 000h, 001h, 030h, 08Eh
db 000h, 001h, 081h, 03Ah, 000h, 001h, 081h, 03Ah, 000h, 001h, 081h, 03Ah, 000h, 001h, 097h, 0F8h
db 000h, 001h, 097h, 0F8h, 000h, 001h, 097h, 0F8h, 000h, 001h, 097h, 0F8h, 000h, 001h, 0ABh, 082h
db 000h, 001h, 0ABh, 082h, 000h, 001h, 0ABh, 082h, 000h, 001h, 0ABh, 082h, 000h, 001h, 0BEh, 0E8h
db 000h, 001h, 0BEh, 0E8h, 000h, 001h, 0BEh, 0E8h, 000h, 001h, 0BEh, 0E8h, 000h, 001h, 0DEh, 024h
db 000h, 001h, 0DEh, 024h, 000h, 001h, 0DEh, 024h, 000h, 001h, 0DEh, 024h, 000h, 001h, 0ECh, 0E8h
db 000h, 001h, 0ECh, 0E8h, 000h, 001h, 0ECh, 0E8h, 000h, 001h, 0ECh, 0E8h, 000h, 001h, 0FBh, 0A8h
db 000h, 001h, 0FBh, 0A8h, 000h, 001h, 0FBh, 0A8h, 000h, 001h, 0FBh, 0A8h, 000h, 002h, 011h, 0D6h
db 000h, 002h, 011h, 0D6h, 000h, 002h, 011h, 0D6h, 000h, 002h, 011h, 0D6h, 000h, 002h, 021h, 056h
db 000h, 002h, 021h, 056h, 000h, 002h, 021h, 056h, 000h, 002h, 021h, 056h, 000h, 002h, 036h, 006h
db 000h, 002h, 036h, 006h, 000h, 002h, 036h, 006h, 000h, 002h, 036h, 006h, 000h, 002h, 044h, 0A2h
db 000h, 002h, 044h, 0A2h, 000h, 002h, 044h, 0A2h, 000h, 002h, 083h, 0AAh, 000h, 002h, 085h, 0D0h
db 000h, 002h, 085h, 0D0h, 000h, 002h, 085h, 0D0h, 000h, 002h, 093h, 0AAh, 000h, 002h, 093h, 0AAh
db 000h, 002h, 093h, 0AAh, 000h, 002h, 0A2h, 0E6h, 000h, 002h, 0A2h, 0E6h, 000h, 002h, 0A6h, 05Ah
db 000h, 002h, 0A6h, 05Ah, 000h, 002h, 0A6h, 05Ah, 000h, 002h, 0ADh, 09Eh, 000h, 002h, 0ADh, 09Eh
db 000h, 002h, 0ADh, 09Eh, 000h, 002h, 0ADh, 09Eh, 000h, 002h, 0B7h, 066h, 000h, 002h, 0B7h, 066h
db 000h, 002h, 0B7h, 066h, 000h, 002h, 0B7h, 066h, 000h, 002h, 0C0h, 016h, 000h, 002h, 0C0h, 016h
db 000h, 002h, 0C0h, 016h, 000h, 002h, 0C0h, 016h, 000h, 002h, 0C5h, 0D6h, 000h, 002h, 0C5h, 0D6h
db 000h, 002h, 0C5h, 0D6h, 000h, 003h, 00Ch, 0B4h, 000h, 003h, 00Ch, 0B4h, 000h, 003h, 00Ch, 0B4h
db 000h, 003h, 00Ch, 0B4h, 000h, 003h, 040h, 016h, 000h, 003h, 041h, 09Eh, 000h, 003h, 043h, 018h
db 000h, 003h, 043h, 018h, 000h, 003h, 043h, 018h, 000h, 003h, 043h, 018h, 000h, 003h, 043h, 018h
db 000h, 003h, 043h, 018h, 000h, 003h, 043h, 018h, 000h, 003h, 0A8h, 068h, 000h, 003h, 0A8h, 068h
db 000h, 003h, 0A8h, 068h, 000h, 003h, 0C9h, 024h, 000h, 003h, 0C9h, 024h, 000h, 003h, 0C9h, 024h
db 000h, 003h, 0C9h, 024h, 000h, 003h, 0C9h, 024h, 000h, 003h, 0FCh, 0ACh, 000h, 003h, 0FCh, 0ACh
db 000h, 004h, 002h, 034h, 000h, 004h, 005h, 0C0h, 000h, 004h, 005h, 0C0h, 000h, 004h, 005h, 0C0h
dataSize EQU $-offset dummyData
.CODE
start:
        invoke RCRC32, offset dummyData, dataSize, 100h, 0BAD1DEAh
        invoke CRC32, offset dummyData, dataSize, INIT_CRC32
        invoke ExitProcess, 0
end start

Share this post


Link to post
ragdog

Thank you Kao


Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  
×
×
  • Create New...