Re: wodFtpDLX.NET - Certificate (General questions)
Hi Macy,
You can do something like this:
--------------------------------
Dim WithEvents ftp1 As WeOnlyDo.Client.FtpDLX
Dim keys As WODSSHKeyLib.Keys
Dim rsa As System.Security.Cryptography.RSACryptoServiceProvider
Dim cert As System.Security.Cryptography.X509Certificates.X509Certificate2
ftp1 = New WeOnlyDo.Client.FtpDLX
keys = New WODSSHKeyLib.Keys
cert = New System.Security.Cryptography.X509Certificates.X509Certificate2
rsa = New System.Security.Cryptography.RSACryptoServiceProvider
cert.Import( C:client.cer , your_password ,Security.Cryptography.X509Certificates.X509KeyStorageFlags.Exportable)
keys.Load( C:client.key , your_password ,Security.Cryptography.X509Certificates.X509KeyStorageFlags.Exportable)
rsa.FromXmlString(keys.ToXmlString(WODSSHKeyLib.SSHKeyTypes.RSAkey, True))
ftp1.Protocol = WeOnlyDo.Client.Protocols.FTPS
ftp1.Authentication = WeOnlyDo.Client.Authentications.Certificate
ftp1.Certificate = cert
ftp1.Hostname = your_hostname
ftp1.Login = your_username
ftp1.PrivateKey = rsa
ftp1.Blocking = True
ftp1.Connect()
--------------------------------
Hope this helps.
Regards,
Damba
Complete thread:
- wodFtpDLX.NET - Certificate - macy, 2006-10-26, 17:11
- Re: wodFtpDLX.NET - Certificate - wodDamir, 2006-11-01, 21:31
- Re: wodFtpDLX.NET - Certificate - wodSupport, 2006-11-01, 23:04
- Re: wodFtpDLX.NET - Certificate - Mike Cass, 2007-04-13, 16:07
- Re: wodFtpDLX.NET - Certificate - woddrazen, 2007-04-13, 16:18
- Re: wodFtpDLX.NET - Certificate - wodSupport, 2007-04-13, 20:58
- Re: wodFtpDLX.NET - Certificate - woddrazen, 2007-04-13, 16:18
- Re: wodFtpDLX.NET - Certificate - Mike Cass, 2007-04-13, 16:07
- Re: wodFtpDLX.NET - Certificate - wodSupport, 2006-11-01, 23:04
- Re: wodFtpDLX.NET - Certificate - wodDamir, 2006-11-01, 21:31