Error Message
Unknown error.
Error Description
A system internal error occurs during the signing process.
Possible Causes
Solution
Error Message
File not exist.
Error Description
The input file does not exist.
Possible Causes
Solution
Error Message
Write file failed.
Error Description
An error occurs when writing data to the file.
Possible Causes
The user does not have the write permission on the output file specified by outFile.
Solution
Verify that the user has the write permission on the output file specified by outFile.
Error Message
Read file failed.
Error Description
An error occurs when reading data from the file.
Possible Causes
The file specified by profileFile does not exist, or the user does not have the read permission on the file.
Solution
Verify that the file specified by profileFile exists and whether the user has the read permission on the file.
Error Message
Not support file.
Error Description
The file format is not supported.
Possible Causes
An unsupported file name extension is entered during the signing process.
Solution
Enter a file in the correct format. The specific formats are as follows:
Error Message
File IO failed.
Error Description
A file reading or writing error occurs during the signing process.
Possible Causes
Solution
Error Message
Certificate format is incorrect, please check your appCertFile parameter.
Error Description
The certificate chain file is incorrect.
Possible Causes
Solution
Error Message
Key alias not found.
Error Description
The key with the specified alias does not exist in the keystore.
Possible Causes
The key specified by keyAlias does not exist in the keystore.
Solution
Verify that the key specified by keyAlias exists in the keystore.
Error Message
Init keystore failed.
Error Description
Failed to initialize the keystore.
Possible Causes
Solution
Error Message
Key alias xxx password error.
Error Description
The key password is incorrect.
Possible Causes
The key password is incorrect.
Solution
Check the key password specified by keyAlias.
Error Message
No usable cert found in xxx.
Error Description
No available certificate is found.
Possible Causes
The certificate corresponding to the key entry specified by keyAlias in the keystore file has expired.
Solution
Verify that the certificate corresponding to the key entry specified by keyAlias in the keystore file has expired.
Error Message
Signature failed.
Error Description
The signature verification fails, and an invalid signature is returned.
Possible Causes
The signature verification or generation fails.
Solution
Analyze the error based on the error log and command line parameters output by the console.
Error Message
Signature not matched.
Error Description
The certificate does not match the private key.
Possible Causes
The key used for signing the profile file does not match the corresponding certificate.
Solution
Verify that the key specified by keyAlias matches the certificate specified by profileCertFile.
Error Message
Verify signature failed.
Error Description
Signature verification failed during the signing process.
Possible Causes
Solution
Error Message
Read zip file failed.
Error Description
The format of the software package to be signed is incorrect.
Possible Causes
The HAP/HSP/HNP package to be signed does not comply with the ZIP specifications.
The file size exceeds 4 GB.
The number of entries (files and directories) exceeds 65,535.
Solution
Error Message
Write zip file failed.
Error Description
Failed to copy the HAP, HSP, or HNP package to be signed.
Possible Causes
The user does not have the write permission on the output file specified by outFile.
Solution
Verify that the user has the write permission on the output file specified by outFile.
Error Message
Alignment zip file failed
Error Description
The byte alignment of the HAP package is incorrect.
Possible Causes
The byte alignment of the HAP package is incorrect.
Solution
Analyze the error based on the fault log and output by the console and the application package.
Error Message
Zip format failed
Error Description
The format of the software package to be signed is incorrect.
Possible Causes
The HAP, HSP, or HNP package to be signed does not comply with the ZIP specifications (such as the compression mode and file structure).
Solution
Repack the package and sign it again.
Error Message
The size of signed application is out of range
Description
The size of the signed HAP/HSP/HNP package exceeds 4 GB.
Possible Causes
The size of the HAP/HSP/HNP package to be signed is close to 4 GB, and after the signing block is written, the package size exceeds 4 GB.
Solution
Reduce the package size and repack and sign it.
Error Message
Verify input HAP failed
Description
Failed to verify the enterprise application package to be re-signed.
Possible Causes
The enterprise application package to be re-signed is not signed or its integrity is compromised.
Solution
Repackage and sign the package.
Error Message
Unsupported application distribution type: xxx
Description
Unsupported application distribution type.
Possible Causes
The distribution type of the application to be re-signed specified by the inFile parameter is not an enterprise application.
Solution
Replace the application to be re-signed specified by the inFile parameter with an enterprise application whose distribution type is enterprise, enterprise_normal, or enterprise_mdm.
Error Message
Invalid file format.
Error Description
The input file format is incorrect.
Possible Causes
The input file format is not supported for code signing.
Solution
The following file formats are supported for code signing: HAP, HSP, and HQF.
Error Message
Input stream read error.
Error Description
Failed to read the file.
Possible Causes
Failed to read the file.
Solution
Try again or analyze the error based on the fault log and application package.
Error Message
Certificates error.
Error Description
Failed to verify the certificate.
Possible Causes
The certificate is incorrect.
The value of the signing parameter keyAlias is incorrect.
Solution
Verify that the certificate format and content are correct.
Verify that the value of keyAlias is correct.
Error Message
Profile content error.
Error Description
The profile content is incorrect.
Possible Causes
The content in JSON format in profile does not comply with the specifications.
type is missing or the value is invalid.
bundle-info is missing.
The value of app-identifier is of the incorrect type or the length is invalid.
Solution
Verify that the content in JSON format complies with the specifications.
Verify that the value of type is correct.
Add the content of bundle-info.
Ensure that the value of app-identifier is of the string type and contains 1 to 32 characters.
Error Message
module.json content error.
Error Description
The content of the module.json file is incorrect.
Possible Causes
The content format of the module.json file does not comply with the specifications.
The HNP file in the application package is not described in the module.json file.
Solution
Verify that the content in JSON format complies with the specifications.
Add the HNP file description to the module.json file. For details, see module.json5 Configuration File.
Error Message
ELF is incorrect.
Error Description
Failed to parse the ELF file.
Possible Causes
The header information of the ELF file is incorrect.
Solution
Verify that the header information of the ELF file complies with the specifications.
Error Message
Extract hnp file error.
Error Description
Failed to decompress the HNP file.
Possible Causes
Failed to extract or decompress the HNP file.
Solution
Perform signing again.
Verify that the HNP file is correctly packaged.
Error Message
Invalid algorithm.
Error Description
The signature algorithm is incorrect.
Possible Causes
The installed Java version does not support this digest algorithm.
Solution
The SHA-256 and SHA-512 algorithms are supported for code signing. Verify that the Java version is correct. Currently, Java 8 or a later version is supported.