Private key with passphrase

Discussion of open issues, suggestions and bugs regarding network security and data protection solution - SecureBridge
Post Reply
coolsmurf
Posts: 5
Joined: Tue 20 Nov 2012 18:54

Private key with passphrase

Post by coolsmurf » Tue 20 Nov 2012 19:00

Hi,

I have a private key encrypted with a passphrase. I want to use it to connect to the SSH server. To open the Key, I use the ImportFrom() method.

Code: Select all

TScKey* myKey = new TScKey(myFileStorage->Keys);
K->KeyName = "myKeyName";
K->ImportFrom("myEncryptedKey.ssl", "myPassword");
However, it seems that the TFileStorage component saves the uncrypted key in a file "myKeyName.key". Can I stop him from doing that ? All I want is to open my connection with the server. I don't want the key to be stored uncrypted like this on the computer. Is there a solution ?

Thanks in advance,

Dimon
Devart Team
Posts: 2910
Joined: Mon 05 Mar 2007 16:32

Re: Private key with passphrase

Post by Dimon » Tue 05 Feb 2013 13:19

To solve the problem, set the TScFileStorage.Password property to any nonempty password.

Post Reply