MySQL 8.4.2
Source Code Documentation
my_sha1.cc File Reference

Wrapper functions for OpenSSL implementations. More...

#include "my_inttypes.h"
#include "sha1.h"
#include <openssl/evp.h>
#include <openssl/sha.h>

Functions

void compute_sha1_hash (uint8 *digest, const char *buf, size_t len)
 Wrapper function to compute SHA1 message digest. More...
 
void compute_sha1_hash_multi (uint8 *digest, const char *buf1, int len1, const char *buf2, int len2)
 Wrapper function to compute SHA1 message digest for two messages in order to emulate sha1(msg1, msg2). More...
 

Detailed Description

Wrapper functions for OpenSSL implementations.

Function Documentation

◆ compute_sha1_hash()

void compute_sha1_hash ( uint8 digest,
const char *  buf,
size_t  len 
)

Wrapper function to compute SHA1 message digest.

Parameters
[out]digestComputed SHA1 digest
[in]bufMessage to be computed
[in]lenLength of the message

◆ compute_sha1_hash_multi()

void compute_sha1_hash_multi ( uint8 digest,
const char *  buf1,
int  len1,
const char *  buf2,
int  len2 
)

Wrapper function to compute SHA1 message digest for two messages in order to emulate sha1(msg1, msg2).

Parameters
[out]digestComputed SHA1 digest
[in]buf1First message
[in]len1Length of first message
[in]buf2Second message
[in]len2Length of second message