1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 16:17:45 +00:00

LibTLS: Streamline certificate loading

Some refactoring of our root ca loading process:

- Remove duplicate code
- Remove duplicate calls to `parse_root_ca`
- Load user imported certificates in Browser/RequestServer
This commit is contained in:
Fabian Dellwing 2023-04-10 07:06:17 +02:00 committed by Ali Mohammad Pur
parent e4481baef9
commit 93232d4e6d
5 changed files with 28 additions and 33 deletions

View file

@ -260,7 +260,8 @@ public:
Vector<Certificate> const& certificates() const { return m_ca_certificates; }
ErrorOr<Vector<Certificate>> reload_certificates(ByteBuffer&);
static ErrorOr<Vector<Certificate>> parse_pem_root_certificate_authorities(ByteBuffer&);
static ErrorOr<Vector<Certificate>> load_certificates();
static DefaultRootCACertificates& the() { return s_the; }