Does anyone know adress for ASM implementation of DES ? I have found this ones but when I try
program crashes. DESencrypt DESdecrypt Any help will be appreciated.
.data mypass db "password",0 szName db 32h dup(?) output db 1000 dup(?) .code invoke GetDlgItemText, _hWin, EDIT_NAME, ADDR szName, 32h invoke des_encrypt addr mypass addr szName,eax,addr output
In the des-enc.asm file, there is the line: "mov ebx, " You push eax onto the stack, and eax is a number between 0-31. You are trying to access a memory location that you shouldn't. You need to change your code to the following:
Either that, or change the des-enc.asm so it uses len directly, rather than as a pointer. Mirno
.data mypass db "password",0 szName db 32h dup(?) output db 1000 dup(?) length dd ? .code invoke GetDlgItemText, _hWin, EDIT_NAME, ADDR szName, 32h mov length, eax invoke des_encrypt, addr mypass, addr szName, addr length, addr output
I have tried but code dies at this location
Thanks for the reply
sub_4A6F38 proc near ... shr ebx, 3 movzx eax, byte ptr ;Here access violation and esi, eax jbe short loc_4A6F5B
I'm not a pro at this but I believe you can't do this: mov eax,byte ptr ;eax on both sides Try using another register for this: mov edx,byte ptr
Now, I've been messing around with linux for the past FOO hours, and my head is starting to spin around, and stuff. But using EAX on both sides shouldn't be any problem. But as I have been messing with linux for so long, I might be wrong :]. I'd try to boost the buffer sizes (a lot) and see if that doesn't help. "A friend of the devil is a friend of mine" - that's PIG, isn't it? :)
I dont know about the exception in the encryption routine, but you can use eax on both sides. There are some encyption routines (Square, Des...) that could easily to converted to pure assembly as they are written in inline c/asm. http://www.scramdisk.clara.net/
Good to know that you can.. oh well.. /me shruggs.
...that's PIG, isn't it?huh? ;)
Anyway, why do you want to use DES? Unless you have to use it for some existing data, or to interface with something that requires DES, I'd suggest you to use something different, like blowfish or twofish or IDEA. DES is slower and more unsafe than the other algorithms. JimmyClif: where does the "a friend of the devil is a friend of mine" originate from? Pig (excellent music :D) uses the quote in one of his songs, http://www.energizerpro.com/users/zolnoff/bands/Pig/Pig-No_One_Gets_Out_Of_Her_Alive.html
f0dder, This is from Grateful Dead.. I'm sorry but I didn't take your question serious at first *hehehe* as it's probably one of their most famous songs ;P (and I never heard of PIG either before) *g* Homepage: http://www.dead.net Lyrics: http://arts.ucsc.edu/GDead/AGDL/fotd.html
I know that Blowfish or twofish ismore secure than DES or make MD5 has then blowfish.However I just need to encrypt with DES I have MD5 and Blowfish asm implementation but not DES.I have found couple of DES implementation in C but I cant convert it :(
Please LaptoniC, can you send me your Blowfish and MD5 asm implementation please (at least blowfish ^^) ? I would really appreciate it... :) Thanks in advance. Happy coding. This message was edited by Readiosys, on 5/21/2001 12:13:59 PM
MD5 algo is on Iczelion's site already.For blowfish check out Egoiste's Website. Although his nick is egoiste his sources are awesome :)
Ok, i already knew these sources... i just thought it was an other implementation... :) Anyway... thanks a lot :).