-
Notifications
You must be signed in to change notification settings - Fork 5.9k
[Bug]: Installing extensions - unable to get issuer certificate #6051
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
VS Code unfortunately overrides NODE_TLS_REJECT_UNAUTHORIZED.
Any idea if you get similar issues with curl? Just to rule out
any Node or code-server issues. Maybe something like:
```
curl -L https://open-vsx.org/api/ms-vscode/powershell/2023.2.1/file/ms-vscode.powershell-2023.2.1.vsix -o ms-vscode.powershell-2023.2.1.vsix
```
|
Yes the curl request works fine, i get the file. I can also install the extension in the VSCode (web)UI. |
Oh that is very interesting. The UI just calls the code-server
backend for installing extensions so if it works there it should
work on the command line. Is there anything different about how
you spawn the main code-server process compared to your shell? I
assume you set NODE_EXTRA_CA_CERTS there as well?
|
So spawning the main code-server process is the standard:
I am not setting I am provisioning
My intention is however to install the extensions before spawning the main "daemon". I have all the necessary certs in /etc/ssl/certs for our CA, and we are going through a corporate proxy with ssl interception, hence the need for CA's. |
I just ran with this (masked) proxyserver.local is the proxy server address, so i can see it's connecting through this, however rejectUnauthorized is true?
|
Interesting! I tested Putting it in Still, even with |
I am not sure how best to reproduce, I tried
Still, I suppose this can at least be used to test if
Maybe there is something not quite right with your certificate? Although if it works for |
One more thing, VS Code uses |
@code-asher Are you actually using the proxy there though? i.e. are you sure that code-server is using the http url as you are only setting http_proxy, and not https_proxy too? coder@dev:~$ http_proxy=https://localhost:8000 NODE_EXTRA_CA_CERTS=$HOME/.mitmproxy/mitmproxy-ca.pem code-server --install-extension ms-python.python |
Thanks for the confirmation anyway.. it looks like there is some cert problem this side though, as it works there.. |
Yeah, I see the requests in mitmproxy, plus if it was not using the proxy the run without the cert would not have failed. VS Code falls back to Edit: Just to double-check I confirmed |
Is there an existing issue for this?
OS/Web Information
code-server --version
: 4.10.0Steps to Reproduce
Expected
Should install the extensions using the ca's provided..
Actual
Logs
No response
Screenshot/Video
No response
Does this issue happen in VS Code or GitHub Codespaces?
Are you accessing code-server over HTTPS?
Notes
I have tried to use NODE_EXTRA_CA_CERTS but to no avail.
The text was updated successfully, but these errors were encountered: