Basic parsing of certs signed with RSASSA-PSS

This commit is contained in:
Manuel Pégourié-Gonnard 2014-01-22 10:12:57 +01:00
parent 1ebc0c592c
commit 59a75d5b9d
11 changed files with 90 additions and 3 deletions

View file

@ -123,6 +123,20 @@ int x509_get_alg_null( unsigned char **p, const unsigned char *end,
return( 0 );
}
/*
* Parse an algorithm identifier with (optional) paramaters
*/
int x509_get_alg( unsigned char **p, const unsigned char *end,
x509_buf *alg, x509_buf *params )
{
int ret;
if( ( ret = asn1_get_alg( p, end, alg, params ) ) != 0 )
return( POLARSSL_ERR_X509_INVALID_ALG + ret );
return( 0 );
}
/*
* AttributeTypeAndValue ::= SEQUENCE {
* type AttributeType,