flat assembler
Message board for the users of flat assembler.

Index > Main > DES/3DES in assembly

Author
Thread Post new topic Reply to topic
Tomasz Grysztar



Joined: 16 Jun 2003
Posts: 7734
Location: Kraków, Poland
Tomasz Grysztar
Has anyone tried implementing DES/3DES in assembly? I need one, and was going to do it myself, but just thought it would be good to check if someone got it already.
Post 25 Jul 2006, 15:02
View user's profile Send private message Visit poster's website Reply with quote
vid
Verbosity in development


Joined: 05 Sep 2003
Posts: 7105
Location: Slovakia
vid
boss says DES is not safe anymore... and that you should use AES
Post 25 Jul 2006, 15:18
View user's profile Send private message Visit poster's website AIM Address MSN Messenger ICQ Number Reply with quote
Tomasz Grysztar



Joined: 16 Jun 2003
Posts: 7734
Location: Kraków, Poland
Tomasz Grysztar
Not that I have choice. Wink
It's for SmartCards, BTW.

PS. As for AES/Rijandel, we've got it already on the board somewhere...
Post 25 Jul 2006, 15:50
View user's profile Send private message Visit poster's website Reply with quote
vid
Verbosity in development


Joined: 05 Sep 2003
Posts: 7105
Location: Slovakia
vid
ummm, some HW-close smartcard driver coding? mmmmmmm....

Wink
Post 25 Jul 2006, 16:06
View user's profile Send private message Visit poster's website AIM Address MSN Messenger ICQ Number Reply with quote
f0dder



Joined: 19 Feb 2004
Posts: 3170
Location: Denmark
f0dder
Tomasz, try looking for "john the ripper", a unix password cracker... it has some DES routines that should be very optimized, or so it's said.
Post 25 Jul 2006, 16:12
View user's profile Send private message Visit poster's website Reply with quote
Reverend



Joined: 24 Aug 2004
Posts: 408
Location: Poland
Reverend
There are lots of crypto implementations on Witeg's site. All are in masm, but written very, very well and thus easy to make fasm-compilable. There's no DES/3DES, but I found:
Quote:
NewDES (SRC) 2.82 KB NewDES algo (anything like a new version of DES... and weaker than DES)
Post 25 Jul 2006, 18:55
View user's profile Send private message Visit poster's website Reply with quote
Tomasz Grysztar



Joined: 16 Jun 2003
Posts: 7734
Location: Kraków, Poland
Tomasz Grysztar
I found some here, but it's GAS syntax, which is strange enough that I finally done it myself. Wink
It's far from being optimized but at least it appears to be working, and that's enough for me right now.

I'm attaching it here in case of someone else searching for such solution. Note: the provided functions encode/decode just 64-bit blocks given in EDX:EAX. But it should easy to put them in a loop (combined with XOR operation for CBC) to make larger encodings.


Description: DES/3DES routines in fasm, 32-bit, with Win32 demonstration skeleton.
Download
Filename: des.asm
Filesize: 16.41 KB
Downloaded: 317 Time(s)

Post 26 Jul 2006, 00:03
View user's profile Send private message Visit poster's website Reply with quote
f0dder



Joined: 19 Feb 2004
Posts: 3170
Location: Denmark
f0dder
When you get the need for speed, google for "DES bitslice", and perhaps add MMX or DES to the party too Smile
Post 26 Jul 2006, 08:09
View user's profile Send private message Visit poster's website Reply with quote
Ivan2k2



Joined: 08 Sep 2004
Posts: 80
Location: Russia, Angarsk
Ivan2k2
try this DES, it's masm syntax


Description:
Download
Filename: des.zip
Filesize: 5.05 KB
Downloaded: 258 Time(s)

Post 26 Jul 2006, 08:56
View user's profile Send private message ICQ Number Reply with quote
Ivan2k2



Joined: 08 Sep 2004
Posts: 80
Location: Russia, Angarsk
Ivan2k2
Post 26 Jul 2006, 14:14
View user's profile Send private message ICQ Number Reply with quote
Vasilev Vjacheslav



Joined: 11 Aug 2004
Posts: 392
Vasilev Vjacheslav
check this ftp's for crypto-information and ready algorithms in c++/c:
ftp.funet.fi
ftp.zedz.net


Description: drizz implementation
Download
Filename: mmx_des.zip
Filesize: 49.01 KB
Downloaded: 212 Time(s)

Description: x3chun implementation
Download
Filename: desx.zip
Filesize: 4.16 KB
Downloaded: 214 Time(s)

Description: x3chun implementation
Download
Filename: des.zip
Filesize: 5.74 KB
Downloaded: 215 Time(s)


_________________
[not enough memory]
Post 27 Jul 2006, 05:37
View user's profile Send private message Reply with quote
Vasilev Vjacheslav



Joined: 11 Aug 2004
Posts: 392
Vasilev Vjacheslav
and another


Description: witeg implementation
Download
Filename: newdes2.zip
Filesize: 2.82 KB
Downloaded: 216 Time(s)

Description: x3chun implementation
Download
Filename: newdes1.zip
Filesize: 1.52 KB
Downloaded: 215 Time(s)


_________________
[not enough memory]
Post 27 Jul 2006, 05:39
View user's profile Send private message Reply with quote
weiss



Joined: 03 Jan 2006
Posts: 25
weiss
Post 02 Aug 2006, 09:37
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2020, Tomasz Grysztar. Also on YouTube, Twitter.

Website powered by rwasa.