From 7cd38fb12ca3329dee99d0032f7e3d4b1d7cc2ce Mon Sep 17 00:00:00 2001
From: Thomas <>
Date: Mon, 4 Jul 2022 14:21:59 +0200
Subject: feat(sl20): add 'eidasAuthLevel' flag into IDA authentication request
to VDA
---
.../egiz/eaaf/modules/auth/sl20/utils/SL20Constants.java | 2 ++
.../eaaf/modules/auth/sl20/utils/SL20JsonBuilderUtils.java | 14 ++++++++------
2 files changed, 10 insertions(+), 6 deletions(-)
(limited to 'eaaf_modules/eaaf_module_auth_sl20/src/main/java/at')
diff --git a/eaaf_modules/eaaf_module_auth_sl20/src/main/java/at/gv/egiz/eaaf/modules/auth/sl20/utils/SL20Constants.java b/eaaf_modules/eaaf_module_auth_sl20/src/main/java/at/gv/egiz/eaaf/modules/auth/sl20/utils/SL20Constants.java
index c95bcc45..ca64c55d 100644
--- a/eaaf_modules/eaaf_module_auth_sl20/src/main/java/at/gv/egiz/eaaf/modules/auth/sl20/utils/SL20Constants.java
+++ b/eaaf_modules/eaaf_module_auth_sl20/src/main/java/at/gv/egiz/eaaf/modules/auth/sl20/utils/SL20Constants.java
@@ -213,6 +213,8 @@ public class SL20Constants {
public static final String SL20_COMMAND_PARAM_EID_CONSENTTEMPLATEID = "consentTemplateID";
public static final String SL20_COMMAND_PARAM_EID_CONSENT = "consent";
+ public static final String SL20_COMMAND_PARAM_EID_EIDAS_AUTH = "eidasAuthLevel";
+
@Deprecated
public static final String SL20_COMMAND_PARAM_EID_CONSENT_RESULT_MDS = "MDS";
@Deprecated
diff --git a/eaaf_modules/eaaf_module_auth_sl20/src/main/java/at/gv/egiz/eaaf/modules/auth/sl20/utils/SL20JsonBuilderUtils.java b/eaaf_modules/eaaf_module_auth_sl20/src/main/java/at/gv/egiz/eaaf/modules/auth/sl20/utils/SL20JsonBuilderUtils.java
index d76f4aad..aa749d73 100644
--- a/eaaf_modules/eaaf_module_auth_sl20/src/main/java/at/gv/egiz/eaaf/modules/auth/sl20/utils/SL20JsonBuilderUtils.java
+++ b/eaaf_modules/eaaf_module_auth_sl20/src/main/java/at/gv/egiz/eaaf/modules/auth/sl20/utils/SL20JsonBuilderUtils.java
@@ -198,22 +198,24 @@ public class SL20JsonBuilderUtils {
/**
* Create parameters for qualifiedeID command.
*
- * @param consentTemplateId Identifier of the template that is used for consent
- * visualization
- * @param consent Consent that has to be signed by user
- * @param dataUrl DataURL for result
- * @param x5cEnc Response encryption certificate
+ * @param consentTemplateId Identifier of the template that is used for consent
+ * visualization
+ * @param consent Consent that has to be signed by user
+ * @param eidasAuthentication true
in case of an eIDAS out-going process, otherwise false
+ * @param dataUrl DataURL for result
+ * @param x5cEnc Response encryption certificate
* @return JSON
* @throws CertificateEncodingException In case of a encryption certificate
* encoding problem
* @throws SlCommandoBuildException In case of a generel error
*/
public static ObjectNode createQualifiedeEidConsent(final String consentTemplateId, final byte[] consent,
- final String dataUrl, final X509Certificate x5cEnc)
+ final boolean eidasAuthentication, final String dataUrl, final X509Certificate x5cEnc)
throws CertificateEncodingException, SlCommandoBuildException {
final ObjectNode params = mapper.getMapper().createObjectNode();
addSingleStringElement(params, SL20Constants.SL20_COMMAND_PARAM_EID_CONSENTTEMPLATEID, consentTemplateId, true);
addSingleByteElement(params, SL20Constants.SL20_COMMAND_PARAM_EID_CONSENT, consent, true);
+ addSingleBooleanElement(params, SL20Constants.SL20_COMMAND_PARAM_EID_EIDAS_AUTH, eidasAuthentication, false);
addSingleStringElement(params, SL20Constants.SL20_COMMAND_PARAM_EID_DATAURL, dataUrl, true);
addSingleCertificateElement(params, SL20Constants.SL20_COMMAND_PARAM_EID_X5CENC, x5cEnc, false);
return params;
--
cgit v1.2.3