How to troubleshoot Windows Defender Firewall for inbound ssh connections


Baeolophus

Member
Member
Local time
1:00 AM
Posts
94
Visit site
OS
macOS Sequoia
This post is trying to get a little more specific than yesterday’s “How to configure Windows Defender Firewall for ssh-tunneled VNC service” in this same forum. As indicated there, I followed the instructions at the Windows OS Hub on how to set up sshd on my Windows 11 system. Those instructions included PowerShell code for configuring the Firewall. The rule is present:

Screenshot 2024-10-02 at 11.12.00 AM.png

These are the three tabs of the properties for that rule:

Screenshot 2024-10-02 at 11.22.16 AM.pngScreenshot 2024-10-02 at 11.22.22 AM.pngScreenshot 2024-10-02 at 11.22.30 AM.png

This is what was set up by the PowerShell command from the referenced Windows OS Hub article

Powershell:
New-NetFirewallRule -Name sshd -DisplayName 'OpenSSH Server (sshd)' -Enabled True -Direction Inbound -Protocol TCP -Action Allow -LocalPort 22

On the same computer I can ssh into localhost:

Powershell:
PS C:\WINDOWS\system32> ssh localhost
The authenticity of host 'localhost (::1)' can't be established.
ED25519 key fingerprint is SHA256:/Di072mY1hj85CGr1vE+EOW/8bNCzXKw6Dv89QHDmwk.
This host key is known by the following other names/addresses:
    C:\Users\admin.PARALLELSM1MAX/.ssh/known_hosts:1: 192.168.1.34
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
Warning: Permanently added 'localhost' (ED25519) to the list of known hosts.
admin@localhost's password:
Microsoft Windows [Version 10.0.22631.4169]
(c) Microsoft Corporation. All rights reserved.

admin@PARALLELSM1MAX2 C:\Users\admin.PARALLELSM1MAX>exit
Connection to localhost closed.
PS C:\WINDOWS\system32>

However, from my Mac I simply see this:

Bash:
dominik@*** ~ % ssh 192.168.1.34
ssh: connect to host 192.168.1.34 port 22: Operation timed out

What am I missing?
 
Windows Build/Version
22631.4169

My Computer

System One

  • OS
    macOS Sequoia
    Computer type
    Laptop
    Manufacturer/Model
    Apple
    CPU
    M1 Max Apple Silicon
    Memory
    32 GB
Back
Top Bottom