aboutsummaryrefslogtreecommitdiff
path: root/src/test/model/csr/CertificationRequestTest.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/model/csr/CertificationRequestTest.java')
-rw-r--r--src/test/model/csr/CertificationRequestTest.java46
1 files changed, 23 insertions, 23 deletions
diff --git a/src/test/model/csr/CertificationRequestTest.java b/src/test/model/csr/CertificationRequestTest.java
index 962e90b..689f39d 100644
--- a/src/test/model/csr/CertificationRequestTest.java
+++ b/src/test/model/csr/CertificationRequestTest.java
@@ -18,25 +18,25 @@ import static org.junit.jupiter.api.Assertions.*;
public class CertificationRequestTest {
private static final Byte[] CSR_1 = Stream.of(
// SEQUENCE (CertificationRequest)
- Arrays.asList(new Byte[]{ 0x30, -126, 0x02, -102 }),
+ Arrays.asList(new Byte[]{0x30, -126, 0x02, -102}),
// SEQUENCE (CertificationRequestInfo)
Arrays.asList(CertificationRequestInfoTest.CSR_1),
// SEQUENCE (AlgorithmIdentifier)
Arrays.asList(new Byte[]{
0x30, 0x0D, 0x06, 0x09, 0x2A, -122, 0x48, -122,
- -9, 0x0D, 0x01, 0x01, 0x0B, 0x05, 0x00
+ -9, 0x0D, 0x01, 0x01, 0x0B, 0x05, 0x00
}),
// BIT STRING (Signature)
Arrays.asList(new Byte[]{
0x03, -127, -127,
- 0x00, 0x6F, 0x61, 0x5C, -25, 0x29, 0x48, 0x3F,
- -78, 0x1B, -117, 0x2C, -93, -114, 0x7D, -77,
- 0x62, 0x14, 0x21, 0x4B, -99, 0x74, -95, -93,
- 0x16, 0x38, 0x31, 0x40, 0x5E, 0x72, -77, -55,
- 0x6D, -69, 0x19, -108, 0x52, -95, 0x19, -121,
- -81, -71, 0x74, -123, 0x6B, -27, -20, 0x4C,
- -126, 0x42, -89, 0x66, 0x6A, 0x52, -34, 0x62,
- 0x72, 0x40, 0x2C, -79, 0x78, -117, -100, -70,
+ 0x00, 0x6F, 0x61, 0x5C, -25, 0x29, 0x48, 0x3F,
+ -78, 0x1B, -117, 0x2C, -93, -114, 0x7D, -77,
+ 0x62, 0x14, 0x21, 0x4B, -99, 0x74, -95, -93,
+ 0x16, 0x38, 0x31, 0x40, 0x5E, 0x72, -77, -55,
+ 0x6D, -69, 0x19, -108, 0x52, -95, 0x19, -121,
+ -81, -71, 0x74, -123, 0x6B, -27, -20, 0x4C,
+ -126, 0x42, -89, 0x66, 0x6A, 0x52, -34, 0x62,
+ 0x72, 0x40, 0x2C, -79, 0x78, -117, -100, -70,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
@@ -53,23 +53,23 @@ public class CertificationRequestTest {
final CertificationRequest request = new CertificationRequest(
ASN1Object.TAG_SEQUENCE, null,
new CertificationRequestInfo(
- ASN1Object.TAG_SEQUENCE, null,
- new Int(Int.TAG, null, CertificationRequestInfo.VERSION_V1),
- TestConstants.NAME_2,
- new SubjectPublicKeyInfo(ASN1Object.TAG_SEQUENCE, null,
- new AlgorithmIdentifier(ASN1Object.TAG_SEQUENCE, null,
- new ObjectIdentifier(ObjectIdentifier.TAG, null,
- ObjectIdentifier.OID_SHA256_WITH_RSA_ENCRYPTION),
- new Null(Null.TAG, null)),
- new BitString(BitString.TAG, null,
- 0, new Byte[]{ 1, 2, 3, 4, 5 })),
- TestConstants.CSR_ATTRS_2),
+ ASN1Object.TAG_SEQUENCE, null,
+ new Int(Int.TAG, null, CertificationRequestInfo.VERSION_V1),
+ TestConstants.NAME_2,
+ new SubjectPublicKeyInfo(ASN1Object.TAG_SEQUENCE, null,
+ new AlgorithmIdentifier(ASN1Object.TAG_SEQUENCE, null,
+ new ObjectIdentifier(ObjectIdentifier.TAG, null,
+ ObjectIdentifier.OID_SHA256_WITH_RSA_ENCRYPTION),
+ new Null(Null.TAG, null)),
+ new BitString(BitString.TAG, null,
+ 0, new Byte[]{1, 2, 3, 4, 5})),
+ TestConstants.CSR_ATTRS_2),
new AlgorithmIdentifier(ASN1Object.TAG_SEQUENCE, null,
new ObjectIdentifier(ObjectIdentifier.TAG, null,
ObjectIdentifier.OID_SHA256_WITH_RSA_ENCRYPTION),
new Null(Null.TAG, null)),
new BitString(BitString.TAG, null,
- 0, new Byte[]{ 2, 4, 6, 8, 10 }));
+ 0, new Byte[]{2, 4, 6, 8, 10}));
assertEquals(CertificationRequestInfo.VERSION_V1,
request.getCertificationRequestInfo().getVersion().getLong());
@@ -77,7 +77,7 @@ public class CertificationRequestTest {
request.getCertificationRequestInfo().getSubject().getRdnSequence().length);
assertArrayEquals(ObjectIdentifier.OID_SHA256_WITH_RSA_ENCRYPTION,
request.getSignatureAlgorithm().getType().getInts());
- assertArrayEquals(new Byte[]{ 2, 4, 6, 8, 10 },
+ assertArrayEquals(new Byte[]{2, 4, 6, 8, 10},
request.getSignature().getConvertedVal());
}