MCPcopy Create free account
hub / github.com/NVIDIA/OpenShell / call

Method call

crates/openshell-cli/src/tls.rs:291–302  ·  view source on GitHub ↗
(&mut self, uri: hyper::Uri)

Source from the content-addressed store, hash-verified

289 }
290
291 fn call(&mut self, uri: hyper::Uri) -> Self::Future {
292 let tls_connector = self.tls_connector.clone();
293 Box::pin(async move {
294 let host = uri.host().unwrap_or("localhost").to_string();
295 let port = uri.port_u16().unwrap_or(443);
296 let addr = format!("{host}:{port}");
297 let tcp = tokio::net::TcpStream::connect(addr).await?;
298 let server_name = ServerName::try_from(host)?;
299 let tls_stream = tls_connector.connect(server_name, tcp).await?;
300 Ok(hyper_util::rt::TokioIo::new(tls_stream))
301 })
302 }
303}
304
305pub fn build_insecure_rustls_config() -> Result<rustls::ClientConfig> {

Callers

nothing calls this directly

Calls 2

connectFunction · 0.85
connectMethod · 0.45

Tested by

no test coverage detected