Skip to content

Commit

Permalink
Support for dev package name
Browse files Browse the repository at this point in the history
  • Loading branch information
quh4gko8 committed Jan 5, 2025
1 parent ccace99 commit d0398c6
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/main/java/app/attestation/server/AttestationProtocol.java
Original file line number Diff line number Diff line change
Expand Up @@ -554,6 +554,11 @@ private static Verified verifyStateless(final Certificate[] certificates,
throw new GeneralSecurityException("invalid Auditor app signing key");
}
appVariant = AUDITOR_APP_VARIANT_DEBUG;
} else if (packageName != null && packageName.startsWith("app.attestation.auditor.dev")) {
if (!"79F16FC09C581E7CA8C407F4F65449C82675D3090E91D0B38ED3BD771C10053F".equals(signatureDigest)) {
throw new GeneralSecurityException("invalid Auditor app signing key");
}
appVariant = AUDITOR_APP_VARIANT_DEBUG;
} else {
throw new GeneralSecurityException("invalid Auditor app package name: " + packageName);
}
Expand Down

0 comments on commit d0398c6

Please sign in to comment.