mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-04-10 15:45:34 +00:00
Merge pull request #8590 from valeriosetti/fix-pkcs5-pkcs12
pkcs[5/12]: use cipher enums for encrypt and decrypt
This commit is contained in:
commit
3d12d65946
@ -31,8 +31,8 @@
|
||||
#define MBEDTLS_PKCS12_DERIVE_IV 2 /**< initialization vector */
|
||||
#define MBEDTLS_PKCS12_DERIVE_MAC_KEY 3 /**< integrity / MAC key */
|
||||
|
||||
#define MBEDTLS_PKCS12_PBE_DECRYPT 0
|
||||
#define MBEDTLS_PKCS12_PBE_ENCRYPT 1
|
||||
#define MBEDTLS_PKCS12_PBE_DECRYPT MBEDTLS_DECRYPT
|
||||
#define MBEDTLS_PKCS12_PBE_ENCRYPT MBEDTLS_ENCRYPT
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
|
@ -17,6 +17,7 @@
|
||||
|
||||
#include "mbedtls/asn1.h"
|
||||
#include "mbedtls/md.h"
|
||||
#include "mbedtls/cipher.h"
|
||||
|
||||
#include <stddef.h>
|
||||
#include <stdint.h>
|
||||
@ -30,8 +31,8 @@
|
||||
/** Given private key password does not allow for correct decryption. */
|
||||
#define MBEDTLS_ERR_PKCS5_PASSWORD_MISMATCH -0x2e00
|
||||
|
||||
#define MBEDTLS_PKCS5_DECRYPT 0
|
||||
#define MBEDTLS_PKCS5_ENCRYPT 1
|
||||
#define MBEDTLS_PKCS5_DECRYPT MBEDTLS_DECRYPT
|
||||
#define MBEDTLS_PKCS5_ENCRYPT MBEDTLS_ENCRYPT
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
|
Loading…
x
Reference in New Issue
Block a user