{"id":1943,"date":"2026-05-29T18:49:38","date_gmt":"2026-05-29T18:49:38","guid":{"rendered":"https:\/\/www.ultrexstaff.com\/?p=1943"},"modified":"2026-05-29T18:49:38","modified_gmt":"2026-05-29T18:49:38","slug":"diagnosing-scanning-issues","status":"publish","type":"post","link":"https:\/\/www.ultrexstaff.com\/?p=1943","title":{"rendered":"Diagnosing Scanning Issues"},"content":{"rendered":"\n<h1 class=\"wp-block-heading\">Diagnosing and Fixing Windows Firewall\/Network Profile Issues Blocking SMB<\/h1>\n\n\n\n<p class=\"wp-block-paragraph\">A device on the network (scanner, printer, external system) can&#8217;t reach a Windows machine&#8217;s shared folder over SMB (port 445). The credentials are correct, the share exists, but the inbound connection silently fails. Most often, the Windows machine&#8217;s network profile is set to <strong>Public<\/strong> instead of <strong>Private<\/strong>, which disables the SMB-In firewall rule by default.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">This guide walks through rapid diagnosis via PowerShell and shows how to repair it efficiently.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">One-Pass Diagnostic (run this first)<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Copy and paste this entire script to get a complete picture:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Write-Host \"=== SMB Connectivity Diagnosis ===\" -ForegroundColor Cyan\nWrite-Host \"`n1. Network Profile\" -ForegroundColor Yellow\nGet-NetConnectionProfile | Select InterfaceAlias, NetworkCategory\n\nWrite-Host \"`n2. SMB Shares on this machine\" -ForegroundColor Yellow\nGet-SmbShare | Select Name, Path, Description\n\nWrite-Host \"`n3. SMB-In Firewall Rule State\" -ForegroundColor Yellow\nGet-NetFirewallRule -DisplayGroup \"File and Printer Sharing\" |\n    Where-Object { $_.DisplayName -eq \"File and Printer Sharing (SMB-In)\" } |\n    Select DisplayName, Enabled, Profile\n\nWrite-Host \"`n4. Wi-Fi Signal and Driver (if applicable)\" -ForegroundColor Yellow\nnetsh wlan show interfaces | Select-String \"Signal|RSSI|Channel|DriverVersion\" -ErrorAction SilentlyContinue\nGet-NetAdapter -Name \"Wi-Fi\" -ErrorAction SilentlyContinue | Select Name, DriverVersion, DriverDate\n\nWrite-Host \"`n5. Known Network Profiles (check for duplicates)\" -ForegroundColor Yellow\nGet-ChildItem \"HKLM:\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\NetworkList\\Profiles\" -ErrorAction SilentlyContinue |\n    ForEach-Object {\n        $p = Get-ItemProperty $_.PSPath\n        &#91;PSCustomObject]@{\n            Name     = $p.ProfileName\n            Category = switch ($p.Category) {0{'Public'}1{'Private'}2{'Domain'}}\n        }\n    } | Sort-Object Name | Format-Table -AutoSize\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">This single command will tell you your network profile, active shares, firewall rule state, Wi-Fi quality, driver version, and any duplicate network profiles. Run it and look at the output \u2014 most issues are visible immediately.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">Quick Reference: Common Repairs<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Profile is Public, needs to be Private:<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Set-NetConnectionProfile -InterfaceAlias \"Wi-Fi\" -NetworkCategory Private\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>SMB-In is disabled for Public, need to enable it (scoped to LocalSubnet):<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Get-NetFirewallRule -DisplayGroup \"File and Printer Sharing\" | Where-Object { $_.DisplayName -eq \"File and Printer Sharing (SMB-In)\" -and $_.Profile -match \"Public\" } | Set-NetFirewallRule -Enabled True -RemoteAddress LocalSubnet\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Test auth from a remote machine (the real test):<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>net use \\\\192.168.1.188\\SCANS \/user:Scanning Scanning12\nnet use\nnet use \\\\192.168.1.188\\SCANS \/delete\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Disable Wi-Fi power management (if the adapter is powering down):<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Disable-NetAdapterPowerManagement -Name \"Wi-Fi\"\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Verify the fix worked:<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Get-NetConnectionProfile | Select InterfaceAlias, NetworkCategory\nGet-NetFirewallRule -DisplayGroup \"File and Printer Sharing\" | Where-Object { $_.DisplayName -eq \"File and Printer Sharing (SMB-In)\" } | Select DisplayName, Enabled, Profile\n<\/code><\/pre>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">Quick Triage (60 seconds)<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Start here to determine if this is a firewall\/profile problem or something else.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">1. Confirm the share exists and the basic path works<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">List all SMB shares on this machine:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Get-SmbShare | Select Name, Path, Description\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>What to look for:<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Is your target share listed? (e.g., <code>SCANS<\/code>, <code>C$<\/code>, <code>FileShare<\/code>)<\/li>\n\n\n\n<li>What local path does it point to? (e.g., <code>C:\\SCANS<\/code>)<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>If not found:<\/strong> The share doesn&#8217;t exist. Create it first before proceeding. This diagnostic won&#8217;t help a missing share.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">2. Test credentials against the share from a remote machine<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">If possible, run this from <strong>another machine on the same network<\/strong> (not from the target itself). Replace 192.168.1.188 with the target IP and &#8220;SCANS&#8221; with your share name:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>net use \\\\192.168.1.188\\SCANS \/user:Scanning Scanning12\nnet use\nnet use \\\\192.168.1.188\\SCANS \/delete\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>What to look for:<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>&#8220;The command completed successfully&#8221;<\/strong> \u2192 Auth works. The problem is firewall\/inbound rules on the target.<\/li>\n\n\n\n<li><strong>Error 1326<\/strong> \u2192 Bad username or password. Fix credentials and re-test.<\/li>\n\n\n\n<li><strong>Error 53 \/ 64<\/strong> \u2192 Network unreachable or path not found. Check IP, routing, and share name spelling.<\/li>\n\n\n\n<li><strong>Error 5<\/strong> \u2192 Auth worked, but permission denied. Check share NTFS permissions.<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Key point:<\/strong> If <code>net use<\/code> succeeds from another machine but the remote device (scanner) still can&#8217;t connect, the issue is inbound firewall rules on your target machine \u2014 proceed to step 3 below.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">Diagnosis: Network Profile and Firewall Rules<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">If you&#8217;ve confirmed credentials and share existence, the culprit is almost always the network profile category (Public vs Private) and the SMB-In inbound firewall rule.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">3. Check the NIC&#8217;s network profile<\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>Get-NetConnectionProfile | Select InterfaceAlias, NetworkCategory\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>What to look for:<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><code>NetworkCategory: Public<\/code> \u2192 <strong>This is the problem.<\/strong> SMB-In is disabled for Public by default.<\/li>\n\n\n\n<li><code>NetworkCategory: Private<\/code> \u2192 Correct for a trusted LAN. Firewall should allow SMB. Proceed to step 4.<\/li>\n\n\n\n<li><code>NetworkCategory: Domain<\/code> \u2192 Domain-joined machine. Profile rules apply per-domain policy.<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>If Public:<\/strong> Note the <code>InterfaceAlias<\/code> (usually <code>Wi-Fi<\/code> or <code>Ethernet<\/code>). You&#8217;ll need it for the fix.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">4. Check the SMB-In firewall rule state<\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>Get-NetFirewallRule -DisplayGroup \"File and Printer Sharing\" |\n    Where-Object { $_.Direction -eq \"Inbound\" } |\n    Select DisplayName, Enabled, Profile, Action\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>What to look for:<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Find the row <code>File and Printer Sharing (SMB-In)<\/code><\/li>\n\n\n\n<li>Check the <code>Enabled<\/code> and <code>Profile<\/code> columns for your NIC&#8217;s profile (Public, Private, or Domain)<\/li>\n\n\n\n<li>If <code>Enabled: False<\/code> for the Public\/Private profile your NIC is on, SMB-In is blocked \u2014 that&#8217;s your answer<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Example of disabled SMB-In on Public:<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>DisplayName                        Enabled  Profile  Action\n-----------                        -------  -------  ------\nFile and Printer Sharing (SMB-In)   False    Public   Allow\nFile and Printer Sharing (SMB-In)    True    Private  Allow\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">If your NIC is on <code>Public<\/code> and SMB-In shows <code>False<\/code> for Public, you&#8217;ve found the root cause.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">5. Verify the target machine can be reached on port 445<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Run this from <strong>the remote machine trying to connect<\/strong> (scanner, printer, another computer):<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Test-NetConnection -ComputerName 192.168.1.188 -Port 445\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>What to look for:<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><code>TcpTestSucceeded: True<\/code> \u2192 Port is reachable. Confirms network connectivity and the SMB port is listening.<\/li>\n\n\n\n<li><code>TcpTestSucceeded: False<\/code> \u2192 Port blocked. Either the firewall rule is denying (step 4), the machine is offline, or network routing is broken.<\/li>\n<\/ul>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">Additional Context: Check for duplicate profiles and reconnect churn<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">If you&#8217;re seeing intermittent issues or the profile keeps changing, check for accumulated duplicate network profiles:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Get-ChildItem \"HKLM:\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\NetworkList\\Profiles\" |\n    ForEach-Object {\n        $p = Get-ItemProperty $_.PSPath\n        &#91;PSCustomObject]@{\n            Name                = $p.ProfileName\n            Category            = switch ($p.Category) {0{'Public'}1{'Private'}2{'Domain'}}\n            DateCreated         = &#91;DateTime]::FromFileTime(&#91;UInt64]$p.DateCreated&#91;0])\n            DateLastConnected   = &#91;DateTime]::FromFileTime(&#91;UInt64]$p.DateLastConnected&#91;0])\n        }\n    } | Format-Table -AutoSize\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>What to look for:<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Multiple entries for the same network name (e.g., &#8220;Office WiFi&#8221;, &#8220;Office WiFi 2&#8221;, &#8220;Office WiFi 3&#8221;)<\/li>\n\n\n\n<li>Duplicate profiles = Windows re-identified the network multiple times, creating a new profile each time (usually due to Wi-Fi reconnects)<\/li>\n\n\n\n<li>The most recent <code>DateLastConnected<\/code> is the one currently in use<\/li>\n\n\n\n<li>If duplicates are classified <code>Public<\/code>, each one is a potential liability<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Why this matters:<\/strong> Frequent Wi-Fi disconnects can cause Windows to create new profiles that default to <code>Public<\/code>. Even if you fix the current one to <code>Private<\/code>, a re-identification creates a new <code>Public<\/code> profile next time.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">Repair: Setting the Profile and Enabling SMB-In<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Once you&#8217;ve identified the issue (usually Public profile + SMB-In disabled), fix it in order of least to most invasive.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Fix 1: Change the profile to Private (recommended)<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Get the exact interface alias first:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Get-NetConnectionProfile | Select InterfaceAlias, NetworkCategory\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Set it to Private (replace &#8220;Wi-Fi&#8221; with your InterfaceAlias if different):<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Set-NetConnectionProfile -InterfaceAlias \"Wi-Fi\" -NetworkCategory Private\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Verify the change:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Get-NetConnectionProfile | Select InterfaceAlias, NetworkCategory\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Expected result:<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>InterfaceAlias  NetworkCategory\n-----------     ---------------\nWi-Fi           Private\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">This immediately activates all the inbound rules that are already enabled for Private, including SMB-In. For a machine on a trusted internal LAN, <code>Private<\/code> is the semantically correct setting.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Test:<\/strong> From the remote machine, try the connection again:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>net use \\\\192.168.1.188\\SCANS \/user:Scanning Scanning12\n<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Fix 2: Enable SMB-In for the Public profile (if the profile must stay Public)<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">If for some reason the profile must remain Public, explicitly enable the SMB-In rule for Public and scope it to your local subnet:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Get-NetFirewallRule -DisplayGroup \"File and Printer Sharing\" |\n    Where-Object { $_.DisplayName -eq \"File and Printer Sharing (SMB-In)\" -and $_.Profile -match \"Public\" } |\n    Set-NetFirewallRule -Enabled True -RemoteAddress LocalSubnet\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Verify:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Get-NetFirewallRule -DisplayGroup \"File and Printer Sharing\" |\n    Where-Object { $_.DisplayName -eq \"File and Printer Sharing (SMB-In)\" } |\n    Select DisplayName, Enabled, Profile, @{N='RemoteAddress';E={($_ | Get-NetFirewallAddressFilter).RemoteAddress}}\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Expected result:<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>DisplayName                       Enabled  Profile  RemoteAddress\n-----------                       -------  -------  ---------\nFile and Printer Sharing (SMB-In)   True    Public   LocalSubnet\nFile and Printer Sharing (SMB-In)   True    Private  LocalSubnet\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">The <code>LocalSubnet<\/code> scope limits SMB to local-segment IPs only, preventing exposure if the device lands on an untrusted network.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">Preventive Diagnosis: Identify root causes of profile instability<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">If this issue recurs, the problem is usually <strong>network profile churn<\/strong> \u2014 Windows re-identifying the network and creating new profiles. Investigate these:<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Check Wi-Fi signal and AP quality<\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>netsh wlan show interfaces\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Look for:<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><code>Signal: 70% or higher<\/code> \u2192 Good. Low signal is a common cause of reconnects.<\/li>\n\n\n\n<li><code>Channel<\/code> \u2192 Check if it&#8217;s congested (2.4 GHz channels 1\/6\/11 are standard; 5 GHz has more space).<\/li>\n\n\n\n<li><code>RSSI: -60 dBm or better<\/code> \u2192 Solid. Anything worse is weak.<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>If signal is poor:<\/strong> The problem is RF. Move the access point or relocate the device closer.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Check for driver issues<\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>Get-NetAdapter -Name \"Wi-Fi\" | Select Name, DriverVersion, DriverDate\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Look for:<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><code>DriverDate<\/code> more than a year old? Update the driver from the NIC vendor (Intel, Qualcomm, Realtek, etc.) directly \u2014 don&#8217;t rely on Windows Update.<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\">Check power management (on laptops especially)<\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>Get-NetAdapterPowerManagement -Name \"Wi-Fi\"\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Look for:<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><code>SelectiveSuspend: Enabled<\/code> or <code>DeviceSleepOnDisconnect: Enabled<\/code> \u2192 These can cause disconnects to save power. Disable them on a desktop or stationary device.<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">If these are enabled, disable them:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Disable-NetAdapterPowerManagement -Name \"Wi-Fi\"\n<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Check for duplicate network profiles (indicates reconnect churn)<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">See the registry query in the &#8220;Additional Context&#8221; section above. Multiple profiles for the same network name is a red flag for instability.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>If duplicates exist:<\/strong> Back up the registry key, then remove stale duplicates (keep only the most recently connected one). Each reconnect event creates a new candidate for being classified <code>Public<\/code>, so cleaning them up reduces surface area.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">Complete diagnostic script (one-liner)<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Here&#8217;s a single script that runs all the key diagnostics and formats them for quick review:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Write-Host \"=== SMB Connectivity Diagnosis ===\" -ForegroundColor Cyan\nWrite-Host \"`n1. Network Profile\" -ForegroundColor Yellow\nGet-NetConnectionProfile | Select InterfaceAlias, NetworkCategory\n\nWrite-Host \"`n2. SMB Shares on this machine\" -ForegroundColor Yellow\nGet-SmbShare | Select Name, Path, Description\n\nWrite-Host \"`n3. SMB-In Firewall Rule State\" -ForegroundColor Yellow\nGet-NetFirewallRule -DisplayGroup \"File and Printer Sharing\" |\n    Where-Object { $_.DisplayName -eq \"File and Printer Sharing (SMB-In)\" } |\n    Select DisplayName, Enabled, Profile\n\nWrite-Host \"`n4. Wi-Fi Signal and Driver (if applicable)\" -ForegroundColor Yellow\nnetsh wlan show interfaces | Select-String \"Signal|RSSI|Channel|DriverVersion\" -ErrorAction SilentlyContinue\nGet-NetAdapter -Name \"Wi-Fi\" -ErrorAction SilentlyContinue | Select Name, DriverVersion, DriverDate\n\nWrite-Host \"`n5. Known Network Profiles (check for duplicates)\" -ForegroundColor Yellow\nGet-ChildItem \"HKLM:\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\NetworkList\\Profiles\" -ErrorAction SilentlyContinue |\n    ForEach-Object {\n        $p = Get-ItemProperty $_.PSPath\n        &#91;PSCustomObject]@{\n            Name     = $p.ProfileName\n            Category = switch ($p.Category) {0{'Public'}1{'Private'}2{'Domain'}}\n        }\n    } | Sort-Object Name | Format-Table -AutoSize\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Run this when a connectivity issue comes in, and it gives you a full picture in one pass.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">Troubleshooting matrix<\/h2>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><thead><tr><th>Symptom<\/th><th>Diagnosis Command<\/th><th>Likely Cause<\/th><th>Fix<\/th><\/tr><\/thead><tbody><tr><td>Remote device can&#8217;t connect, no error code<\/td><td><code>Get-NetConnectionProfile<\/code><\/td><td>Network profile is Public<\/td><td>Set to Private<\/td><\/tr><tr><td>Remote device gets generic &#8220;connection error&#8221;<\/td><td>Check SMB-In rule with <code>Get-NetFirewallRule<\/code><\/td><td>SMB-In disabled on active profile<\/td><td>Enable SMB-In or switch to Private<\/td><\/tr><tr><td>Port 445 shows closed from remote<\/td><td><code>Test-NetConnection -Port 445<\/code><\/td><td>Firewall blocking or service not listening<\/td><td>Enable rule, or <code>Test-NetConnection localhost 445<\/code> to confirm SMB is up<\/td><\/tr><tr><td>Auth succeeds locally but fails remotely<\/td><td><code>net use<\/code> from remote machine<\/td><td>Likely a firewall rule keying off profile, not share\/auth<\/td><td>Confirm profile and SMB-In rule state<\/td><\/tr><tr><td>Problem happens intermittently<\/td><td><code>Get-ChildItem ...\/NetworkList\/Profiles<\/code><\/td><td>Duplicate profiles from Wi-Fi reconnects; newer profile is Public<\/td><td>Clean duplicates; investigate RF stability<\/td><\/tr><tr><td>Problem returns weeks later<\/td><td><code>netsh wlan show interfaces<\/code> + driver check<\/td><td>Unstable Wi-Fi or driver issue causing reconnects<\/td><td>Update driver, optimize Wi-Fi channel\/placement, or move to wired<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">Quick reference: Common PowerShell repairs<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Profile is Public, needs to be Private:<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Set-NetConnectionProfile -InterfaceAlias \"Wi-Fi\" -NetworkCategory Private\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>SMB-In is disabled for Public, need to enable it:<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Get-NetFirewallRule -DisplayGroup \"File and Printer Sharing\" |\n    Where-Object { $_.DisplayName -eq \"File and Printer Sharing (SMB-In)\" -and $_.Profile -match \"Public\" } |\n    Set-NetFirewallRule -Enabled True -RemoteAddress LocalSubnet\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Test auth from remote (safest test):<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>net use \\\\&lt;target-ip&gt;\\&lt;share-name&gt; \/user:&lt;username&gt; &lt;password&gt;\nnet use \\\\&lt;target-ip&gt;\\&lt;share-name&gt; \/delete\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Disable Wi-Fi power management (if adapter is powering down):<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Disable-NetAdapterPowerManagement -Name \"Wi-Fi\"\n<\/code><\/pre>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">When to escalate<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">If after these steps the issue persists, check:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Third-party firewall\/endpoint protection<\/strong> (Sophos, SentinelOne, ZeroTrust) \u2014 these can override Windows Firewall. Check their console for 445 rules.<\/li>\n\n\n\n<li><strong>Network\/VLAN isolation<\/strong> \u2014 confirm both machines are on the same network segment (DHCP scope, VLAN, or subnet).<\/li>\n\n\n\n<li><strong>SMB protocol version mismatch<\/strong> \u2014 older devices may only speak SMBv1, which is disabled on modern Windows for security. Check device firmware.<\/li>\n\n\n\n<li><strong>DNS\/hostname resolution<\/strong> \u2014 if the remote device is resolving a hostname instead of an IP, confirm it&#8217;s reaching the right target.<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>Diagnosing and Fixing Windows Firewall\/Network Profile Issues Blocking SMB A device on the network (scanner, printer, external system) can&#8217;t reach a Windows machine&#8217;s shared folder over SMB (port 445). The credentials are correct, the share exists, but the inbound connection silently fails. Most often, the Windows machine&#8217;s network profile is set to Public instead of [&hellip;]<\/p>\n","protected":false},"author":8,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-1943","post","type-post","status-publish","format-standard","hentry","category-uncategorized","post-preview"],"_links":{"self":[{"href":"https:\/\/www.ultrexstaff.com\/index.php?rest_route=\/wp\/v2\/posts\/1943","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.ultrexstaff.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.ultrexstaff.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.ultrexstaff.com\/index.php?rest_route=\/wp\/v2\/users\/8"}],"replies":[{"embeddable":true,"href":"https:\/\/www.ultrexstaff.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1943"}],"version-history":[{"count":2,"href":"https:\/\/www.ultrexstaff.com\/index.php?rest_route=\/wp\/v2\/posts\/1943\/revisions"}],"predecessor-version":[{"id":1946,"href":"https:\/\/www.ultrexstaff.com\/index.php?rest_route=\/wp\/v2\/posts\/1943\/revisions\/1946"}],"wp:attachment":[{"href":"https:\/\/www.ultrexstaff.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1943"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.ultrexstaff.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1943"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.ultrexstaff.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1943"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}