Installing FSTP & SSH Windows
Sumber :
Petunjuk kali ini saya menggunakan Windows 11
Using Command Line
-
Informasi instalasi Open SSH client dan server
Syntax
Get-WindowsCapability -Online | Where-Object Name -like 'OpenSSH*' # Output belum terinstall # Name : OpenSSH.Client~~~~0.0.1.0 # State : NotPresent # Name : OpenSSH.Server~~~~0.0.1.0 # State : NotPresent # Output jika sudah terinstall # Name : OpenSSH.Client~~~~0.0.1.0 # State : Installed # Name : OpenSSH.Server~~~~0.0.1.0 # State : Installed
-
Instal client dan server open ssh
-
Memulai service SSH
syntax
# Start the sshd service Start-Service sshd # OPTIONAL but recommended: Set-Service -Name sshd -StartupType 'Automatic' # Confirm the Firewall rule is configured. It should be created automatically by setup. Run the following to verify if (!(Get-NetFirewallRule -Name "OpenSSH-Server-In-TCP" -ErrorAction SilentlyContinue | Select-Object Name, Enabled)) { Write-Output "Firewall Rule 'OpenSSH-Server-In-TCP' does not exist, creating it..." New-NetFirewallRule -Name 'OpenSSH-Server-In-TCP' -DisplayName 'OpenSSH Server (sshd)' -Enabled True -Direction Inbound -Protocol TCP -Action Allow -LocalPort 22 } else { Write-Output "Firewall rule 'OpenSSH-Server-In-TCP' has been created and exists." } # Untuk menguji apakah service sudah running Get-Service sshd
-
Mematikan service !!! info "Syntax"
```PowerShell Stop-Service sshd ```
Using GUI
-
Untuk menginstall OpenSSH. Buka settings/system/Optional System.
Picture
-
Selanjutnya pilih view Optionals, lalu cari keyword OpenSSH, lalau tekan install.
Picture
Installed folder dan konfigurasi
Binary data terinnstall di %WINDIR%\System32\OpenSSH
. Sedangkan untuk konfigurasi file (sshd_config) dan hosts-keys terinstall di %ProgramData%\ssh
Setup chroot direktori
Buka %ProgramData%\ssh\sshd_config
. Lalu uncomment dan berikan nilai sebagai berikut ChrootDirectory "D:\Demo\SFTP-Interface"