Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Common Practice regarding Passwords in Memory

I am writing a .net(C#) windows application to store user passwords in it, like keypass, lastpass, roboforms etc.

To process the user data i have to keep it in memory this data also contains Passwords of the user.

Now my Questions are:

  1. Can someone read the Memory Data using some tool or memory dump?
  2. If yes then How? Can someone share such tool? i tried with CurrProcess, HeapViewer,ProcessExplorer and ProcessView applications but can't find any private data in memory dump,
  3. Do I need to learn something else to ensure the protection of in memory passwords.

Thanks

like image 213
Mubashar Avatar asked Feb 02 '11 10:02

Mubashar


People also ask

What is the best practice in storing passwords in a database?

Hash all passwords Never store passwords in plain text. Always create a hash from them and store the hash instead. In password storage, hashing is superior to encryption since a hash can't be reversed.

What is password management practices?

Password management is a set of principles and best practices to be followed by users while storing and managing passwords in an efficient manner to secure passwords as much as they can to prevent unauthorized access.

How are passwords commonly stored?

The main storage methods for passwords are plain text, hashed, hashed and salted, and reversibly encrypted. If an attacker gains access to the password file, then if it is stored as plain text, no cracking is necessary.


1 Answers

You are correct in your concerns, strings in memory are not safe.

You're probably looking for the SecureString class.

like image 194
Kobi Avatar answered Oct 06 '22 22:10

Kobi