Page 1 of 1
SSH server users question
Posted: Wed 17 Feb 2016 02:14
by snorkel
Do you have to use the built in user list?
I have a indy 10 ftp server app and it has a onuserlogon and I validate the users against a database, now I would like to add sftp server support and use the same database for user auth, is it possible to do this with the secure bridge sftp server component?
Re: SSH server users question
Posted: Tue 23 Feb 2016 14:34
by ViktorV
To verify a user by password, you can use the TScStorage.OnCheckUserPass event handler. See more details about this event in SecureBridge help:
https://www.devart.com/sbridge/docs/tsc ... erpass.htm
Re: SSH server users question
Posted: Wed 24 Feb 2016 06:16
by snorkel
Hi,
Yes I know about that method, but the issue is it appears the user has to be defined in the local storage first correct?
Re: SSH server users question
Posted: Wed 24 Feb 2016 06:26
by snorkel
What would be really nice is if SB had a Database storage option, for example you could have the DB storage option tied to a TDatasource and that way you could use any database, i.e. SQLite,PostgresQL etc.
ProFTPd does something similar and they define a table structure, but you can use a view to translate/map your existing DB structure to the one they require.
Re: SSH server users question
Posted: Wed 24 Feb 2016 10:59
by ViktorV
When using the TScStorage.OnCheckUserPass event handler to verify user by password, a user may be undefined in TScStorage.
Re: SSH server users question
Posted: Thu 25 Feb 2016 18:28
by snorkel
Thanks for the info

Re: SSH server users question
Posted: Fri 26 Feb 2016 10:45
by ViktorV
If you have any questions during using our products, please don't hesitate to contact us - and we will try to help you solve them.
Re: SSH server users question
Posted: Sat 27 Feb 2016 15:40
by snorkel
Thanks
I have both the checkPass and checkKey events both working from my database perfectly,
I store the users public key in a table and then import it into a key from a stream and then compare it to the key passed by the client.
only issue as I mentioned in another post is the OncheckKey is being fired twice the first time it fires the session data obj is nil, then on the second fire it's populated from the first time still.
Re: SSH server users question
Posted: Wed 02 Mar 2016 16:39
by ViktorV
Please don't duplicate posts in different topics. I answered you at the topic:
http://forums.devart.com/viewtopic.php?f=27&t=33288