diff options
Diffstat (limited to 'modules/authmodule-eIDAS-v2/src')
-rw-r--r-- | modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/SzrClientTestProduction.java | 23 |
1 files changed, 21 insertions, 2 deletions
diff --git a/modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/SzrClientTestProduction.java b/modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/SzrClientTestProduction.java index 1e7ff369..0ea62855 100644 --- a/modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/SzrClientTestProduction.java +++ b/modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/SzrClientTestProduction.java @@ -105,6 +105,17 @@ public class SzrClientTestProduction { } @Test + public void getVszRandom() throws SzrCommunicationException, EidasSAuthenticationException { + String vsz = szrClient.getEncryptedStammzahl(getPersonInfo( + RandomStringUtils.randomAlphabetic(10), + familyName, dateOfBirth, + "IS/AT/" + RandomStringUtils.randomAlphanumeric(15) + )); + Assert.assertNotNull("vsz", vsz); + + } + + @Test public void getEidasBind() throws SzrCommunicationException, EidasSAuthenticationException { String vsz = RandomStringUtils.randomAlphanumeric(10); String bindingPubKey = Base64.toBase64String(RandomStringUtils.random(20).getBytes()); @@ -203,7 +214,9 @@ public class SzrClientTestProduction { } } - private PersonInfoType getPersonInfo() throws EidasSAuthenticationException { + private PersonInfoType getPersonInfo(String givenname, String familyname, String dateofbirth, + String eidaseid) throws EidasSAuthenticationException { + final PersonInfoType personInfo = new PersonInfoType(); final PersonNameType personName = new PersonNameType(); final PhysicalPersonType naturalPerson = new PhysicalPersonType(); @@ -215,7 +228,7 @@ public class SzrClientTestProduction { // parse some eID attributes final Triple<String, String, String> eIdentifier = - EidasResponseUtils.parseEidasPersonalIdentifier(eIDASeID); + EidasResponseUtils.parseEidasPersonalIdentifier(eidaseid); final String uniqueId = createHashFromUniqueId(eIdentifier.getThird()); final String citizenCountry = eIdentifier.getFirst(); @@ -232,5 +245,11 @@ public class SzrClientTestProduction { Constants.SZR_CONSTANTS_DEFAULT_DOCUMENT_TYPE)); return personInfo; + + } + + private PersonInfoType getPersonInfo() throws EidasSAuthenticationException { + return getPersonInfo(givenName, familyName, dateOfBirth, eIDASeID); + } } |