Cant figure out how to setup an HTTPS server using esp-idf with rust libraries

Yaman Seyravan
Posts: 1
Joined: Wed Jul 19, 2023 10:58 pm

Cant figure out how to setup an HTTPS server using esp-idf with rust libraries

Postby Yaman Seyravan » Wed Jul 19, 2023 11:11 pm

Here is the client setup code I'm using: (it has an esp_crt_bundle_attach config for https connection, no problems there)
[
let mut client = EspHttpClient::new(&EspHttpClientConfiguration {
crt_bundle_attach: Some(esp_idf_sys::esp_crt_bundle_attach),
..Default::default()
})?;
]
But for the server, I can't figure out how to change my HTTP into an HTTPS server,
I couldn't find any config related to the certifications or any examples of how to set up an HTTPS server for RUST users.
Here is the server setup code I'm using:
[
let conf = Configuration {
stack_size: 10240,
..Default::default()
};
let mut server = EspHttpServer::new(&conf)?;
server.set_handler("/api", embedded_svc::http::Method::Post, Api {})?;
]
Can I get any help, hints, or examples on how to do that, or is that even supported for the RUST libraries just like in the C libraries?

Who is online

Users browsing this forum: Baidu [Spider] and 142 guests