x509_certificate_chain_validate() function
x509_certificate_chain_validate - Validate X.509 certificate chain @trusted: List of trusted certificates @chain: Certificate chain to be validated (first chain must be issued by signed by the second certificate in the chain and so on) @reason: Buffer for returning failure reason (X509_VALIDATE_*) Returns: 0 if chain is valid, -1 if not