I'm currently trying to install Rust on a Windows Subsystem for Linux on a machine that is in a network with a man in the middle internet access through ZScaler.
I'm using the curl | sh installation method.
I have installed the custom SSL certificates by downloading them and installing them via sudo dpkg-reconfigure ca-certificates. This allowed me to download the installer script with curl, but running the installer still leads to an SSL error, caused by reqwest:
info: profile set to 'default'
info: default host triple is x86_64-unknown-linux-gnu
verbose: installing toolchain 'stable-x86_64-unknown-linux-gnu'
verbose: toolchain directory: '/home/REDACTED/.rustup/toolchains/stable-x86_64-unknown-linux-gnu'
info: syncing channel updates for 'stable-x86_64-unknown-linux-gnu'
verbose: creating temp file: /home/REDACTED/.rustup/tmp/s5y7qk800z4b0_cp_file
verbose: downloading file from: 'https://static.rust-lang.org/dist/channel-rust-stable.toml.sha256'
verbose: downloading with reqwest
verbose: removing toolchain directory: '/home/REDACTED/.rustup/toolchains/stable-x86_64-unknown-linux-gnu'
error: could not download file from 'https://static.rust-lang.org/dist/channel-rust-stable.toml.sha256' to '/home/REDACTED/.rustup/tmp/s5y7qk800z4b0_cp_file'
Caused by:
0: failed to make network request
1: error sending request for url (https://static.rust-lang.org/dist/channel-rust-stable.toml.sha256): error trying to connect: error:1416F086:SSL routines:tls_process_server_certificate:certificate verify failed:ssl/statem/statem_clnt.c:1921: (unable to get issuer certificate)
2: error trying to connect: error:1416F086:SSL routines:tls_process_server_certificate:certificate verify failed:ssl/statem/statem_clnt.c:1921: (unable to get issuer certificate)
3: error:1416F086:SSL routines:tls_process_server_certificate:certificate verify failed:ssl/statem/statem_clnt.c:1921: (unable to get issuer certificate)
4: error:1416F086:SSL routines:tls_process_server_certificate:certificate verify failed:ssl/statem/statem_clnt.c:1921:
I'm assuming reqwest is not using ca-certificates to get it's SSL certificates, so I does not know the custom certificates I previously installed.
Is there a way to add the certificates to the trusted certificates of reqwest?