mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2024-11-22 12:05:36 +01:00
Fix compile error when POLARSSL_ERROR_STRERROR_BC is undefined.
This commit is contained in:
parent
6c33a16dae
commit
95a0d118a9
@ -19,6 +19,8 @@ Bugfix
|
|||||||
Gergely Budai).
|
Gergely Budai).
|
||||||
* Fix #include path in ecdsa.h which wasn't accepted by some compilers.
|
* Fix #include path in ecdsa.h which wasn't accepted by some compilers.
|
||||||
(found by Gergely Budai)
|
(found by Gergely Budai)
|
||||||
|
* Fix compile errors when POLARSSL_ERROR_STRERROR_BC is undefined (found by
|
||||||
|
Shuo Chen).
|
||||||
|
|
||||||
= PolarSSL 1.3.5 released on 2014-03-26
|
= PolarSSL 1.3.5 released on 2014-03-26
|
||||||
Features
|
Features
|
||||||
|
@ -645,7 +645,7 @@
|
|||||||
* Do not add default entropy sources. These are the platform specific,
|
* Do not add default entropy sources. These are the platform specific,
|
||||||
* hardclock and HAVEGE based poll functions.
|
* hardclock and HAVEGE based poll functions.
|
||||||
*
|
*
|
||||||
* This is useful to have more control over the added entropy sources in an
|
* This is useful to have more control over the added entropy sources in an
|
||||||
* application.
|
* application.
|
||||||
*
|
*
|
||||||
* Uncomment this macro to prevent loading of default entropy functions.
|
* Uncomment this macro to prevent loading of default entropy functions.
|
||||||
@ -1366,7 +1366,7 @@
|
|||||||
* Module: library/error.c
|
* Module: library/error.c
|
||||||
* Caller:
|
* Caller:
|
||||||
*
|
*
|
||||||
* This module enables err_strerror().
|
* This module enables polarssl_strerror().
|
||||||
*/
|
*/
|
||||||
#define POLARSSL_ERROR_C
|
#define POLARSSL_ERROR_C
|
||||||
|
|
||||||
|
@ -220,7 +220,7 @@ int main( int argc, char *argv[] )
|
|||||||
if( ret != 0 )
|
if( ret != 0 )
|
||||||
{
|
{
|
||||||
#ifdef POLARSSL_ERROR_C
|
#ifdef POLARSSL_ERROR_C
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
#endif
|
#endif
|
||||||
printf( " failed\n ! load_file returned %d - %s\n\n", ret, buf );
|
printf( " failed\n ! load_file returned %d - %s\n\n", ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
@ -237,7 +237,7 @@ int main( int argc, char *argv[] )
|
|||||||
if( ( ret = convert_pem_to_der( pem_buffer, pem_size, der_buffer, &der_size ) ) != 0 )
|
if( ( ret = convert_pem_to_der( pem_buffer, pem_size, der_buffer, &der_size ) ) != 0 )
|
||||||
{
|
{
|
||||||
#ifdef POLARSSL_ERROR_C
|
#ifdef POLARSSL_ERROR_C
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
#endif
|
#endif
|
||||||
printf( " failed\n ! convert_pem_to_der %d - %s\n\n", ret, buf );
|
printf( " failed\n ! convert_pem_to_der %d - %s\n\n", ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
@ -256,7 +256,7 @@ int main( int argc, char *argv[] )
|
|||||||
if( ret != 0 )
|
if( ret != 0 )
|
||||||
{
|
{
|
||||||
#ifdef POLARSSL_ERROR_C
|
#ifdef POLARSSL_ERROR_C
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
#endif
|
#endif
|
||||||
printf( " failed\n ! write_file returned %d - %s\n\n", ret, buf );
|
printf( " failed\n ! write_file returned %d - %s\n\n", ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
|
@ -367,7 +367,7 @@ int main( int argc, char *argv[] )
|
|||||||
(const unsigned char *) pers,
|
(const unsigned char *) pers,
|
||||||
strlen( pers ) ) ) != 0 )
|
strlen( pers ) ) ) != 0 )
|
||||||
{
|
{
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
printf( " failed\n ! ctr_drbg_init returned %d - %s\n", ret, buf );
|
printf( " failed\n ! ctr_drbg_init returned %d - %s\n", ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
@ -381,7 +381,7 @@ int main( int argc, char *argv[] )
|
|||||||
|
|
||||||
if( ( ret = mpi_read_string( &serial, 10, opt.serial ) ) != 0 )
|
if( ( ret = mpi_read_string( &serial, 10, opt.serial ) ) != 0 )
|
||||||
{
|
{
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
printf( " failed\n ! mpi_read_string returned -0x%02x - %s\n\n", -ret, buf );
|
printf( " failed\n ! mpi_read_string returned -0x%02x - %s\n\n", -ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
@ -400,7 +400,7 @@ int main( int argc, char *argv[] )
|
|||||||
|
|
||||||
if( ( ret = x509_crt_parse_file( &issuer_crt, opt.issuer_crt ) ) != 0 )
|
if( ( ret = x509_crt_parse_file( &issuer_crt, opt.issuer_crt ) ) != 0 )
|
||||||
{
|
{
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
printf( " failed\n ! x509_crt_parse_file returned -0x%02x - %s\n\n", -ret, buf );
|
printf( " failed\n ! x509_crt_parse_file returned -0x%02x - %s\n\n", -ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
@ -409,7 +409,7 @@ int main( int argc, char *argv[] )
|
|||||||
&issuer_crt.issuer );
|
&issuer_crt.issuer );
|
||||||
if( ret < 0 )
|
if( ret < 0 )
|
||||||
{
|
{
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
printf( " failed\n ! x509_dn_gets returned -0x%02x - %s\n\n", -ret, buf );
|
printf( " failed\n ! x509_dn_gets returned -0x%02x - %s\n\n", -ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
@ -432,7 +432,7 @@ int main( int argc, char *argv[] )
|
|||||||
|
|
||||||
if( ( ret = x509_csr_parse_file( &csr, opt.request_file ) ) != 0 )
|
if( ( ret = x509_csr_parse_file( &csr, opt.request_file ) ) != 0 )
|
||||||
{
|
{
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
printf( " failed\n ! x509_csr_parse_file returned -0x%02x - %s\n\n", -ret, buf );
|
printf( " failed\n ! x509_csr_parse_file returned -0x%02x - %s\n\n", -ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
@ -441,7 +441,7 @@ int main( int argc, char *argv[] )
|
|||||||
&csr.subject );
|
&csr.subject );
|
||||||
if( ret < 0 )
|
if( ret < 0 )
|
||||||
{
|
{
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
printf( " failed\n ! x509_dn_gets returned -0x%02x - %s\n\n", -ret, buf );
|
printf( " failed\n ! x509_dn_gets returned -0x%02x - %s\n\n", -ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
@ -465,7 +465,7 @@ int main( int argc, char *argv[] )
|
|||||||
opt.subject_pwd );
|
opt.subject_pwd );
|
||||||
if( ret != 0 )
|
if( ret != 0 )
|
||||||
{
|
{
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
printf( " failed\n ! pk_parse_keyfile returned -0x%02x - %s\n\n", -ret, buf );
|
printf( " failed\n ! pk_parse_keyfile returned -0x%02x - %s\n\n", -ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
@ -480,7 +480,7 @@ int main( int argc, char *argv[] )
|
|||||||
opt.issuer_pwd );
|
opt.issuer_pwd );
|
||||||
if( ret != 0 )
|
if( ret != 0 )
|
||||||
{
|
{
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
printf( " failed\n ! pk_parse_keyfile returned -x%02x - %s\n\n", -ret, buf );
|
printf( " failed\n ! pk_parse_keyfile returned -x%02x - %s\n\n", -ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
@ -517,14 +517,14 @@ int main( int argc, char *argv[] )
|
|||||||
*/
|
*/
|
||||||
if( ( ret = x509write_crt_set_subject_name( &crt, opt.subject_name ) ) != 0 )
|
if( ( ret = x509write_crt_set_subject_name( &crt, opt.subject_name ) ) != 0 )
|
||||||
{
|
{
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
printf( " failed\n ! x509write_crt_set_subject_name returned -0x%02x - %s\n\n", -ret, buf );
|
printf( " failed\n ! x509write_crt_set_subject_name returned -0x%02x - %s\n\n", -ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
if( ( ret = x509write_crt_set_issuer_name( &crt, opt.issuer_name ) ) != 0 )
|
if( ( ret = x509write_crt_set_issuer_name( &crt, opt.issuer_name ) ) != 0 )
|
||||||
{
|
{
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
printf( " failed\n ! x509write_crt_set_issuer_name returned -0x%02x - %s\n\n", -ret, buf );
|
printf( " failed\n ! x509write_crt_set_issuer_name returned -0x%02x - %s\n\n", -ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
@ -535,7 +535,7 @@ int main( int argc, char *argv[] )
|
|||||||
ret = x509write_crt_set_serial( &crt, &serial );
|
ret = x509write_crt_set_serial( &crt, &serial );
|
||||||
if( ret != 0 )
|
if( ret != 0 )
|
||||||
{
|
{
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
printf( " failed\n ! x509write_crt_set_serial returned -0x%02x - %s\n\n", -ret, buf );
|
printf( " failed\n ! x509write_crt_set_serial returned -0x%02x - %s\n\n", -ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
@ -543,7 +543,7 @@ int main( int argc, char *argv[] )
|
|||||||
ret = x509write_crt_set_validity( &crt, opt.not_before, opt.not_after );
|
ret = x509write_crt_set_validity( &crt, opt.not_before, opt.not_after );
|
||||||
if( ret != 0 )
|
if( ret != 0 )
|
||||||
{
|
{
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
printf( " failed\n ! x509write_crt_set_validity returned -0x%02x - %s\n\n", -ret, buf );
|
printf( " failed\n ! x509write_crt_set_validity returned -0x%02x - %s\n\n", -ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
@ -557,7 +557,7 @@ int main( int argc, char *argv[] )
|
|||||||
opt.max_pathlen );
|
opt.max_pathlen );
|
||||||
if( ret != 0 )
|
if( ret != 0 )
|
||||||
{
|
{
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
printf( " failed\n ! x509write_crt_set_basic_contraints returned -0x%02x - %s\n\n", -ret, buf );
|
printf( " failed\n ! x509write_crt_set_basic_contraints returned -0x%02x - %s\n\n", -ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
@ -571,7 +571,7 @@ int main( int argc, char *argv[] )
|
|||||||
ret = x509write_crt_set_subject_key_identifier( &crt );
|
ret = x509write_crt_set_subject_key_identifier( &crt );
|
||||||
if( ret != 0 )
|
if( ret != 0 )
|
||||||
{
|
{
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
printf( " failed\n ! x509write_crt_set_subject_key_identifier returned -0x%02x - %s\n\n", -ret, buf );
|
printf( " failed\n ! x509write_crt_set_subject_key_identifier returned -0x%02x - %s\n\n", -ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
@ -584,7 +584,7 @@ int main( int argc, char *argv[] )
|
|||||||
ret = x509write_crt_set_authority_key_identifier( &crt );
|
ret = x509write_crt_set_authority_key_identifier( &crt );
|
||||||
if( ret != 0 )
|
if( ret != 0 )
|
||||||
{
|
{
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
printf( " failed\n ! x509write_crt_set_authority_key_identifier returned -0x%02x - %s\n\n", -ret, buf );
|
printf( " failed\n ! x509write_crt_set_authority_key_identifier returned -0x%02x - %s\n\n", -ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
@ -600,7 +600,7 @@ int main( int argc, char *argv[] )
|
|||||||
ret = x509write_crt_set_key_usage( &crt, opt.key_usage );
|
ret = x509write_crt_set_key_usage( &crt, opt.key_usage );
|
||||||
if( ret != 0 )
|
if( ret != 0 )
|
||||||
{
|
{
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
printf( " failed\n ! x509write_crt_set_key_usage returned -0x%02x - %s\n\n", -ret, buf );
|
printf( " failed\n ! x509write_crt_set_key_usage returned -0x%02x - %s\n\n", -ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
@ -616,7 +616,7 @@ int main( int argc, char *argv[] )
|
|||||||
ret = x509write_crt_set_ns_cert_type( &crt, opt.ns_cert_type );
|
ret = x509write_crt_set_ns_cert_type( &crt, opt.ns_cert_type );
|
||||||
if( ret != 0 )
|
if( ret != 0 )
|
||||||
{
|
{
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
printf( " failed\n ! x509write_crt_set_ns_cert_type returned -0x%02x - %s\n\n", -ret, buf );
|
printf( " failed\n ! x509write_crt_set_ns_cert_type returned -0x%02x - %s\n\n", -ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
@ -633,7 +633,7 @@ int main( int argc, char *argv[] )
|
|||||||
if( ( ret = write_certificate( &crt, opt.output_file,
|
if( ( ret = write_certificate( &crt, opt.output_file,
|
||||||
ctr_drbg_random, &ctr_drbg ) ) != 0 )
|
ctr_drbg_random, &ctr_drbg ) ) != 0 )
|
||||||
{
|
{
|
||||||
error_strerror( ret, buf, 1024 );
|
polarssl_strerror( ret, buf, 1024 );
|
||||||
printf( " failed\n ! write_certifcate -0x%02x - %s\n\n", -ret, buf );
|
printf( " failed\n ! write_certifcate -0x%02x - %s\n\n", -ret, buf );
|
||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user