Инструмент для выполнения сценария оболочки

Правильное решение состоит в том, чтобы использовать ntlm_auth программу от более свежего распределения самбы: самба 3.4 и самба 3.5, кажется, аутентифицируют Win7 с NTLMv2 без проблем. Samba 3.0 не мог сделать это.

0
задан 15 November 2012 в 07:14
2 ответа

use plink (http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html), you also can use putty to execute the ssh command but you can't get the output.

C:\>plink.exe -ssh root@1.1.1.1 -pw mypassword uptime
06:40:58 up 50 days,  3:30,  8 users,  load average: 0.00, 0.07, 0.10

C:\>plink.exe -ssh root@1.1.1.1 -pw mypassword uptime > output.txt

C:\>type output.txt
06:41:45 up 50 days,  3:31,  8 users,  load average: 0.00, 0.06, 0.09

execute script

C:\>type cmd.txt
uptime

C:\>plink.exe -ssh root@1.1.1.1 -pw mypassword -m cmd.txt
06:41:45 up 50 days,  3:31,  8 users,  load average: 0.00, 0.06, 0.09
1
ответ дан 4 December 2019 в 21:34

You can just use PuTTY. Just create a saved session using SSH which executes the script on the server. It will SSH into the sever, execute the script, and display the output.

0
ответ дан 4 December 2019 в 21:34

Теги

Похожие вопросы