GCP-CLOUD-ARCHITECT practice question 10 of 10

You deploy your custom java application to google app engine. It fails to deploy and gives you the following stack trace:

Full set: 333 questions

Domain Ensuring solution and operations reliability

Answer options
A: Recompile the CLoakedServlet class using and MD5 hash instead of SHA1
B: Digitally sign all of your JAR files and redeploy your application. Correct answer
C: Upload missing JAR files and redeploy your application
Correct Answer:
B. Digitally sign all of your JAR files and redeploy your application.
Explanation

The stack trace with java.lang.SecurityException: SHA1 digest error indicates that one or more JAR files are signed but the embedded signature/digest is invalid (often corrupted during packaging). Re-signing the JARs (or removing the invalid signatures) and redeploying resolves the SHA-1 digest mismatch so App Engine can verify the archive at class-load time.

Why Incorrect

A. Recompiling a single class with MD5 does not correct manifest-signature mismatches across the whole JAR.
C. The problem is signature verification, not missing libraries; uploading additional JARs will not fix an invalid digest.

References

1. Oracle

“JAR File Specification – Signing and Verification”

Section 4.2

explains SHA-1 digest verification errors.

2. Google Cloud

“App Engine Standard for Java – Troubleshooting deployment errors”

paragraph “java.lang.SecurityException: SHA1 digest error”

recommends re-signing or removing signatures.

Scroll to Top