Fixed null pointer found in git actions`

This commit is contained in:
Cyrus 2022-02-23 10:13:20 -05:00
parent 4cf08ef38a
commit a1ebd2f962

View File

@ -91,7 +91,7 @@ public class CertificateAuthorityCredential extends Certificate {
byte[] tempBytes = getX509Certificate()
.getExtensionValue(SUBJECT_KEY_IDENTIFIER_EXTENSION);
if (tempBytes.length > CA_BYTE_SIZE) {
if (tempBytes != null && tempBytes.length > CA_BYTE_SIZE) {
this.subjectKeyIdentifier = truncatePrefixBytes(tempBytes);
} else {
this.subjectKeyIdentifier =