I can NOT connect Chome WT API to this implementation
jordicenzano opened this issue · 6 comments
I created a super simple example that shows how Chome (Version 119.0.6045.123 (Official Build) (arm64)) gets a establishment connection error when tries to connect to this WT server
See example and repro steps here: https://github.com/jordicenzano/simple-wt-server
PS: Exact same code and steps with github.com/adriancable/webtransport-go
works perfectly (with small tweaks on go code to adapt to this lib)
Thanks for the repro, I ran it on my machine and it fails as well.
I suspect this is because it's using RSA keys: see https://www.w3.org/TR/webtransport/#web-transport-configuration (last paragraph). Can you try switching to non-RSA keys?
Thanks a lot for testing this, but when I use a ECDSA keys I get the exact same error. This is what I use to create those keys:
openssl req -new -newkey ec -pkeyopt ec_paramgen_curve:prime256v1 -x509 -nodes -days 10 -out ../certs/certificate.pem -keyout ../certs/certificate.key -subj '/CN=Test Certificate' -addext "subjectAltName = DNS:localhost"
Have you also updated https://github.com/jordicenzano/simple-wt-server/blob/main/scripts/start-localhost-test-chrome.sh#L4? Could you push your change?
Yes, I updated that script (IDK if I did properly TBH)
I just pushed the changes
@jordicenzano Can you try running the interop code? It works on CI. If it doesn't work on your machine, this might be because Chrome changed something.
Sorry for my late reply, it is faling too:
interop git:(master) ✗ python3 interop.py
Traceback (most recent call last):
File "/Users/jcenzano/joccode/webtransport-go/interop/interop.py", line 32, in <module>
driver.get("http://localhost:8080/webtransport")
File "/Users/jcenzano/homebrew/lib/python3.11/site-packages/selenium/webdriver/remote/webdriver.py", line 356, in get
self.execute(Command.GET, {"url": url})
File "/Users/jcenzano/homebrew/lib/python3.11/site-packages/selenium/webdriver/remote/webdriver.py", line 347, in execute
self.error_handler.check_response(response)
File "/Users/jcenzano/homebrew/lib/python3.11/site-packages/selenium/webdriver/remote/errorhandler.py", line 229, in check_response
raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.WebDriverException: Message: unknown error: net::ERR_CONNECTION_REFUSED
(Session info: headless chrome=119.0.6045.159)
Stacktrace:
0 chromedriver 0x0000000104a3e004 chromedriver + 4169732
1 chromedriver 0x0000000104a35ff8 chromedriver + 4136952
2 chromedriver 0x000000010468b500 chromedriver + 292096
3 chromedriver 0x0000000104683f20 chromedriver + 261920
4 chromedriver 0x0000000104674790 chromedriver + 198544
5 chromedriver 0x0000000104675bd0 chromedriver + 203728
6 chromedriver 0x0000000104674aec chromedriver + 199404
7 chromedriver 0x00000001046739d0 chromedriver + 195024
8 chromedriver 0x000000010467397c chromedriver + 194940
9 chromedriver 0x0000000104671ef4 chromedriver + 188148
10 chromedriver 0x00000001046729e0 chromedriver + 190944
11 chromedriver 0x000000010468debc chromedriver + 302780
12 chromedriver 0x000000010470bda4 chromedriver + 818596
13 chromedriver 0x000000010470b818 chromedriver + 817176
14 chromedriver 0x00000001046c45e8 chromedriver + 525800
15 chromedriver 0x00000001046c54b8 chromedriver + 529592
16 chromedriver 0x0000000104a04334 chromedriver + 3932980
17 chromedriver 0x0000000104a08970 chromedriver + 3950960
18 chromedriver 0x00000001049ec774 chromedriver + 3835764
19 chromedriver 0x0000000104a09478 chromedriver + 3953784
20 chromedriver 0x00000001049deab4 chromedriver + 3779252
21 chromedriver 0x0000000104a25914 chromedriver + 4069652
22 chromedriver 0x0000000104a25a90 chromedriver + 4070032
23 chromedriver 0x0000000104a35c70 chromedriver + 4136048
24 libsystem_pthread.dylib 0x0000000183265034 _pthread_start + 136
25 libsystem_pthread.dylib 0x000000018325fe3c thread_start + 8