Re: Where to securely store encryption key?
- From: "Mitch Gallant" <jensigner@xxxxxxxxxxxxxxxx>
- Date: Tue, 12 Sep 2006 07:44:25 -0400
This is discussed in great detail in :
"Writing Secure Code", 2nd Edn. Howard et. al.
There is no way to securely store a key in software or in the OS used for
encryption.
You need some secret which is not stored in the file-system, registry etc...
Depending on if your software can prompt for the key, a solution is to use a
good strong password-derived symmetric key(again discussed in detail in book
above).
- Mitch Gallant
<harishashim@xxxxxxxxx> wrote in message
news:1158043709.597558.171600@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
I am using VC++ on VS .NET 2003 experimenting with various way of using
cryptography.
At the moment I am facing a paradox due to the following.
I have a secrete message. I want to encrypt this message using
symmetric algorithm let say AES. The encrypted message is accessible
to the user while the secrete message must stay secrete.
For this process I will need to specify a key for the encryption
process.Since my software need to do both encryption and decryption I
need to have the key available in my software.
The paradox here is that now I have to protect the key. So how should I
do this? I have consider the following together with the argument
against it.
1. Embed the key in the source code. Argument: Source code can be
reverse engineerd. The key will be known and can be used to decrypt the
encrypted message.
2. Save key in the filesystem, not encrypted. Argument: User can open
it, read the plain text key and use the key to decrypt the encrypted
message.
3. Save key in the filesystem, encrypted. Argument: If I do this, I
will have another key to secure. So this is chicken and egg situation.
4. Save key in registry. Argument: User with administrator access can
open it, read the key and use the key to decrypt the encrypted message.
I am fairly new to cryptography, please show me the way!
Thanks in advance.
*pst : At the moment hardware solution like smart card is out of the
question
.
- Follow-Ups:
- Re: Where to securely store encryption key?
- From: lelteto
- Re: Where to securely store encryption key?
- References:
- Where to securely store encryption key?
- From: harishashim
- Where to securely store encryption key?
- Prev by Date: Re: Where to securely store encryption key?
- Next by Date: Error code 0x800404b0 from CryptGetUserKey
- Previous by thread: Re: Where to securely store encryption key?
- Next by thread: Re: Where to securely store encryption key?
- Index(es):
Relevant Pages
|