Issues accessing localhost:4443
Greetings!
I have an issue regarding to accessing services running at port 4443.
When running just all, accessing http://localhost:4443 returns 404, https://localhost:4443 returns SSL_ERROR_RX_RECORD_TOO_LONG using Firefox (134.0.2) and a similar error using Chrome (132.0.6834.110).
Accessing http://localhost:8080 using Chrome outputs a dark page with title MoQ Demo, but I'm getting error Disconnected TODO get the error message (Firefox keeps loading, but nothing happens).
I'm running the newest main-branch of moq-rs on Ubuntu 22.04.5 LTS on WSL 2.
No errors on terminal, but getting Failed to establish a connection to https://localhost:4443/: net::ERR_CONNECTION_RESET on Chrome.
Running netstat -an shows that there are services running on 8080 and 4443 (and there shouldn't be any other services on those ports because after terminating moq-rs process there are no more services running on those ports).
Any ideas what could be the issue?
http://localhost:8080 is the right URL. That makes a HTTP GET for http://localhost:4443 to get the TLS certificate followed by a WebTransport CONNECT for https://localhost:4443. The WebTransport connect failure is unexpected.
Actually since you're on Windows, it miiight be a network interface issue. Can you try changing this line to --bind [::]:4443 or --bind 127.0.0.1:4443?
#315 might work for you
Hi @kixelated, and thank you for your reply!
Sorry, it has been quite a busy week for me, so apologizes for a late reply.
I noticed you had merged #315 to main, so I pulled the changes, but unfortunately, I'm still getting 404 when accessing http://localhost:4443/demo/bbb (accessing http://localhost:4443 does not work either). Changing --bind "[::]:4443" to --bind "127.0.0.1:4443" didn't help.
Also, after running just all I'm getting following error when accessing to http://localhost:8080:
webtransport error: webtransport session error: WebTransportError { obj: DomException { obj: Object { obj: JsValue(WebTransportError: Opening handshake failed. WebTransportError: Opening handshake failed.) } } }
I'll try setting this project up to a Debian-machine to see if this is just a WSL-related issue.
Tested running just all (and just bbb) on Debian (running the current main-branch) and Node 22.13.1.
http://localhost:4443 still returns 404, but http://localhost:8080 returns the bbb-video (after running just bbb separately).
However, accessing the port 8080 from the LAN returns following error:
webtransport error: unknown error: JsValue(ReferenceError: WebTransport is not defined ReferenceError: WebTransport is not defined at eval (webpack://@kixelated/moq/./dist/rust_bg.js?:1493:17) at handleError (webpack://@kixelated/moq/./dist/rust_bg.js?:228:18) at __wbg_newwithoptions_06e9c2c2d1fe042c (webpack://@kixelated/moq/./dist/rust_bg.js?:1492:59) at moq_web.wasm.__wbg_newwithoptions_06e9c2c2d1fe042c externref shim (http://192.168.1.185:8080/f46bd88d5235726c0348.module.wasm:wasm-function[20621]:0x691e93) at moq_web.wasm.web_sys::features::gen_WebTransport::WebTransport::new_with_options::h1845c572b9866e3f (http://192.168.1.185:8080/f46bd88d5235726c0348.module.wasm:wasm-function[3286]:0x461e1f) at moq_web.wasm.web_transport_wasm::client::Client::connect::{{closure}}::hd4c56ea5a3fdd4ed (http://192.168.1.185:8080/f46bd88d5235726c0348.module.wasm:wasm-function[1430]:0x3546fc) at moq_web.wasm.web_transport::quic::Client::connect::{{closure}}::h5a1bd1c8a18c656b (http://192.168.1.185:8080/f46bd88d5235726c0348.module.wasm:wasm-function[1604]:0x379507) at moq_web.wasm.moq_web::session::Connect::run::{{closure}}::h1f20ade0b40249eb (http://192.168.1.185:8080/f46bd88d5235726c0348.module.wasm:wasm-function[247]:0x108083) at moq_web.wasm.moq_web::session::Connect::create::{{closure}}::h126baa6c99d42418 (http://192.168.1.185:8080/f46bd88d5235726c0348.module.wasm:wasm-function[225]:0xdd502) at moq_web.wasm.wasm_bindgen_futures::task::singlethread::Task::run::hb21456dc451e538d (http://192.168.1.185:8080/f46bd88d5235726c0348.module.wasm:wasm-function[2419]:0x3fc352))
So yeah, it appears to be something related to WSL, I guess?
WebTransport is not defined
That's a browser error: https://caniuse.com/webtransport
You said you were using Firefox? Can you try Chrome?
Greetings kixelated! This happened with Chrome and Firefox (when accessing over LAN), and the reason is quite clear:
Basically, the MoQ Demo tries to fetch fingerprint from
http://localhost:4443, so not from the server address server is using, but from localhost. Therefore, the result is 404 unless there's such endpoint working at localhost.
However, when accessing from the hosted devices by going to http://localhost:8080, the video plays fine on Chrome 132.0.6834.159 with Debian 12. With Firefox 128.6.0esr I'm getting the following error:
handleError@webpack://@kixelated/moq/./node_modules/webpack-dev-server/client/overlay.js?:588:58
createOverlay/<@webpack://@kixelated/moq/./node_modules/webpack-dev-server/client/overlay.js?:607:18
EventListener.handleEvent*listenToRuntimeError@webpack://@kixelated/moq/./node_modules/webpack-dev-server/client/overlay.js?:264:10
createOverlay@webpack://@kixelated/moq/./node_modules/webpack-dev-server/client/overlay.js?:600:25
@webpack://@kixelated/moq/./node_modules/webpack-dev-server/client/index.js?:222:105
./node_modules/webpack-dev-server/client/index.js?protocol=ws%3A&hostname=0.0.0.0&port=8080&pathname=%2Fws&logging=info&overlay=true&reconnect=10&hot=false&live-reload=false@http://localhost:8080/index.js:129:1
__webpack_require__@http://localhost:8080/index.js:1558:41
@http://localhost:8080/index.js:1786:30
@http://localhost:8080/index.js:1789:12
So basically, this seems to work somewhat nicely when using Chrome on the host machine.
Greetings @kixelated!
I did some changes to my local setup (latest version of main). I changed all the localhost-related values in justfile to 192.168.1.185 (the LAN IP-address of the devices I'm using as the "server") and also did that in moq-web/src/demo (to <moq-publish> and <moq-meet>).
However, accessing http://192.168.1.185:8080 does not work either on Chrome (versions 133.0.6943.127/Windows, 133.0.6943.126/Ubuntu 22.04.5 LTS, 133.0.6943.98/Debian 12 (the device where the moq-rs is running with just all)).
Firefox (versions 135.0.1/Windows, 130.0.0/Ubuntu 22.04.5 LTS, 128.7.0esr/Debian 12) does not work either.
If I try accessing http://localhost:8080 on the device used for running moq-rs (the Debian 12 one), I can access the site normally.
All the addresses have been changed from localhost to the LAN-address (192.168.1.185) in moq-rs, but this still does not seem to work.
Any ideas what could be the issue?
The error between systems is similar per browser.
Error when trying to access http://192.168.1.185:8080 using Firefox:
Disconnected webtransport error: unknown error: JsValue(ReferenceError: WebTransport is not defined __wbg_newwithoptions_06e9c2c2d1fe042c/<@webpack://@kixelated/moq/./dist/rust_bg.js?:1523:17 handleError@webpack://@kixelated/moq/./dist/rust_bg.js?:228:18 __wbg_newwithoptions_06e9c2c2d1fe042c@webpack://@kixelated/moq/./dist/rust_bg.js?:1522:59 moq_web.wasm.__wbg_newwithoptions_06e9c2c2d1fe042c externref shim@http://192.168.1.185:8080/aeb344b8c8b0169d2599.module.wasm:wasm-function[20704]:0x689453 moq_web.wasm.web_sys::features::gen_WebTransport::WebTransport::new_with_options::h94ee05c77520749a@http://192.168.1.185:8080/aeb344b8c8b0169d2599.module.wasm:wasm-function[3303]:0x457774 moq_web.wasm.web_transport_wasm::client::Client::connect::{{closure}}::h12f5c5ef6c4e609e@http://192.168.1.185:8080/aeb344b8c8b0169d2599.module.wasm:wasm-function[1426]:0x346f34 moq_web.wasm.web_transport::quic::Client::connect::{{closure}}::h480f03d0c267ba26@http://192.168.1.185:8080/aeb344b8c8b0169d2599.module.wasm:wasm-function[1602]:0x36c515 moq_web.wasm.moq_web::connection::connect::Connect::run::{{closure}}::h342d6734a8b3a678@http://192.168.1.185:8080/aeb344b8c8b0169d2599.module.wasm:wasm-function[245]:0xfdd88 moq_web.wasm.moq_web::connection::connect::Connect::create::{{closure}}::hd51ed1be379f403f@http://192.168.1.185:8080/aeb344b8c8b0169d2599.module.wasm:wasm-function[224]:0xd575e moq_web.wasm.wasm_bindgen_futures::task::singlethread::Task::run::he6f387d46ce1f502@http://192.168.1.185:8080/aeb344b8c8b0169d2599.module.wasm:wasm-function[2426]:0x3f09af moq_web.wasm.wasm_bindgen_futures::queue::QueueState::run_all::hffef341aa829dff9@http://192.168.1.185:8080/aeb344b8c8b0169d2599.module.wasm:wasm-function[1966]:0x3ad6b4 moq_web.wasm.wasm_bindgen_futures::queue::Queue::new::{{closure}}::hccf89b3a44da5a45@http://192.168.1.185:8080/aeb344b8c8b0169d2599.module.wasm:wasm-function[10139]:0x5cb2dd moq_web.wasm.<dyn core::ops::function::FnMut<(A,)>+Output = R as wasm_bindgen::closure::WasmClosure>::describe::invoke::h15422ca83e3fe4d0@http://192.168.1.185:8080/aeb344b8c8b0169d2599.module.wasm:wasm-function[7457]:0x568b1d moq_web.wasm.closure1159 externref shim@http://192.168.1.185:8080/aeb344b8c8b0169d2599.module.wasm:wasm-function[20983]:0x68ad86 __wbg_adapter_36@webpack://@kixelated/moq/./dist/rust_bg.js?:460:10 real@webpack://@kixelated/moq/./dist/rust_bg.js?:355:20 )
And using Chrome:
Disconnected webtransport error: unknown error: JsValue(ReferenceError: WebTransport is not defined ReferenceError: WebTransport is not defined at eval (webpack://@kixelated/moq/./dist/rust_bg.js?:1523:17) at handleError (webpack://@kixelated/moq/./dist/rust_bg.js?:228:18) at __wbg_newwithoptions_06e9c2c2d1fe042c (webpack://@kixelated/moq/./dist/rust_bg.js?:1522:59) at moq_web.wasm.__wbg_newwithoptions_06e9c2c2d1fe042c externref shim (http://192.168.1.185:8080/aeb344b8c8b0169d2599.module.wasm:wasm-function[20704]:0x689453) at moq_web.wasm.web_sys::features::gen_WebTransport::WebTransport::new_with_options::h94ee05c77520749a (http://192.168.1.185:8080/aeb344b8c8b0169d2599.module.wasm:wasm-function[3303]:0x457774) at moq_web.wasm.web_transport_wasm::client::Client::connect::{{closure}}::h12f5c5ef6c4e609e (http://192.168.1.185:8080/aeb344b8c8b0169d2599.module.wasm:wasm-function[1426]:0x346f34) at moq_web.wasm.web_transport::quic::Client::connect::{{closure}}::h480f03d0c267ba26 (http://192.168.1.185:8080/aeb344b8c8b0169d2599.module.wasm:wasm-function[1602]:0x36c515) at moq_web.wasm.moq_web::connection::connect::Connect::run::{{closure}}::h342d6734a8b3a678 (http://192.168.1.185:8080/aeb344b8c8b0169d2599.module.wasm:wasm-function[245]:0xfdd88) at moq_web.wasm.moq_web::connection::connect::Connect::create::{{closure}}::hd51ed1be379f403f (http://192.168.1.185:8080/aeb344b8c8b0169d2599.module.wasm:wasm-function[224]:0xd575e) at moq_web.wasm.wasm_bindgen_futures::task::singlethread::Task::run::he6f387d46ce1f502 (http://192.168.1.185:8080/aeb344b8c8b0169d2599.module.wasm:wasm-function[2426]:0x3f09af))