Cryptography: What are the best strategies to store a encryption key on the computer?
-
I am developing a side project for supporting data encryption on Linux platform. My code encrypts the files using AES256CBC. (I am using OpenSSL Crypto API). The user can encrypt the files and at some later time can decrypt the files. An AES key is generated which I use to encrypt the files. The issue is I need to save the key somewhere so as to enable the user to decrypt the files at some later point in time. Currently I am saving the key in a text file which is hidden the home directory of the user and I am encrypting the file by another AES key which is generated using the password as one of the inputs. What are the best strategies to store a key securely on the local machine? Are there any standards for this? I have seen that some commercial encryption products from McAfee and Symantec use a sort of key store on the local machine to store encryption keys. The key store are also password protected. Any suggestions will be highly appreciated. P.S : I am looking for suggestion more from design point of view.
-
Answer:
While this might not answer your question, I just thought I'd share something I came across. In ARM devices there is something known as TrustZone technology which is the following: The Security Extensions, marketed as TrustZone Technology, is found in ARMv6KZ and later application profile architectures. It provides a low cost alternative to adding an additional dedicated security core to an SoC, by providing two virtual processors backed by hardware based access control. This enables the application core to switch between two states, referred to as worlds (to reduce confusion with other names for capability domains), in order to prevent information from leaking from the more trusted world to the less trusted world. This world switch is generally orthogonal to all other capabilities of the processor, thus each world can operate independently of the other while using the same core. Memory and peripherals are then made aware of the operating world of the core and may use this to provide access control to secrets and code on the device. (From Wikipedia) So if you manage your cryptographic keys only from the more trusted "secure world", which has a region of the memory mapped for itself with hardware support, no rootkit or any software of that sort could actually get access to your cryptographic keys. Again, I'm not an expert in this area. Just in my learning stage.
Sailesh Mukil at Quora Visit the source
Other answers
I suggest your use a security keystore (ie. PKCS12, Bouncycastle UBER) and protect it with a passphrase.
William Emmanuel Yu
If you are using Linux platform as a desktop, it is good to encrypt the keys using a pass phrase and setting up such a way that the password is used to decrypt the disk encryption key upon login.But, if your Linux system is unattended, then it is good to use bus-attached Hardware Security Modules or use Network attached HSMs in case you are deploying your Linux system as a VM in public or private clouds.
Ravi Chunduru
Related Q & A:
- What's the best way to get a job in a restaurant?Best solution by Yahoo! Answers
- What's the best way to make a good impression at a job interview?Best solution by Yahoo! Answers
- What are the best ways to find a job with a social entrepreneurial company?Best solution by answers.yahoo.com
- What are some good strategies for getting a job?Best solution by Quora
- What is the best way to negotiate a salary for a new position?Best solution by Yahoo! Answers
Just Added Q & A:
- How many active mobile subscribers are there in China?Best solution by Quora
- How to find the right vacation?Best solution by bookit.com
- How To Make Your Own Primer?Best solution by thekrazycouponlady.com
- How do you get the domain & range?Best solution by ChaCha
- How do you open pop up blockers?Best solution by Yahoo! Answers
For every problem there is a solution! Proved by Solucija.
-
Got an issue and looking for advice?
-
Ask Solucija to search every corner of the Web for help.
-
Get workable solutions and helpful tips in a moment.
Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.