diff options
Diffstat (limited to 'id/ConfigWebTool/src')
5 files changed, 128 insertions, 8 deletions
diff --git a/id/ConfigWebTool/src/main/java/at/gv/egovernment/moa/id/configuration/data/GeneralMOAIDConfig.java b/id/ConfigWebTool/src/main/java/at/gv/egovernment/moa/id/configuration/data/GeneralMOAIDConfig.java index 4da4d3907..c6b9b984a 100644 --- a/id/ConfigWebTool/src/main/java/at/gv/egovernment/moa/id/configuration/data/GeneralMOAIDConfig.java +++ b/id/ConfigWebTool/src/main/java/at/gv/egovernment/moa/id/configuration/data/GeneralMOAIDConfig.java @@ -40,10 +40,12 @@ import at.gv.egovernment.moa.id.commons.db.dao.config.IdentificationNumber; import at.gv.egovernment.moa.id.commons.db.dao.config.LegacyAllowed; import at.gv.egovernment.moa.id.commons.db.dao.config.MOAIDConfiguration; import at.gv.egovernment.moa.id.commons.db.dao.config.MOASP; +import at.gv.egovernment.moa.id.commons.db.dao.config.OAuth; import at.gv.egovernment.moa.id.commons.db.dao.config.OnlineMandates; import at.gv.egovernment.moa.id.commons.db.dao.config.Organization; import at.gv.egovernment.moa.id.commons.db.dao.config.PVP2; import at.gv.egovernment.moa.id.commons.db.dao.config.Protocols; +import at.gv.egovernment.moa.id.commons.db.dao.config.SAML1; import at.gv.egovernment.moa.id.commons.db.dao.config.SLRequestTemplates; import at.gv.egovernment.moa.id.commons.db.dao.config.SSO; import at.gv.egovernment.moa.id.commons.db.dao.config.STORK; @@ -81,6 +83,10 @@ public class GeneralMOAIDConfig { private String mandateURL = null; + private boolean protocolActiveSAML1 = false; + private boolean protocolActivePVP21 = true; + private boolean protocolActiveOAuth = true; + private boolean legacy_saml1 = false; private boolean legacy_pvp2 = false; @@ -205,8 +211,23 @@ public class GeneralMOAIDConfig { legacy_pvp2 = true; } + SAML1 saml1 = protocols.getSAML1(); + if (saml1 != null) { + protocolActiveSAML1 = saml1.isIsActive(); + + } + + OAuth oauth = protocols.getOAuth(); + if (oauth != null) { + protocolActiveOAuth = saml1.isIsActive(); + + } + PVP2 pvp2 = protocols.getPVP2(); if (pvp2 != null) { + + protocolActivePVP21 = pvp2.isIsActive(); + pvp2PublicUrlPrefix = pvp2.getPublicURLPrefix(); pvp2IssuerName = pvp2.getIssuerName(); @@ -850,6 +871,49 @@ public class GeneralMOAIDConfig { this.fileUploadFileName = new ArrayList<String>(); this.fileUploadFileName.add(fileUploadFileName); } + + /** + * @return the protocolActiveSAML1 + */ + public boolean isProtocolActiveSAML1() { + return protocolActiveSAML1; + } + + /** + * @param protocolActiveSAML1 the protocolActiveSAML1 to set + */ + public void setProtocolActiveSAML1(boolean protocolActiveSAML1) { + this.protocolActiveSAML1 = protocolActiveSAML1; + } + + /** + * @return the protocolActivePVP21 + */ + public boolean isProtocolActivePVP21() { + return protocolActivePVP21; + } + + /** + * @param protocolActivePVP21 the protocolActivePVP21 to set + */ + public void setProtocolActivePVP21(boolean protocolActivePVP21) { + this.protocolActivePVP21 = protocolActivePVP21; + } + + /** + * @return the protocolActiveOAuth + */ + public boolean isProtocolActiveOAuth() { + return protocolActiveOAuth; + } + + /** + * @param protocolActiveOAuth the protocolActiveOAuth to set + */ + public void setProtocolActiveOAuth(boolean protocolActiveOAuth) { + this.protocolActiveOAuth = protocolActiveOAuth; + } + } diff --git a/id/ConfigWebTool/src/main/java/at/gv/egovernment/moa/id/configuration/struts/action/EditGeneralConfigAction.java b/id/ConfigWebTool/src/main/java/at/gv/egovernment/moa/id/configuration/struts/action/EditGeneralConfigAction.java index f1a8c8694..362579c9f 100644 --- a/id/ConfigWebTool/src/main/java/at/gv/egovernment/moa/id/configuration/struts/action/EditGeneralConfigAction.java +++ b/id/ConfigWebTool/src/main/java/at/gv/egovernment/moa/id/configuration/struts/action/EditGeneralConfigAction.java @@ -53,10 +53,12 @@ import at.gv.egovernment.moa.id.commons.db.dao.config.IdentityLinkSigners; import at.gv.egovernment.moa.id.commons.db.dao.config.LegacyAllowed; import at.gv.egovernment.moa.id.commons.db.dao.config.MOAIDConfiguration; import at.gv.egovernment.moa.id.commons.db.dao.config.MOASP; +import at.gv.egovernment.moa.id.commons.db.dao.config.OAuth; import at.gv.egovernment.moa.id.commons.db.dao.config.OnlineMandates; import at.gv.egovernment.moa.id.commons.db.dao.config.Organization; import at.gv.egovernment.moa.id.commons.db.dao.config.PVP2; import at.gv.egovernment.moa.id.commons.db.dao.config.Protocols; +import at.gv.egovernment.moa.id.commons.db.dao.config.SAML1; import at.gv.egovernment.moa.id.commons.db.dao.config.SLRequestTemplates; import at.gv.egovernment.moa.id.commons.db.dao.config.SSO; import at.gv.egovernment.moa.id.commons.db.dao.config.STORK; @@ -271,11 +273,28 @@ public class EditGeneralConfigAction extends ActionSupport el.add(Constants.MOA_CONFIG_PROTOCOL_SAML1); legprot.setProtocolName(el); + SAML1 saml1= dbprotocols.getSAML1(); + if (saml1 == null) { + saml1 = new SAML1(); + dbprotocols.setSAML1(saml1); + } + saml1.setIsActive(moaconfig.isProtocolActiveSAML1()); + + OAuth oauth= dbprotocols.getOAuth(); + if (oauth == null) { + oauth = new OAuth(); + dbprotocols.setOAuth(oauth); + } + oauth.setIsActive(moaconfig.isProtocolActiveOAuth()); + PVP2 pvp2 = dbprotocols.getPVP2(); if (pvp2 == null) { pvp2 = new PVP2(); dbprotocols.setPVP2(pvp2); } + + pvp2.setIsActive(moaconfig.isProtocolActivePVP21()); + if (MiscUtil.isNotEmpty(moaconfig.getPvp2IssuerName())) pvp2.setIssuerName(moaconfig.getPvp2IssuerName()); if (MiscUtil.isNotEmpty(moaconfig.getPvp2PublicUrlPrefix())) diff --git a/id/ConfigWebTool/src/main/resources/applicationResources.properties b/id/ConfigWebTool/src/main/resources/applicationResources.properties index 456c37ff1..454175125 100644 --- a/id/ConfigWebTool/src/main/resources/applicationResources.properties +++ b/id/ConfigWebTool/src/main/resources/applicationResources.properties @@ -124,9 +124,11 @@ webpages.moaconfig.sso.FriendlyName=SSO Service Name webpages.moaconfig.services.sso.Target=SSO Service Target webpages.moaconfig.services.sso.SpecialText=SSO AuthBlockText webpages.moaconfig.protocols.header=Protokolle +webpages.moaconfig.protocols.allowed.header=Protokolle aktivieren webpages.moaconfig.protocols.legacy.header=Legacy Modus aktivieren webpages.moaconfig.protocols.legacy.saml1=SAML1 webpages.moaconfig.protocols.legacy.pvp2=PVP2.1 +webpages.moaconfig.protocols.oauth=OpenID Connect webpages.moaconfig.protocols.pvp2.header=PVP2 Konfiguration webpages.moaconfig.protocols.pvp2.PublicUrlPrefix=PVP2 Service URL-Prefix webpages.moaconfig.protocols.pvp2.IssuerName=PVP Service Name diff --git a/id/ConfigWebTool/src/main/webapp/css/index.css b/id/ConfigWebTool/src/main/webapp/css/index.css index 14591f1dc..79f8b4e72 100644 --- a/id/ConfigWebTool/src/main/webapp/css/index.css +++ b/id/ConfigWebTool/src/main/webapp/css/index.css @@ -1,10 +1,14 @@ @CHARSET "UTF-8"; +body { + font-size: 1em; +} + #header_area { padding-bottom: 10px; background-color: #6FA5D4; display: block; - font-size: 20px; + font-size: 1.2em; /* margin-left: 25px; */ padding-top: 10px; padding-left: 25px; @@ -12,7 +16,7 @@ } #header_area>div { - font-size: 20px; + font-size: 1.2em; margin-left: 25px; padding-top: 8px; } @@ -69,7 +73,7 @@ .menu_element { margin-top: 15px; margin-bottom: 15px; - font-size: 20px; + font-size: 1.2em; display: block; /* background-color: red; */ background-color: #6FA5D4; @@ -96,7 +100,7 @@ } #message_area label { - font-size: 18px; + font-size: 1.1em; font-weight: bold; } @@ -105,7 +109,7 @@ } #error_area label{ - font-size: 18px; + font-size: 1.1em; font-weight: bold; } @@ -220,6 +224,11 @@ margin-left: 10px; } +#moageneral_active_protocol>.wwgrp { + float: left; + clear: none; +} + #moageneral_legacy_protocol>.wwgrp { clear: none; } @@ -318,7 +327,7 @@ div .wwgrp br { border-bottom-style: none; display: table-header-group; font-weight: bold; - font-size: 18px; + font-size: 1.1em; } .listFirst { @@ -371,7 +380,7 @@ div .wwgrp br { padding-left: 30px; position: relative; top: 15px; - font-size: 20px; + font-size: 1.2em; text-align: center; padding-top: 10px; border-radius: 3px; diff --git a/id/ConfigWebTool/src/main/webapp/jsp/editMOAConfig.jsp b/id/ConfigWebTool/src/main/webapp/jsp/editMOAConfig.jsp index 05f4a1106..de2548535 100644 --- a/id/ConfigWebTool/src/main/webapp/jsp/editMOAConfig.jsp +++ b/id/ConfigWebTool/src/main/webapp/jsp/editMOAConfig.jsp @@ -228,7 +228,31 @@ <div class="oa_config_block"> <h3><%=LanguageHelper.getGUIString("webpages.moaconfig.protocols.header", request) %></h3> - + + <div id="moageneral_active_protocol" class="moageneral_protocol_area"> + <h4><%=LanguageHelper.getGUIString("webpages.moaconfig.protocols.allowed.header", request) %></h4> + <s:checkbox name="moaconfig.protocolActiveSAML1" + value="%{moaconfig.protocolActiveSAML1}" + labelposition="left" + key="webpages.moaconfig.protocols.legacy.saml1" + cssClass="checkbox"> + </s:checkbox> + <s:checkbox name="moaconfig.protocolActivePVP21" + value="%{moaconfig.protocolActivePVP21}" + labelposition="left" + key="webpages.moaconfig.protocols.legacy.pvp2" + cssClass="checkbox"> + </s:checkbox> + <s:checkbox name="moaconfig.protocolActiveOAuth" + value="%{moaconfig.protocolActiveOAuth}" + labelposition="left" + key="webpages.moaconfig.protocols.oauth" + cssClass="checkbox"> + </s:checkbox> + </div> + + <br> + <div id="moageneral_legacy_protocol" class="moageneral_protocol_area"> <h4><%=LanguageHelper.getGUIString("webpages.moaconfig.protocols.legacy.header", request) %></h4> <s:checkbox name="moaconfig.legacy_saml1" @@ -245,6 +269,8 @@ </s:checkbox> </div> + <br> + <div class="moageneral_protocol_area"> <h4><%=LanguageHelper.getGUIString("webpages.moaconfig.protocols.pvp2.header", request) %></h4> |