Authentication class - WeOnlyDo Discussion board

Authentication class (General questions)

by Jerome Airaudo, Tuesday, May 31, 2005, 15:29 (7115 days ago)

I'm evaluating .NET component in my application and it works fine with the authentication method login/password. I'd like now to try with the private key method and I have to set Authentication to Authentications.PrivateKey but I did not find the Authentications class in STFP package. I cannot set the parameter to the right value without this classe. Do you have a solution or did I miss something ?

Thanks a lot.

Re: Authentication class

by wodSupport, Tuesday, May 31, 2005, 16:15 (7115 days ago) @ Jerome Airaudo

Jerome,

look arround, there is wodKeyManager.NET component installed with wodSFTP.NET, where you can load/generate key and pass it's data to wodSFTP's PrivateKey property. It should be in same dir as WeOnlyDo.Client.SFTP.DLL file.

Re: Authentication class

by Jerome Airaudo, Tuesday, May 31, 2005, 16:28 (7115 days ago) @ wodSupport

Thanks.
I have this package in my application that allow me to load a private key but I can't specify to my SFTP object (SFTP.Authentication) to use PublicKey method because the Authentications class is not declared and even known in those 2 packages.
If you have anything else I'm very interrested.

Thanks a lot.

Re: Authentication class

by wodSupport, Tuesday, May 31, 2005, 16:34 (7115 days ago) @ Jerome Airaudo

Jerome,

ah, I think I know what bothers you. Authentications is not a class, but enumeration. Try doing

wodSFTP.Authentications = WeOnlyDo.Client.SFTP.Authentications.PublicKey

can you try that?

Re: Authentication class

by Jerome Airaudo, Tuesday, May 31, 2005, 17:17 (7115 days ago) @ wodSupport

That's the point. I cannot try this syntax because my development tools (which is Windev from PC SOFT) does not know this enumeration.
I use de .NET component through my tool.
Please, do you have any solutions ?

Thanks and thanks.

Re: Authentication class

by wodSupport, Tuesday, May 31, 2005, 18:48 (7115 days ago) @ Jerome Airaudo

Jerome,

I'm not familiar with this tool, but I don't think there are workarounds. This isn't like in old days where you could replace enumerated value with the number - NET doesn't allow that anymore, so you must use somehow this value. There's no replacement class or anything.

Re: Authentication class

by Jerome Airaudo, Thursday, June 02, 2005, 16:51 (7113 days ago) @ wodSupport

Thank you for all your answers.
I decided to use your ActivX/Component for SFTP, which works fine. I manage to generate keys, connect with login and password.
Now I'm trying to connect with private/public key, is there any restriction for this method with the evaluation version ?
It doesn't seem to load the private key and do not connect to my server. I've used putty and puttygen to use my private key with psftp.exe and it works, so I think it's not a big problem, only a misunderstanding from me.

There is a part of my source code :

Client is an Automation Object WeOnlyDo.wodSFTPCom.1
Key is an Automation Object WeOnlyDo.Keys.1

Client>>Hostname= my_host
Client>>Blocking = True
Client>>Resume = True
Key>>Load( privkey )
Client>>Authentication = 2 // Public key
Client>>PrivateKey = Key>>PrivateKey(0)
Client>>Connect()

Ferme

Thanks,

Jerome.

Re: Authentication class

by wodSupport, Thursday, June 02, 2005, 16:53 (7113 days ago) @ Jerome Airaudo

Jerome,

can you try to do this:

Client>>PrivateKey = Key


Re: Authentication class

by Jerome Airaudo, Thursday, June 02, 2005, 16:59 (7113 days ago) @ wodSupport

I've tried but I still have the same error message :

Please set login, and password/privatekey first

[:sad:] Jerome.

Re: Authentication class

by wodSupport, Thursday, June 02, 2005, 17:02 (7113 days ago) @ Jerome Airaudo

Did you set Login property?

Re: Authentication class

by Jerome Airaudo, Thursday, June 02, 2005, 17:12 (7113 days ago) @ wodSupport

Did you set Login property?

[:happy:]OK, shame on me, I'm sorry to have borred you with my smart questions. Your product is a very good one. I will send you a check in a few weeks, after finishing my tests.
To use the component (DLL) in the client environnement I need to register (in windows registry) the DLL right ?

Thanks and thanks a lot.