Solved

file encryption/decryption solution

Posted on 2008-10-12
3
811 Views
Last Modified: 2008-10-27
Do you have any suggestion on encrypting data/configuration files ~1-5mb size (I need to encrypt the files at the server and the c++ client app running on users laptop downloads them via http) and key mangement? I might be able to get way with one set of keys for all clients. suitability of symmetric vs asymmetric, how to mange keys, specific implementations you could recomend. please share if you have any experience.
0
Comment
Question by:ponnen
  • 2
3 Comments
 
LVL 33

Expert Comment

by:Dave Howe
ID: 22705558
Well, files that size you are looking at symmetric - these days there is little reason NOT to use AES in CBC mode, except when the terminal client is very restrictive (certain mobile phones)

However, you are probably best to use a hybrid approach - this is the usual configuration for transporting files, where you in fact send the recipient two things; the first is the file and the second is the key -  which is randomly generated per file, then itself encrypted to the recipient's public key.

That said - you might find it easier and cleaner to just use https and transport the file entirely via that method; that way, the transport level libraries handle the crypto for you, and you need only worry about confirming your server key is correct and leave the rest to automation.
0
 

Author Comment

by:ponnen
ID: 22709336
Thanks Dave.
I need to keep them encrypted on the client as well so I am not looking at TLS (performance of transfer is the issue). Could you suggest API/tools to generate AES and could you elaborate on "CBS mode". Could I use openssl to generate AES key and use them with standard java crypto API ?. Are there c++/C# API's to do decryption given the key on the client side? Could anybody could point to an example... (s it too much to ask for :)

thanks.
0
 
LVL 33

Accepted Solution

by:
Dave Howe earned 250 total points
ID: 22709833
Usually, with java or C# it is recommended you use the much superior Bouncy Castle java libraries - they are compatible with openssl.

http://www.bouncycastle.org/

there are extensive examples given with the libraries.

CBC mode is one of the standard supported modes for AES - in effect, each block becomes dependent not only on the key but the box preceding it, which hides patterns that might be visible at the block level.

http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation gives a good overview, but tbh its easier to just read it as "EBC leaks data, CBC doesn't so use CBC"

0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

This paper addresses the security of Sennheiser DECT Contact Center and Office (CC&O) headsets. It describes the DECT security chain comprised of “Pairing”, “Per Call Authentication” and “Encryption”, which are all part of the standard DECT protocol.
By this time the large percentage of day-to-day transactions have shifted to mobile banking; here are some overriding areas QAs must investigate while testing mobile banking apps.  
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now