Tuesday, June 12, 2007

OpenSSH for Windows

packge i ke dar site http://sshwindows.sourceforge.net/ saakhte shode dar vaghe ye OpenSSH e minimal e ke dar cygwin ejra mishe , montaha ehtiaj be cygwin e kamel nadare.
ba in link download kardamesh : http://heanet.dl.sourceforge.net/sourceforge/sshwindows/setupssh381-20040709.zip
bad az unzip kardan o install kardan, config esh kardam :

C:\>cd "c:\Program Files\OpenSSH"
C:\Program Files\OpenSSH>cd bin
C:\Program Files\OpenSSH\bin>mkgroup -l >> ..\etc\group
C:\Program Files\OpenSSH\bin>mkpasswd -l -u Administrator > ..\etc\passwd
C:\Program Files\OpenSSH\bin>net start opensshd

khob windows e dige, labod bad az installation bayad ye bar restart ham beshe, jahhanam.

khob hala az ye linux behesh connect misham :

root@Slack:~# ssh Administrator@172.16.20.254

****USAGE WARNING****

This is a private computer system. This computer system, including all
related equipment, networks, and network devices (specifically including
Internet access) are provided only for authorized use. This computer system
may be monitored for all lawful purposes, including to ensure that its use
is authorized, for management of the system, to facilitate protection against
unauthorized access, and to verify security procedures, survivability, and
operational security. Monitoring includes active attacks by authorized entities
to test or verify the security of this system. During monitoring, information
may be examined, recorded, copied and used for authorized purposes. All
information, including personal information, placed or sent over this system
may be monitored.

Use of this computer system, authorized or unauthorized, constitutes consent
to monitoring of this system. Unauthorized use may subject you to criminal
prosecution. Evidence of unauthorized use collected during monitoring may be
used for administrative, criminal, or other adverse action. Use of this system
constitutes consent to monitoring for these purposes.


Administrator@172.16.20.254's password:
Microsoft Windows 2000 [Version 5.00.2195]
(C) Copyright 1985-2000 Microsoft Corp.

C:\Documents and Settings\Administrator>



mashalla ajab tam-taraaghi am dare .... ;)

hala ye test dige ba scp, masalan ye file o copy mikonam tu drive D:\mp3 :


root@172.16.20.254's password:
root@Slack:~# scp dela_didi.mp3 Administrator@172.16.20.254:/cygdrive/d/mp3

****USAGE WARNING****

This is a private computer system. This computer system, including all
related equipment, networks, and network devices (specifically including
Internet access) are provided only for authorized use. This computer system
may be monitored for all lawful purposes, including to ensure that its use
is authorized, for management of the system, to facilitate protection against
unauthorized access, and to verify security procedures, survivability, and
operational security. Monitoring includes active attacks by authorized entities
to test or verify the security of this system. During monitoring, information
may be examined, recorded, copied and used for authorized purposes. All
information, including personal information, placed or sent over this system
may be monitored.

Use of this computer system, authorized or unauthorized, constitutes consent
to monitoring of this system. Unauthorized use may subject you to criminal
prosecution. Evidence of unauthorized use collected during monitoring may be
used for administrative, criminal, or other adverse action. Use of this system
constitutes consent to monitoring for these purposes.


Administrator@172.16.20.254's password:
dela_didi.mp3 100% 13MB 733.6KB/s 00:18
root@Slack:~#


khob be salamti copy shod.....

man az in "USAGE WARNING" be khatere in rude derazi kardanesh aslan khosham nemiyaaaad ,.......khob hazfesh mikonam, naale nadare ke :


C:\>cd "c:\Program Files\OpenSSH"
C:\Program Files\OpenSSH>cd etc
C:\Program Files\OpenSSH\etc>edit sshd_config


bad miram un khatti ro ke ba kalameye "Banner" shuru mishe "hash mark"mizaram,
(ya be ghole yeki az bache ha : "PASH MARK" mizaram :)) ) , mishe in shekli :

#Banner /etc/banner.txt


bad service e opensshd o restart mikonam :

C:\Program Files\OpenSSH\etc>net stop opensshd
The OpenSSH Server service is stopping.
The OpenSSH Server service was stopped successfully.
C:\Program Files\OpenSSH\etc>net start opensshd
The OpenSSH Server service is starting.
The OpenSSH Server service was started successfully.


vaaaagheaaaan keeeeeeee, in pas chera restart nadare ???????????? =))
dar har hal ba stop/start kardan karam raah oftad.

hala test :


root@Slack:~# ssh Administrator@172.16.20.254
Administrator@172.16.20.254's password:
Last login: Wed Jun 13 09:16:07 2007 from 172.16.20.2
Microsoft Windows 2000 [Version 5.00.2195]
(C) Copyright 1985-2000 Microsoft Corp.

C:\Documents and Settings\Administrator>


Motshakkeram vaghean :">

No comments: