mbedtls: make style

This commit is contained in:
Philippe Teuwen 2021-05-14 11:00:46 +02:00
commit b1d6eaf2f7
177 changed files with 37224 additions and 41821 deletions

View file

@ -50,8 +50,7 @@ extern "C" {
/**
* \brief XTEA context structure
*/
typedef struct mbedtls_xtea_context
{
typedef struct mbedtls_xtea_context {
uint32_t k[4]; /*!< key */
}
mbedtls_xtea_context;
@ -65,14 +64,14 @@ mbedtls_xtea_context;
*
* \param ctx XTEA context to be initialized
*/
void mbedtls_xtea_init( mbedtls_xtea_context *ctx );
void mbedtls_xtea_init(mbedtls_xtea_context *ctx);
/**
* \brief Clear XTEA context
*
* \param ctx XTEA context to be cleared
*/
void mbedtls_xtea_free( mbedtls_xtea_context *ctx );
void mbedtls_xtea_free(mbedtls_xtea_context *ctx);
/**
* \brief XTEA key schedule
@ -80,7 +79,7 @@ void mbedtls_xtea_free( mbedtls_xtea_context *ctx );
* \param ctx XTEA context to be initialized
* \param key the secret key
*/
void mbedtls_xtea_setup( mbedtls_xtea_context *ctx, const unsigned char key[16] );
void mbedtls_xtea_setup(mbedtls_xtea_context *ctx, const unsigned char key[16]);
/**
* \brief XTEA cipher function
@ -92,10 +91,10 @@ void mbedtls_xtea_setup( mbedtls_xtea_context *ctx, const unsigned char key[16]
*
* \return 0 if successful
*/
int mbedtls_xtea_crypt_ecb( mbedtls_xtea_context *ctx,
int mode,
const unsigned char input[8],
unsigned char output[8] );
int mbedtls_xtea_crypt_ecb(mbedtls_xtea_context *ctx,
int mode,
const unsigned char input[8],
unsigned char output[8]);
#if defined(MBEDTLS_CIPHER_MODE_CBC)
/**
@ -111,12 +110,12 @@ int mbedtls_xtea_crypt_ecb( mbedtls_xtea_context *ctx,
* \return 0 if successful,
* MBEDTLS_ERR_XTEA_INVALID_INPUT_LENGTH if the length % 8 != 0
*/
int mbedtls_xtea_crypt_cbc( mbedtls_xtea_context *ctx,
int mode,
size_t length,
unsigned char iv[8],
const unsigned char *input,
unsigned char *output);
int mbedtls_xtea_crypt_cbc(mbedtls_xtea_context *ctx,
int mode,
size_t length,
unsigned char iv[8],
const unsigned char *input,
unsigned char *output);
#endif /* MBEDTLS_CIPHER_MODE_CBC */
#if defined(MBEDTLS_SELF_TEST)
@ -126,7 +125,7 @@ int mbedtls_xtea_crypt_cbc( mbedtls_xtea_context *ctx,
*
* \return 0 if successful, or 1 if the test failed
*/
int mbedtls_xtea_self_test( int verbose );
int mbedtls_xtea_self_test(int verbose);
#endif /* MBEDTLS_SELF_TEST */