KpyM Telnet/SSH Server - Forum
security - deny command prompt
scott k security - deny command prompt
Hi, is there a way to prevent users from the command prompt, only allow the login script to start another program? -- I know there is "break off", exit, and other tricks... but it there a solid way in kpym to deny this no matter what?

Kroum Grigorov
You can set your program to be the login shell, you can do that by chaging the "shell_command" parameter in kts.ini file
For example:

shell_command = "ping.exe -t"

will set the ping command as the user shell, once the user breaks the ping command the KTS session will end


If you need to do that with a script you can change the "/K" switch of the %COMSPEC% to "/C" this will tell the command prompt to exit immediately after the script is executed

Again with the ping command:

shell_command = "%COMSPEC% /C "scripts\_test_.bat""

c:\program files\kts\scripts\_test_.bat
goto start1

Once the user breaks the script the session will end.


scott k

This is perfect, and works great, Thanks!



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