Skip to content

Commit 1c0772a

Browse files
authored
Update GreenCertificateDecoder.java
prefix "HC1:" has 4 chars
1 parent de8cd39 commit 1c0772a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/ehn/techiop/hcert/GreenCertificateDecoder.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ public String decode(String base45String) throws CompressorException, IOExceptio
4646
if (!base45String.startsWith(prefix))
4747
throw new RuntimeException("Base45 string not valid according to specification");
4848

49-
base45String = base45String.substring(3);
49+
base45String = base45String.substring(4);
5050
byte[] decodedBytes = Base45.getDecoder().decode(base45String);
5151

5252
byte[] coseBytes = decompress(decodedBytes);

0 commit comments

Comments
 (0)