Re: Public Key Authentication with C++ Builder 6 - WeOnlyDo Discussion board

Re: Public Key Authentication with C++ Builder 6 (General questions)

by David Lucas, Thursday, July 21, 2005, 16:51 (6857 days ago) @ wodSupport

David,

one small note. Instead of passing binary data using SafeArray, you can pass reference to wodKeys component to PrivateKey property! So, use also VARIANT, but put LPDISPATCH inside (you would put ClientKey there) and pass it to wodSSH - that should be the best (and cleanest) way.

Do you have any example code detailing how to do this? My COM knowledge is extremely limited.

I'm having a hard time trying to work out how to load a private key without calling the Load method on TKeys (our Keys will be stored in a database and I'm trying to avoid having to write the keys to file simply to read them in using the Load method).

I assume you can simply set the TKeys::PrivateKey property, but I'm not sure what format it expects the data to be in (i.e. Am I supposed to remove control characters? The -----BEGIN RSA PRIVATE KEY----- tags? Etc).


Regards,

David Lucas
Data Track Technology


Complete thread: