Skip to content

Commit bc00722

Browse files
committed
Use FingerprintUtil in test
1 parent 554fe27 commit bc00722

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

pg/src/test/java/org/bouncycastle/bcpg/test/OnePassSignaturePacketTest.java

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -115,14 +115,7 @@ private void roundtripV6Packet()
115115
{
116116
byte[] salt = new byte[32];
117117
byte[] fingerprint = Hex.decode("CB186C4F0609A697E4D52DFA6C722B0C1F1E27C18A56708F6525EC27BAD9ACC9");
118-
long keyID = ((fingerprint[0] & 0xffL) << 56) |
119-
((fingerprint[1] & 0xffL) << 48) |
120-
((fingerprint[2] & 0xffL) << 40) |
121-
((fingerprint[3] & 0xffL) << 32) |
122-
((fingerprint[4] & 0xffL) << 24) |
123-
((fingerprint[5] & 0xffL) << 16) |
124-
((fingerprint[6] & 0xffL) << 8) |
125-
((fingerprint[7] & 0xffL));
118+
long keyID = FingerprintUtil.keyIdFromV6Fingerprint(fingerprint);
126119

127120
new SecureRandom().nextBytes(salt);
128121
OnePassSignaturePacket before = new OnePassSignaturePacket(

0 commit comments

Comments
 (0)