MCPcopy Index your code
hub / github.com/RustPython/RustPython / ssl_write_tls_records

Function ssl_write_tls_records

crates/stdlib/src/ssl/compat.rs:1992–1999  ·  view source on GitHub ↗

Write TLS records from rustls to socket

(conn: &mut TlsConnection)

Source from the content-addressed store, hash-verified

1990
1991/// Write TLS records from rustls to socket
1992fn ssl_write_tls_records(conn: &mut TlsConnection) -> SslResult<Vec<u8>> {
1993 let mut buf = Vec::new();
1994 let n = conn
1995 .write_tls(&mut buf as &mut dyn std::io::Write)
1996 .map_err(SslError::Io)?;
1997
1998 if n > 0 { Ok(buf) } else { Ok(Vec::new()) }
1999}
2000
2001/// Read TLS records from socket to rustls
2002fn ssl_read_tls_records(

Callers 4

ssl_do_handshakeFunction · 0.85
ssl_readFunction · 0.85
ssl_writeFunction · 0.85

Calls 2

newFunction · 0.85
write_tlsMethod · 0.80

Tested by

no test coverage detected