Run the comment converter on fuzz/ and tool/
Change-Id: I5ff73db09cc2871fca9cc18a74ad52636c6e753d Reviewed-on: https://boringssl-review.googlesource.com/19485 Commit-Queue: Adam Langley <agl@google.com> Reviewed-by: Adam Langley <agl@google.com> CQ-Verified: CQ bot account: commit-bot@chromium.org <commit-bot@chromium.org>
This commit is contained in:
parent
331d2cee0a
commit
e2daba6d20
@ -19,10 +19,10 @@
|
||||
extern "C" int LLVMFuzzerTestOneInput(const uint8_t *buf, size_t len) {
|
||||
X509 *x509 = d2i_X509(NULL, &buf, len);
|
||||
if (x509 != NULL) {
|
||||
/* Extract the public key. */
|
||||
// Extract the public key.
|
||||
EVP_PKEY_free(X509_get_pubkey(x509));
|
||||
|
||||
/* Reserialize the structure. */
|
||||
// Reserialize the structure.
|
||||
uint8_t *der = NULL;
|
||||
i2d_X509(x509, &der);
|
||||
OPENSSL_free(der);
|
||||
|
@ -90,4 +90,4 @@ extern const uint8_t kDERRSAPrivate4096[];
|
||||
extern const size_t kDERRSAPrivate4096Len;
|
||||
|
||||
|
||||
#endif /* !OPENSSL_HEADER_TOOL_INTERNAL_H */
|
||||
#endif // !OPENSSL_HEADER_TOOL_INTERNAL_H
|
||||
|
@ -153,9 +153,9 @@ static bool SpeedRSA(const std::string &key_name, RSA *key,
|
||||
TimeResults results;
|
||||
if (!TimeFunction(&results,
|
||||
[key, &sig, &fake_sha256_hash, &sig_len]() -> bool {
|
||||
/* Usually during RSA signing we're using a long-lived |RSA| that has
|
||||
* already had all of its |BN_MONT_CTX|s constructed, so it makes
|
||||
* sense to use |key| directly here. */
|
||||
// Usually during RSA signing we're using a long-lived |RSA| that has
|
||||
// already had all of its |BN_MONT_CTX|s constructed, so it makes
|
||||
// sense to use |key| directly here.
|
||||
return RSA_sign(NID_sha256, fake_sha256_hash, sizeof(fake_sha256_hash),
|
||||
sig.get(), &sig_len, key);
|
||||
})) {
|
||||
@ -167,11 +167,11 @@ static bool SpeedRSA(const std::string &key_name, RSA *key,
|
||||
|
||||
if (!TimeFunction(&results,
|
||||
[key, &fake_sha256_hash, &sig, sig_len]() -> bool {
|
||||
/* Usually during RSA verification we have to parse an RSA key from a
|
||||
* certificate or similar, in which case we'd need to construct a new
|
||||
* RSA key, with a new |BN_MONT_CTX| for the public modulus. If we were
|
||||
* to use |key| directly instead, then these costs wouldn't be
|
||||
* accounted for. */
|
||||
// Usually during RSA verification we have to parse an RSA key from a
|
||||
// certificate or similar, in which case we'd need to construct a new
|
||||
// RSA key, with a new |BN_MONT_CTX| for the public modulus. If we were
|
||||
// to use |key| directly instead, then these costs wouldn't be
|
||||
// accounted for.
|
||||
bssl::UniquePtr<RSA> verify_key(RSA_new());
|
||||
if (!verify_key) {
|
||||
return false;
|
||||
|
@ -65,4 +65,4 @@ bool DoSMTPStartTLS(int sock);
|
||||
// success and false otherwise.
|
||||
bool DoHTTPTunnel(int sock, const std::string &hostname_and_port);
|
||||
|
||||
#endif /* !OPENSSL_HEADER_TOOL_TRANSPORT_COMMON_H */
|
||||
#endif // !OPENSSL_HEADER_TOOL_TRANSPORT_COMMON_H
|
||||
|
Loading…
Reference in New Issue
Block a user