提交 f2793c72 编写于 作者: A Annie_wang
上级 416b06cf
...@@ -128,6 +128,8 @@ ...@@ -128,6 +128,8 @@
- Security - Security
- [@ohos.abilityAccessCtrl](js-apis-abilityAccessCtrl.md) - [@ohos.abilityAccessCtrl](js-apis-abilityAccessCtrl.md)
- [@ohos.privacyManager](js-apis-privacyManager.md) - [@ohos.privacyManager](js-apis-privacyManager.md)
- [@ohos.security.cert](js-apis-cert.md)
- [@ohos.security.cryptoFramework]js-apis-cryptoFramework.md)
- [@ohos.security.huks ](js-apis-huks.md) - [@ohos.security.huks ](js-apis-huks.md)
- [@ohos.userIAM.faceAuth](js-apis-useriam-faceauth.md) - [@ohos.userIAM.faceAuth](js-apis-useriam-faceauth.md)
- [@ohos.userIAM.userAuth ](js-apis-useriam-userauth.md) - [@ohos.userIAM.userAuth ](js-apis-useriam-userauth.md)
......
此差异已折叠。
# Certificate Error Codes
## 19020001 Memory Error
**Error Message**
Memory error.
**Possible Causes**
The memory allocation failed.
**Solution**
1. Check whether the system is running properly.
2. Check whether the service data is too long.
## 19020002 Runtime Error
**Error Message**
Runtime error.
**Possible Causes**
An unexpected error occurs.
**Solution**
Check whether the system is running properly.
## 19030001 Crypto Operation Error
**Error Message**
Crypto operation error.
**Possible Causes**
An error occurs when the cryptography framework interacts with a third-party algorithm library.
**Solution**
1. Check whether the input parameters are correct.
2. Check whether the third-party algorithm library functions properly.
## 19030002 Certificate Signature Verification Failed
**Error Message**
The certificate signature verification failed.
**Possible Causes**
Incorrect certificate signature information is found during the signature verification.
**Solution**
Check whether the certificate is correct.
## 19030003 Certificate Has Not Taken Effect
**Error Message**
The certificate has not taken effect.
**Possible Causes**
The certificate has not taken effect. The effective time of the certificate is later than the current system time or the time specified by the service.
**Solution**
1. Check whether the certificate is correct.
2. Check whether the system time is correct.
3. Compare the certificate effective time with the current system time to determine whether the certificate has taken effect.
## 19030004 Certificate Expired
**Error Message**
The certificate has expired.
**Possible Causes**
The certificate has expired. The certificate expiration time is earlier than the current system time or the time specified by the service.
**Solution**
1. Check whether the certificate is correct.
2. Check whether the system time is correct.
3. Compare the certificate expiration time time with the current system time to determine whether the certificate has expired.
## 19030005 Failed to Obtain the Certificate Issuer
**Error Message**
Failed to obtain the certificate issuer.
**Possible Causes**
The certificate issuer cannot be obtained during certificate verification.
**Solution**
Check whether the certificate is correct.
## 19030006 Key Cannot be Used for Signing a Certificate
**Error Message**
The key cannot be used for signing a certificate.
**Possible Causes**
The key cannot be used to sign certificates.
**Solution**
Check whether the certificate is correct.
## 19030007 Key Cannot be Used for Digital Signature
**Error Message**
The key cannot be used for digital signature.
**Possible Causes**
The key cannot be used for digital signature.
**Solution**
Check whether the certificate is correct.
# Crypto Framework Error Codes
## 17620001 Memory Error
**Error Message**
Memory error.
**Possible Causes**
The memory allocation failed.
**Solution**
1. Check whether the system is running properly.
2. Check whether the service data is too long.
## 17620002 Runtime Error
**Error Message**
Runtime error.
**Possible Causes**
An unexpected error occurs.
**Solution**
Check whether the system is running properly.
## 19030001 Crypto Operation Error
**Error Message**
Crypto operation error.
**Possible Causes**
An error occurs when the cryptography framework interacts with a third-party algorithm library.
**Solution**
1. Check whether the input parameters are correct.
2. Check whether the third-party algorithm library functions properly.
...@@ -11,6 +11,12 @@ ...@@ -11,6 +11,12 @@
- Key Management - Key Management
- [HUKS Overview](huks-overview.md) - [HUKS Overview](huks-overview.md)
- [HUKS Development](huks-guidelines.md) - [HUKS Development](huks-guidelines.md)
- Crypto Framework
- [Crypto Framework Overview](cryptoFramework-overview.md)
- [Crypto Framework Development](cryptoFramework-guidelines.md)
- Certificate
- [Certificate Overview](cert-overview.md)
- [Certificate Development](cert-guidelines.md)
- hapsigner - hapsigner
- [hapsigner Overview](hapsigntool-overview.md) - [hapsigner Overview](hapsigntool-overview.md)
- [hapsigner Guide](hapsigntool-guidelines.md) - [hapsigner Guide](hapsigntool-guidelines.md)
此差异已折叠。
# Certificate Overview
The **Certificate** module provides APIs for X.509 certificate operations. You can use the APIs to implement quick development.
## Basic Concepts
A digital certificate provides a method of digitally verifying the identity of a user, device, or service. X.509 is an international standard format public key certificates that securely associate cryptographic key pairs with identifies such as websites, individuals, or organizations. The crypto framework provides the following capabilities:
- X.509 certificate capabilities: parsing and serializing X.509 certificates, verifying X.509 certificate signatures, and querying certificate information.
- X.509 certificate revocation list (CRL) capabilities: parsing, serializing, and querying the X.509 CRL.
- Certificate chain validator capabilities: verifying the certificate chain (excluding the certificate validity period) and querying certificate chain algorithms.
## Constraints
- Multi-thread concurrent operations are not supported.
### Certificate Specifications
- Certificate chain verification
The certificate chain validator does not verify the certificate validity period because the system time on the device is untrusted. To check the validity period of a certificate, use **checkValidityWithDate()** of the **X509Cert** class.
- Certificate formats
Currently, only the certificates in DER and PEM formats are supported.
此差异已折叠。
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册