KpyM Telnet/SSH Server - Forum
Run server NOT as service?
Chris Run server NOT as service?
 
I would like to run the SSH server, but in my instance I can not run it as a service. I have another application that controls execution of EXE processes and would just like to run it this way.

Any trick?

I know this is an odd request.


Kroum Grigorov
 
Hi,
There is no good way to run KTS as standalone app, the reason is that in windows an application needs to have system privileges to validate another user password and to start a program as another user.

However there is "debug" mode that allows you to run KTS as standart application, as it name says I use it to debug KTS so I can strongly recommend you [b:4ec2bb60df]NOT[/b:4ec2bb60df] to use KTS that way.

Anyway if you still want to use KTS in debug mode here is what you need to do:

1) as there is no way KTS to validate passwords you need to implement your own password authentication

in the file: [b:4ec2bb60df].\scripts\allusers.bat[/b:4ec2bb60df] place these lines
[code:1:4ec2bb60df]set /p passphrase=Enter passphrase:
if not "%passphrase%" == "log_me_in" exit[/code:1:4ec2bb60df]
this will prompt the user "Enter passphrase:" and exit session if he doesn't enter the correct one, log_me_in in this case.

2) it is good to disable ctrl+c, or someone could skip the custom pass protection by pressing ctrl+c

in file: [b:4ec2bb60df].\telnet.ini[/b:4ec2bb60df] set
[code:1:4ec2bb60df]ctrl_c_enabled = 0[/code:1:4ec2bb60df]

3) and now as we don't validate passwords we don't need the pass prompt.

To disable it in file: [b:4ec2bb60df].\kts.ini[/b:4ec2bb60df] set
[code:1:4ec2bb60df]default_pass = sdfsdf[/code:1:4ec2bb60df]

4) finally start KTS in "debug" mode by typing:

[b:4ec2bb60df]telnetd.exe -debug[/b:4ec2bb60df]

Kroum


 

© 2007 - 2008 Kroum Grigorov
Powered by phpBB © 2001, 2005 phpBB Group