diff --git a/mock-certify-plugin/src/main/java/io/mosip/certify/mock/integration/mocks/MdocGenerator.kt b/mock-certify-plugin/src/main/java/io/mosip/certify/mock/integration/mocks/MdocGenerator.kt index 3adb687..6a34e45 100644 --- a/mock-certify-plugin/src/main/java/io/mosip/certify/mock/integration/mocks/MdocGenerator.kt +++ b/mock-certify-plugin/src/main/java/io/mosip/certify/mock/integration/mocks/MdocGenerator.kt @@ -63,7 +63,7 @@ class MdocGenerator { val calculateDigestsForNameSpace = MdocUtil.calculateDigestsForNameSpace(NAMESPACE, generatedIssuerNameSpaces, DIGEST_ALGORITHM) - val mobileSecurityObjectGenerator = MobileSecurityObjectGenerator(DIGEST_ALGORITHM, NAMESPACE, devicePublicKey) + val mobileSecurityObjectGenerator = MobileSecurityObjectGenerator(DIGEST_ALGORITHM, DOCTYPE, devicePublicKey) mobileSecurityObjectGenerator.addDigestIdsForNamespace(NAMESPACE, calculateDigestsForNameSpace) //Validity of MSO & its signature is assigned here mobileSecurityObjectGenerator.setValidityInfo( diff --git a/mock-certify-plugin/src/test/java/io/mosip/certify/util/PKCS12ReaderTest.java b/mock-certify-plugin/src/test/java/io/mosip/certify/util/PKCS12ReaderTest.java deleted file mode 100644 index b44eccf..0000000 --- a/mock-certify-plugin/src/test/java/io/mosip/certify/util/PKCS12ReaderTest.java +++ /dev/null @@ -1,31 +0,0 @@ -package io.mosip.certify.util; - -import org.junit.jupiter.api.Test; - -import static org.junit.jupiter.api.Assertions.*; - -class PKCS12ReaderTest { - - @Test - void testExtract() { - KeyPairAndCertificate extract = new PKCS12Reader().extract("MIGHAgEAMBMGByqGSM49AgEGCCqGSM49AwEHBG0wawIBAQQgc/l+Y4UL5u42T8ugxSlUWjh1V+ZBJP1EAImDa1VJYvyhRANCAAQceevdAPMdDZ6mz7khfXP/db+ItLwqKSsUQWw8nSwUTQ6LSMtvnUxy/r7bCdjhj+AMnqYX8cOEickarfOSKuVq||LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk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