Closed Bug 1926661 Opened 9 months ago Closed 9 months ago

Can't reach LAN IPs behind routers in WiFi bridge mode on OSX

Categories

(Core :: Networking, defect, P2)

defect

Tracking

()

RESOLVED INVALID

People

(Reporter: dshin, Unassigned)

References

Details

(Whiteboard: [necko-triaged][necko-priority-new])

Attachments

(1 file)

OSX: Sequoia 15.0.1
Firefox: 133.0a1 (2024-10-22)
Safari: Technology Preview 205 (Safari 18.0, WebKit 20621.1.2.111.4)

STR:
Given

  • Main Router
    • WiFi AP
      • MacBook Pro
      • Router in WiFi Bridge mode
        • Target Device

Run python3 -m http.server on target device. Try to reach it from MacBook Pro using Firefox and Safari by specifying IPv4 LAN address at port 8000

Expected: Can reach the Python server through both browsers
Actual: Can reach server on Safari, but not Firefox, with "Unable to connect" message, with NS_ERROR_CONNECTION_REFUSED.

Thanks for reporting this Bug.
We would need http logs to debug this issue further.
Kindly share the http logs to progress on this bug.
Let us know if you need additional help in log collection.

Flags: needinfo?(dshin)

Logged to profiler, available at https://share.firefox.dev/3AloOO4.

Flags: needinfo?(dshin)

Thank you for sharing the logs. Unfortunately the profiler logs does not have all the information we are looking for.
Could you please log it to a file (instead of a profiler) and share with us.
Kindly ensure the following logging presets are used
timestamp,sync,nsHttp:5,cache2:5,nsSocketTransport:5,nsHostResolver:5

Additionally, could you please confirm if safari and firefox are using similar proxy settings?

Flags: needinfo?(dshin)
Attached file Networking log

No proxy setting has been modified in either Safari or Firefox Nightly.
The logging preset was set to Networking, which had timestamp,sync,nsHttp:5,cache2:5,nsSocketTransport:5,nsHostResolver:5,EarlyHint:5

Flags: needinfo?(dshin)
  "start": 36642750.822507,
  "end": null,
  "name": "LogMessages",
  "category": 1,
  "threadId": null,
  "data": {
    "type": "Log",
    "module": "nsSocketTransport",
    "name": "ErrorAccordingToNSPR [in=-5927 out=804b000d]\n"
  }
}

Apparently connecting to the IP returns
https://searchfox.org/mozilla-central/rev/964b8aa226c68bbf83c9ffc38984804734bb0de2/nsprpub/pr/src/md/unix/unix_errors.c#81-83

case EHOSTUNREACH:
case EHOSTDOWN:
  prError = PR_HOST_UNREACHABLE_ERROR;

Is http://192.168.50.105:8000/ the correct IP?
Does ping work?
How about wget http://192.168.50.105:8000/ or curl http://192.168.50.105:8000/

Flags: needinfo?(dshin)

Yep, double checked on host side that the IP is correct. Additionally, all of ping, get and curl work.

Flags: needinfo?(dshin)

Thanks. Additional question: did it work on previous Firefox, MacOS versions? I'm assuming it working on different operating systems?

Flags: needinfo?(dshin)

I've tried only recently, so unfortunately not sure on OSX version differences.
Tried going back to 2020-01-01 build on mozregression, and that still had issues connecting.

Flags: needinfo?(dshin)
Severity: -- → S3
Priority: -- → P2
Whiteboard: [necko-triaged][necko-priority-new]

:glob apparently hit a similar issue on Mac OS

There's macOS per-application permission for allowing access to the "Local Network".
macOS phrases it as "Allow 'Firefox' to find devices on local networks/"

https://support.apple.com/guide/mac-help/control-access-to-your-local-network-on-mac-mchla4f49138/mac

Could you check if Firefox has that permission, and if changing the option fixes you problem?

Flags: needinfo?(dshin)

Ah, I didn't have that permission. Strange - I never got that prompt.
It's also a bit strange that I can hit the main router just fine?

Closing as INVALID as it's a configuration issue.

Status: NEW → RESOLVED
Closed: 9 months ago
Flags: needinfo?(dshin)
Resolution: --- → INVALID

Is it possible for us to proactively detect that the user has not given Firefox permissions to access the local network, and alert them to do so (if they desire to connect to local web servers)? Without something like that, I expect a continuous stream of such tickets.

(In reply to Lars Eggert [:lars] from comment #11)

Is it possible for us to proactively detect that the user has not given Firefox permissions to access the local network, and alert them to do so (if they desire to connect to local web servers)? Without something like that, I expect a continuous stream of such tickets.

As far as I can tell, the error is the same as a port not being opened on the destination host.
A quick search doesn't find any programatic way of determining if Firefox has that permission or not.
My suggestion would be to add a line to the the error screen telling people to make sure Firefox is granted that permission on OSX.

See Also: → 1936452
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: