1
0
mirror of https://github.com/Ylianst/MeshAgent synced 2025-12-15 07:43:50 +00:00

1. Fixed return value of util_from_cer to be consistent with other util methods

2. Added DER support to tls.loadCertificate
3. Updated sign/verify methods
This commit is contained in:
Bryan Roe
2019-04-03 17:39:22 -07:00
parent 69f76902cd
commit f6ccbce1fb
4 changed files with 186 additions and 15 deletions

View File

@@ -522,7 +522,7 @@ int __fastcall util_from_cer(char* data, int datalen, struct util_cert* cert)
{
cert->pkey = NULL;
cert->x509 = d2i_X509(NULL, (const unsigned char**)&data, datalen);
return ((cert->x509) == NULL);
return ((cert->x509) != NULL);
}
int __fastcall util_from_pkcs7b_string(char *data, int datalen, char *out, int outLen)