Security and Cryptography
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsSystem AdministrationSecurity and Cryptography

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old May 9th, 2011, 05:07 PM
Devicated Devicated is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: May 2011
Posts: 1 Devicated User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 17 m 25 sec
Reputation Power: 0
Crypto Protocol Evaluation - Please check my protocol

Hello everyone,

Lately cryptography has taken my interest and I've been fiddling around with some hobby projects.
Say I want to secure internet traffic between two users, a client and a server. I want to eliminate man-in-the-middle attacks.

This is what I came up with:

The client has the public key of the signer. The server has the private key.
When a client connects to the server, it requests the certificate.
The server then sends a certificate, including a (client-specific? please confirm) public key and a message digest.
The public key is plain text. The message digest is encrypted with the private signer key. ECC (Elliptical Curve Cryptography) seems to be a strong algorithm, but if it's too complex I can still use RSA of course.
The client receives the certificate and checks its authenticity by decrypting the message digest.
It then checks if the message digest is equal to the message digest independently generated from the certificate, client-side.

Now, Client->Server traffic is secured. Server->Client is not.
The client now generates a random array of bytes. It sends this to the server. This is our symmetrical key for an algorithm like AES.
Now, Client->Server traffic is secured, AND Server->Client is secured.

My question: am I missing something? It sounds too good to be true, especially because there are far more complex systems like DSA/ECDSA, of which I don't really understand the advantage.
Of course I could be completely wrong, if so, please tell me why and explain me 'the answer'. I'm still very new to this cryptography thing so be gentle

Thanks

Reply With Quote
  #2  
Old June 6th, 2011, 09:20 PM
AstroTux AstroTux is offline
Contributing User
Dev Shed Novice (500 - 999 posts)
 
Join Date: Feb 2008
Posts: 593 AstroTux User rank is Sergeant Major (2000 - 5000 Reputation Level)AstroTux User rank is Sergeant Major (2000 - 5000 Reputation Level)AstroTux User rank is Sergeant Major (2000 - 5000 Reputation Level)AstroTux User rank is Sergeant Major (2000 - 5000 Reputation Level)AstroTux User rank is Sergeant Major (2000 - 5000 Reputation Level)AstroTux User rank is Sergeant Major (2000 - 5000 Reputation Level) 
Time spent in forums: 5 Days 21 m 29 sec
Reputation Power: 42
You basically described SSL; using asymmetric cipher (e.g. RSA) to exchange a session key for a symmetric cipher (e.g. AES) that will be used to secure the bulk of the communications.

Be sure you pad, etc.. correctly. Unpadded RSA is breakable, especially if the message is shorter than the key length.

You could also use Diffie-Hellman for the key exchange, though you'll need to check the security status of it.

Best regards,
AstroTux.

Reply With Quote
Reply

Viewing: Dev Shed ForumsSystem AdministrationSecurity and Cryptography > Crypto Protocol Evaluation - Please check my protocol

Developer Shed Advertisers and Affiliates



Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap