removing more locations of WOLFSSL_API used with function implementations

This commit is contained in:
JacobBarthelmeh
2025-07-10 16:44:28 -06:00
parent 13b8a972ea
commit 01cd91cbea
10 changed files with 22 additions and 22 deletions

View File

@ -1404,7 +1404,7 @@ long wolfSSL_BIO_get_mem_ptr(WOLFSSL_BIO *bio, WOLFSSL_BUF_MEM **ptr)
}
#endif
WOLFSSL_API long wolfSSL_BIO_int_ctrl(WOLFSSL_BIO *bp, int cmd, long larg, int iarg)
long wolfSSL_BIO_int_ctrl(WOLFSSL_BIO *bp, int cmd, long larg, int iarg)
{
(void) bp;
(void) cmd;

View File

@ -8722,7 +8722,7 @@ static int isArrayUnique(const char* buf, size_t len)
* Takes byte array containing cert types the caller can provide to its peer.
* Cert types are in preferred order in the array.
*/
WOLFSSL_API int wolfSSL_CTX_set_client_cert_type(WOLFSSL_CTX* ctx,
int wolfSSL_CTX_set_client_cert_type(WOLFSSL_CTX* ctx,
const char* buf, int bufLen)
{
int i;
@ -8757,7 +8757,7 @@ WOLFSSL_API int wolfSSL_CTX_set_client_cert_type(WOLFSSL_CTX* ctx,
* Takes byte array containing cert types the caller can provide to its peer.
* Cert types are in preferred order in the array.
*/
WOLFSSL_API int wolfSSL_CTX_set_server_cert_type(WOLFSSL_CTX* ctx,
int wolfSSL_CTX_set_server_cert_type(WOLFSSL_CTX* ctx,
const char* buf, int bufLen)
{
int i;
@ -8792,7 +8792,7 @@ WOLFSSL_API int wolfSSL_CTX_set_server_cert_type(WOLFSSL_CTX* ctx,
* Takes byte array containing cert types the caller can provide to its peer.
* Cert types are in preferred order in the array.
*/
WOLFSSL_API int wolfSSL_set_client_cert_type(WOLFSSL* ssl,
int wolfSSL_set_client_cert_type(WOLFSSL* ssl,
const char* buf, int bufLen)
{
int i;
@ -8829,7 +8829,7 @@ WOLFSSL_API int wolfSSL_set_client_cert_type(WOLFSSL* ssl,
* Takes byte array containing cert types the caller can provide to its peer.
* Cert types are in preferred order in the array.
*/
WOLFSSL_API int wolfSSL_set_server_cert_type(WOLFSSL* ssl,
int wolfSSL_set_server_cert_type(WOLFSSL* ssl,
const char* buf, int bufLen)
{
int i;
@ -8871,7 +8871,7 @@ WOLFSSL_API int wolfSSL_set_server_cert_type(WOLFSSL* ssl,
* in case no negotiation performed, it returns WOLFSSL_SUCCESS and -1 is for
* cert type.
*/
WOLFSSL_API int wolfSSL_get_negotiated_client_cert_type(WOLFSSL* ssl, int* tp)
int wolfSSL_get_negotiated_client_cert_type(WOLFSSL* ssl, int* tp)
{
int ret = WOLFSSL_SUCCESS;
@ -8902,7 +8902,7 @@ WOLFSSL_API int wolfSSL_get_negotiated_client_cert_type(WOLFSSL* ssl, int* tp)
* in case no negotiation performed, it returns WOLFSSL_SUCCESS and -1 is for
* cert type.
*/
WOLFSSL_API int wolfSSL_get_negotiated_server_cert_type(WOLFSSL* ssl, int* tp)
int wolfSSL_get_negotiated_server_cert_type(WOLFSSL* ssl, int* tp)
{
int ret = WOLFSSL_SUCCESS;

View File

@ -290,7 +290,7 @@ WOLFSSL_SESSION* wolfSSL_get1_session(WOLFSSL* ssl)
}
/* session is a private struct, return if it is setup or not */
WOLFSSL_API int wolfSSL_SessionIsSetup(WOLFSSL_SESSION* session)
int wolfSSL_SessionIsSetup(WOLFSSL_SESSION* session)
{
if (session != NULL)
return session->isSetup;

View File

@ -2121,7 +2121,7 @@ static const char* ocspAppStrList[] = {
NULL
};
WOLFSSL_API int wolfIO_HttpProcessResponseOcspGenericIO(
int wolfIO_HttpProcessResponseOcspGenericIO(
WolfSSLGenericIORecvCb ioCb, void* ioCbCtx, unsigned char** respBuf,
unsigned char* httpBuf, int httpBufSz, void* heap)
{

View File

@ -8327,7 +8327,7 @@ WOLFSSL_X509 *wolfSSL_d2i_X509_fp(XFILE fp, WOLFSSL_X509 **x509)
/* @param file file name to load */
/* @param type WOLFSSL_FILETYPE_PEM or WOLFSSL_FILETYPE_ASN1 */
/* @return a number of loading CRL or certificate, otherwise zero */
WOLFSSL_API int wolfSSL_X509_load_cert_crl_file(WOLFSSL_X509_LOOKUP *ctx,
int wolfSSL_X509_load_cert_crl_file(WOLFSSL_X509_LOOKUP *ctx,
const char *file, int type)
{
WOLFSSL_X509 *x509 = NULL;
@ -8464,7 +8464,7 @@ WOLFSSL_API int wolfSSL_X509_load_cert_crl_file(WOLFSSL_X509_LOOKUP *ctx,
#ifdef HAVE_CRL
#ifndef NO_BIO
WOLFSSL_API WOLFSSL_X509_CRL *wolfSSL_d2i_X509_CRL_bio(WOLFSSL_BIO *bp,
WOLFSSL_X509_CRL *wolfSSL_d2i_X509_CRL_bio(WOLFSSL_BIO *bp,
WOLFSSL_X509_CRL **x)
{
int derSz;
@ -8502,7 +8502,7 @@ WOLFSSL_X509_CRL *wolfSSL_d2i_X509_CRL_fp(XFILE fp, WOLFSSL_X509_CRL **crl)
/* @param file a file to read */
/* @param type WOLFSSL_FILETYPE_PEM or WOLFSSL_FILETYPE_ASN1 */
/* @return WOLFSSL_SUCCESS(1) on successful, otherwise WOLFSSL_FAILURE(0)*/
WOLFSSL_API int wolfSSL_X509_load_crl_file(WOLFSSL_X509_LOOKUP *ctx,
int wolfSSL_X509_load_crl_file(WOLFSSL_X509_LOOKUP *ctx,
const char *file, int type)
{
#ifndef NO_BIO
@ -12339,7 +12339,7 @@ err_exit:
return NULL;
}
WOLFSSL_API WOLFSSL_X509* wolfSSL_PEM_read_X509(XFILE fp, WOLFSSL_X509 **x,
WOLFSSL_X509* wolfSSL_PEM_read_X509(XFILE fp, WOLFSSL_X509 **x,
wc_pem_password_cb *cb, void *u)
{
return (WOLFSSL_X509* )wolfSSL_PEM_read_X509_ex(fp, (void **)x, cb, u,
@ -12347,7 +12347,7 @@ WOLFSSL_API WOLFSSL_X509* wolfSSL_PEM_read_X509(XFILE fp, WOLFSSL_X509 **x,
}
#if defined(HAVE_CRL)
WOLFSSL_API WOLFSSL_X509_CRL* wolfSSL_PEM_read_X509_CRL(XFILE fp,
WOLFSSL_X509_CRL* wolfSSL_PEM_read_X509_CRL(XFILE fp,
WOLFSSL_X509_CRL **crl, wc_pem_password_cb *cb, void *u)
{
return (WOLFSSL_X509_CRL* )wolfSSL_PEM_read_X509_ex(fp, (void **)crl, cb, u,
@ -15604,7 +15604,7 @@ int wolfSSL_X509_ACERT_get_serial_number(WOLFSSL_X509_ACERT* x509,
* Returns WOLFSSL_SUCCESS on success.
* Returns BAD_FUNC_ARG if input pointers are null.
* */
WOLFSSL_API int wolfSSL_X509_ACERT_get_attr_buf(const WOLFSSL_X509_ACERT* x509,
int wolfSSL_X509_ACERT_get_attr_buf(const WOLFSSL_X509_ACERT* x509,
const byte ** rawAttr,
word32 * rawAttrLen)
{
@ -15619,7 +15619,7 @@ WOLFSSL_API int wolfSSL_X509_ACERT_get_attr_buf(const WOLFSSL_X509_ACERT* x509,
}
#ifndef NO_WOLFSSL_STUB
WOLFSSL_API int wolfSSL_X509_ACERT_sign(WOLFSSL_X509_ACERT * x509,
int wolfSSL_X509_ACERT_sign(WOLFSSL_X509_ACERT * x509,
WOLFSSL_EVP_PKEY * pkey,
const WOLFSSL_EVP_MD * md)
{

View File

@ -1584,7 +1584,7 @@ static int X509StoreLoadFile(WOLFSSL_X509_STORE *str,
* a file or directory.
* Returns WOLFSSL_SUCCESS on success or WOLFSSL_FAILURE if an error occurs.
*/
WOLFSSL_API int wolfSSL_X509_STORE_load_locations(WOLFSSL_X509_STORE *str,
int wolfSSL_X509_STORE_load_locations(WOLFSSL_X509_STORE *str,
const char *file, const char *dir)
{
WOLFSSL_CTX* ctx;

View File

@ -24975,7 +24975,7 @@ int wc_CertGetPubKey(const byte* cert, word32 certSz,
* @return BAD_FUNC_ARG if certDer is NULL, certSz is 0, or pubKeyDerSz is NULL
* @return BUFFER_E if the provided buffer is too small
*/
WOLFSSL_API int wc_GetSubjectPubKeyInfoDerFromCert(const byte* certDer,
int wc_GetSubjectPubKeyInfoDerFromCert(const byte* certDer,
word32 certDerSz,
byte* pubKeyDer,
word32* pubKeyDerSz)

View File

@ -172,7 +172,7 @@ static const char* GetCryptoCbCmdTypeStr(int type)
}
#endif
WOLFSSL_API void wc_CryptoCb_InfoString(wc_CryptoInfo* info)
void wc_CryptoCb_InfoString(wc_CryptoInfo* info)
{
if (info == NULL)
return;

View File

@ -1378,7 +1378,7 @@ static int GeneratePublicDh(DhKey* key, byte* priv, word32 privSz,
* Given a DhKey with set params and a priv key, generate the corresponding
* public key. If fips, does pub key validation.
* */
WOLFSSL_API int wc_DhGeneratePublic(DhKey* key, byte* priv, word32 privSz,
int wc_DhGeneratePublic(DhKey* key, byte* priv, word32 privSz,
byte* pub, word32* pubSz)
{
int ret = 0;

View File

@ -176,7 +176,7 @@ void wolfSSL_Debugging_OFF(void)
#endif
}
WOLFSSL_API void wolfSSL_SetLoggingPrefix(const char* prefix)
void wolfSSL_SetLoggingPrefix(const char* prefix)
{
#ifdef DEBUG_WOLFSSL
log_prefix = prefix;
@ -490,7 +490,7 @@ void WOLFSSL_LEAVE2(const char *file, int line, const char* msg, int ret)
#endif
#endif
WOLFSSL_API int WOLFSSL_IS_DEBUG_ON(void)
int WOLFSSL_IS_DEBUG_ON(void)
{
return loggingEnabled;
}