<%@ page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" trimDirectiveWhitespaces="true" %> <%@ taglib prefix="fsp" uri="FIRSTpersonalisation" %> <%! /** * Checks if goven roles are contained by roles cookie. checkAllRoles defines, if all roles need to be in cookie (-> true) or just one of them (-> false) **/ private boolean checkRoles(Cookie[] cookies, java.util.List roles, boolean checkAllRoles, boolean negateCondition) { boolean returnValue = true; if (roles!= null && !roles.isEmpty()) { java.util.List currentRoles = new java.util.ArrayList(); if (cookies != null) { for (Cookie currentCookie : cookies) { if (currentCookie.getName().equals("GRIT.GWA.ROLES")) { String value = currentCookie.getValue(); if (value != null && !"".equals(value)) { String decryptValue = decrypt(value); if (decryptValue != null) { String[] valueArray = decryptValue.split(","); java.util.Collections.addAll(currentRoles, valueArray); } } } } } if (negateCondition) { if (checkAllRoles) { // if one role from roles is contained by currentRoles, return true, // because we need to check if ALL roles from roles are contained by currentRoles returnValue = true; for (Object role : roles) { returnValue = returnValue && currentRoles.contains((String)role); } } else { returnValue = true; // if one role from roles is contained by currentRoles, return false for (Object role : roles) { if (currentRoles.contains((String)role)) { returnValue = false; } } } } else { // regular check if (checkAllRoles) { // all roles from roles must be contained by currentRoles returnValue = currentRoles.containsAll(roles); } else { returnValue = false; // only one role from roles must be contained by currentRoles for (Object role : roles) { if (currentRoles.contains((String)role)) { returnValue = true; } } } } } return returnValue; } /** * Compute key for decryption **/ private static javax.crypto.spec.SecretKeySpec setKey(char[] myKey) { java.security.MessageDigest sha; javax.crypto.spec.SecretKeySpec secretKey = null; try { final java.nio.ByteBuffer bb = java.nio.charset.StandardCharsets.UTF_8.encode(java.nio.CharBuffer.wrap(myKey)); byte[] key = new byte[bb.remaining()]; bb.get(key); sha = java.security.MessageDigest.getInstance("SHA-256"); key = sha.digest(key); key = java.util.Arrays.copyOf(key, 16); secretKey = new javax.crypto.spec.SecretKeySpec(key, "AES"); } catch (java.security.NoSuchAlgorithmException e) { // do nothing } return secretKey; } /** * Decrypt given string **/ public static String decrypt(String strToDecrypt) { try { javax.crypto.spec.SecretKeySpec secretKey = setKey("CHANGE-ME-GROHEWEBAPP".toCharArray()); javax.crypto.Cipher cipher = javax.crypto.Cipher.getInstance("AES"); cipher.init(javax.crypto.Cipher.DECRYPT_MODE, secretKey); return new String(cipher.doFinal(java.util.Base64.getUrlDecoder().decode(strToDecrypt))); } catch (Exception e) { // do nothing } return ""; } private String showRoles(Cookie[] cookies) { String returnValue = ""; if (cookies != null) { for (Cookie currentCookie : cookies) { if (currentCookie.getName().equals("GRIT.GWA.ROLES")) { String value = currentCookie.getValue(); if (value != null && !"".equals(value)) { returnValue = decrypt(value); } } } } return returnValue; } private boolean checkRolesSet(Cookie[] cookies) { boolean returnValue = false; if (cookies != null) { for (Cookie currentCookie : cookies) { if (currentCookie.getName().equals("GRIT.GWA.ROLES")) { returnValue = true; break; } } } return returnValue; } public boolean includeContentByTargetGroup(String allowedGroups, String targetGroup) { return allowedGroups.contains(targetGroup); } %> <% java.util.Set possibleCookieValues = new java.util.HashSet(); possibleCookieValues.add("daa"); possibleCookieValues.add("end"); possibleCookieValues.add("inst"); java.lang.String targetGroupCookieValue = ""; if(request != null){ java.lang.String targetGroupRequestParameter = request.getParameter("target_group"); if(targetGroupRequestParameter != null && !targetGroupRequestParameter.isEmpty() && possibleCookieValues.contains(targetGroupRequestParameter)){ targetGroupCookieValue = targetGroupRequestParameter; javax.servlet.http.Cookie targetGroupCookie = new javax.servlet.http.Cookie("target_group", targetGroupRequestParameter); targetGroupCookie.setPath("/"); response.addCookie(targetGroupCookie); } //String targetGroup = getTargetGroupFromCookie(); } %> <%@ taglib prefix="fsp" uri="FIRSTpersonalisation" %> Patent Notice | GROHE
<% boolean set_secondary_nav_open = false; String cookieValue = ""; if (targetGroupCookieValue != null && !targetGroupCookieValue.isEmpty()) { cookieValue = targetGroupCookieValue; } else if (request != null) { Cookie[] cookies = request.getCookies(); String cookieName = "target_group"; if (cookies != null) { for (Cookie currentCookie : cookies) { if (currentCookie.getName().equals(cookieName)) { if (currentCookie.getValue() != null) { cookieValue = currentCookie.getValue(); } } } } } %><% boolean daa = includeContentByTargetGroup("daa",cookieValue); boolean daa_inst = includeContentByTargetGroup("daa_inst",cookieValue); boolean daa_end = includeContentByTargetGroup("daa_end",cookieValue); boolean daa_end_inst = includeContentByTargetGroup("daa_end_inst",cookieValue); boolean end = includeContentByTargetGroup("end",cookieValue); boolean end_inst = includeContentByTargetGroup("end_inst",cookieValue); boolean inst = includeContentByTargetGroup("inst",cookieValue); %>

Patent Notice

<% boolean showContent1610573052973 = true; if(showContent1610573052973) {%>

Grohe is licensed to use map-related services on this website under: U.S. Patent Nos., 7,555,725, 8,468,464, 570,047, 10,365,795, and 10,444,943; U.S. Patent Application No. 16/516,215; European Patent Nos. EP 1 433 132 amd EP 2 336 970; European Patent Application No. EP 16161233.8-1972; and Japanese Patent No. JP 5102124; and any patent or parent application which claims priority of US Application No. 60/287,339 or any of the above patents and patent applications.

<% } // end of if %>
utilizziamo i nostri cookie e quelli dei terzi a fine pubblicitari per migliorare la tua esperienza sul nostro sito e i nostri servizi analizzando la navigazione dell’utente sul nostro sito web. Se continui a navigare, accetterai l’uso dei cookie. Puoi rifiutare l’installazione di tali cookie. Per saperne di più, clicca qui