mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 20:07:35 +00:00
LibTLS: Remove all uses of VLAs
This commit is contained in:
parent
abda20e25e
commit
98ecb95709
3 changed files with 16 additions and 16 deletions
|
@ -275,8 +275,9 @@ void TLSv12::build_random(PacketBuilder& builder)
|
|||
|
||||
Crypto::PK::RSA_PKCS1_EME rsa(certificate.public_key.modulus(), 0, certificate.public_key.public_exponent());
|
||||
|
||||
u8 out[rsa.output_size()];
|
||||
auto outbuf = Bytes { out, rsa.output_size() };
|
||||
Vector<u8, 32> out;
|
||||
out.resize(rsa.output_size());
|
||||
auto outbuf = out.span();
|
||||
rsa.encrypt(m_context.premaster_key, outbuf);
|
||||
|
||||
if constexpr (TLS_DEBUG) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue