summaryrefslogtreecommitdiff
path: root/src/main
diff options
context:
space:
mode:
authorLeif Johansson <leifj@sunet.se>2011-07-26 00:24:27 +0200
committerLeif Johansson <leifj@sunet.se>2011-07-26 00:24:27 +0200
commit9d63824f3e9270a92cee88f893a3292a5b83897c (patch)
treeaee3c16c09e1f195250454391047d87c15b62e89 /src/main
parent5f66382e3f4fc7f78df06bfc40036c0c124ded52 (diff)
call jquery library
Diffstat (limited to 'src/main')
-rw-r--r--src/main/webapp/wayf-ndn.jsp268
1 files changed, 268 insertions, 0 deletions
diff --git a/src/main/webapp/wayf-ndn.jsp b/src/main/webapp/wayf-ndn.jsp
new file mode 100644
index 0000000..3060b1d
--- /dev/null
+++ b/src/main/webapp/wayf-ndn.jsp
@@ -0,0 +1,268 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<%@ page contentType="text/html;charset=UTF-8" %>
+<html>
+
+<%@ taglib uri="/WEB-INF/tlds/struts-logic.tld" prefix="logic" %>
+<%@ taglib uri="/WEB-INF/tlds/struts-bean.tld" prefix="bean" %>
+
+<%request.setCharacterEncoding("UTF-8");%>
+<%response.setCharacterEncoding("UTF-8");%>
+
+<logic:present name="showComments" scope="Request">
+
+<!-- TO CONFIGURE THIS FOR A SPECIFIC SITE
+ =====================================
+
+ Before you deploy this jsp you need to look for CONFIG below.
+ These mark places where you should make changes.
+
+ If you want to make more profound changes but only to the jsp,
+ you should read the sections marked PROGRAMMING NOTE below.-->
+
+<!-- PROGRAMMING NOTE
+
+ "requestURL" contains the URL that was specified to get the
+ WAYF going. The jsp uses it mostly for submitting result back to
+ the WAYF and error reporting -->
+
+</logic:present>
+
+ <jsp:useBean id="requestURL" scope="request" class="java.lang.String"/>
+
+<logic:present name="showComments" scope="Request">
+
+<!-- PROGRAMMING NOTE
+
+ shire, target, provider and time are all part of the Shibboleth
+ 1.3 discovery protocol and need to be specified as parameters to the WAYF
+
+ entityID, return, returnIDParam are all part of the
+ SAML Discovery protocol.
+
+
+-->
+</logic:present>
+
+<logic:notPresent name="entityID" scope="request">
+<logic:notPresent name="shire" scope="request">
+
+<jsp:forward page = "wayferror.jsp"/>
+</logic:notPresent>
+</logic:notPresent>
+
+
+<logic:present name="showComments" scope="Request">
+
+<!-- PROGRAMMING NOTE
+ In addition to the above. The WAYF may also supply the following to
+ the jsp.
+
+ "cookieList" If this exists it represents the contents of the
+ _saml_idp cookie (possibly filtered to remove IdPs which
+ cannot serve the SP). It is a Collection of IdPSite objects,
+ which themselves have the following properties:
+
+ "name" The uri for the IdP, which needs to be returned to the
+ WAYF in the "origin" parameter.
+
+ "displayName" User friendly name (taken from its alias)
+
+ "addressFor" The (ungarnished) URL for the IdP. This could be
+ used to create a direct hyperlink to the IdP
+
+ "sites" If this exists it contains all the possible IdPs for for
+ the SP (possibly filtered). It is a Collection of IdPSite
+ Objects which are described above. This is only present if
+ provideList was defined true in the configuration.
+
+ "siteLists" If this exists it contains all the possible metadata
+ files which can service for the SP (possibly filtered). It
+ is a collection of IdPSiteSetEntry Objects which have two
+ properties:
+
+ "name" This is the displayName from the Metadata element in
+ the WAYF configuration file
+
+ "sites" This represents the IdPs. Again it is a collection
+ of IdPSite Objects
+
+ It is only present if provideListOfList was defined true in
+ the configuration.
+
+ "singleSiteList" if this is present, then there is only one
+ IdPSiteSetEntry Object in "siteLists".
+
+ "searchresultempty" If this is present then it means that a
+ search was performed, but no suitable IdPs were returned.
+
+ "searchresults" If this is present it represents the list of IdPs
+ which matched a previous search. It is a Collection of
+ IdPSite Objects. -->
+
+<!-- PROGRAMMING NOTE
+
+ The jsp communicates back to the WAYF via the parameters listed
+ above, and:
+
+ "action" what the WAYF has to do. Possible contents are:
+
+ "lookup" - refresh the screen.
+ "search" - perform a search on the contents parameter "string"
+ "selection" - redirect to the IdP with the uri "origin"
+
+ "cache" preserve any selection in the _saml_idp cookie. A
+ value of "session" makes the cookie last for the browser
+ session, "perm" gives it the lifetime specified in the
+ configuration file.
+
+ The tabindex is hard wired. Fortunately the standard allows us to
+ have duplicate numbers and says the order is the order things
+ get emitted. We use these numbers
+
+ 10 - Recently used sites hyperlinks
+ 20 - <clear button for above>
+ 25 - AutoSuggestion
+ 30 Federation selection
+ 40 IdP within Selection
+ 50 Select button
+ 60 How long to remember selector
+ 70 Search entry
+ 80 Search Button
+ 90 List of search results
+ 100 Select search result
+ 110 How long to remember search results
+ 120 Hyperlink to admin user.
+
+-->
+
+</logic:present>
+
+<head>
+ <link rel="stylesheet" title="normal" type="text/css" href="wayf.css" />
+ <link type="text/css" href="css/ui-lightness/jquery-ui-1.8.14.custom.css" rel="stylesheet" />
+ <script type="text/javascript" src="js/jquery-1.5.1.min.js"></script>
+ <script type="text/javascript" src="js/jquery-ui-1.8.14.custom.min.js"></script>
+ <title>Identity Provider Selection</title>
+ <script type="text/javascript">
+$(function() {
+ $("input:submit, input:reset, input:button, a",".button").button();
+ $("#sites").tabs();
+});
+ <script>
+</head>
+
+<body>
+ <div class="head">
+ <h1>
+
+Select an identity provider
+
+ </h1>
+ </div>
+
+ <div class="selector">
+ <p class="text">The service you are trying to use require that you identify yourself. Please select your identity provider below...</p>
+
+ <logic:present name="siteLists" scope="request">
+ <div id="sites">
+ <ul>
+ <logic:present name="cookieList" scope="request">
+ <li><a href="#recently-visited">Recently Visited</a></li>
+ </logic:present>
+ <logic:iterate id="siteset" name="siteLists">
+ <li><a href="#<jsp:getProperty name="siteset" property="name"/>"<a href="<jsp:getProperty name="siteset" property="name"/></a></li>
+ </logic:iterate>
+ </ul>
+ <logic:present name="cookieList" scope="request">
+ <div id="recently-visited">
+ <ul class="sitelist">
+ <logic:iterate id="site" name="cookieList">
+ <li>
+ <logic:present name="entityID" scope="request">
+
+ <bean:define id="returnIDParam" name="returnIDParam"/>
+ <bean:define id="ei" name="entityID" />
+ <bean:define id="re" name="returnX"/>
+
+ <a tabindex="10" href="<bean:write name="requestURL" />?entityID=<%= java.net.URLEncoder.encode(ei.toString(), "utf-8") %>&return=<%= java.net.URLEncoder.encode(re.toString(), "utf-8") %>&returnIDxParam=<%= java.net.URLEncoder.encode( returnIDParam.toString(), "utf-8" ) %>&cache=perm&action=selection&origin=<jsp:getProperty name="site" property="name" />">
+ <jsp:getProperty name="site" property="displayName" />
+ </a>
+ </logic:present>
+ <logic:notPresent name="entityID" scope="request">
+ <bean:define id="targ" name="target" />
+ <bean:define id="shire" name="shire" />
+ <bean:define id="pid" name="providerId" />
+ <a tabindex="10" href="<bean:write name="requestURL" />?target=<%= java.net.URLEncoder.encode(targ.toString(),"utf-8") %>&shire=<%= java.net.URLEncoder.encode(shire.toString(),"utf-8") %>&providerId=<%= java.net.URLEncoder.encode(pid.toString(),"utf-8") %>&time=<bean:write name="time" />&cache=perm&action=selection&origin=<jsp:getProperty name="site" property="name" />">
+ <jsp:getProperty name="site"
+ property="displayName" />
+ </a>
+ </logic:notPresent>
+ </li>
+ </logic:iterate>
+ </ul>
+ <form method="get" action="ClearCache.wayf" >
+ <div>
+ <logic:notPresent name="entityID" scope="request">
+ <input type="hidden" name="shire" value="<bean:write name="shire" />" />
+ <input type="hidden" name="target" value="<bean:write name="target" />" />
+ <input type="hidden" name="providerId" value="<bean:write name="providerId" />" />
+ <logic:present name="time" scope="request">
+ <input type="hidden" name="time" value="<bean:write name="time" />" />
+ </logic:present>
+ </logic:notPresent>
+ <logic:present name="entityID" scope="request">
+ <input type="hidden" name="entityID" value="<bean:write name="entityID" />" />
+ <input type="hidden" name="returnX" value="<bean:write name="returnX" />" />
+ <input type="hidden" name="returnIDParam" value="<bean:write name="returnIDParam" />" />
+ </logic:present>
+ <input tabindex="20" type="submit" value="Clear List" />
+ </div>
+ </form>
+ </div>
+ </logic:present>
+ <logic:iterate id="siteset" name="siteLists">
+ <div id="<jsp:getProperty name="siteset" property="name"/>">
+ <ul class="sitelist">
+ <logic:iterate id="site" name="siteset" property="sites">
+ <li>
+ <logic:present name="entityID" scope="request">
+
+ <bean:define id="returnIDParam" name="returnIDParam"/>
+ <bean:define id="ei" name="entityID" />
+ <bean:define id="re" name="returnX"/>
+
+ <a href="<bean:write name="requestURL" />?entityID=<%= java.net.URLEncoder.encode(ei.toString(), "utf-8") %>&return=<%= java.net.URLEncoder.encode(re.toString(), "utf-8") %>&returnIDxParam=<%= java.net.URLEncoder.encode( returnIDParam.toString(), "utf-8" ) %>&cache=perm&action=selection&origin=<jsp:getProperty name="site" property="name" />">
+ <jsp:getProperty name="site" property="displayName" />
+ </a>
+ </logic:present>
+ <logic:notPresent name="entityID" scope="request">
+ <bean:define id="targ" name="target" />
+ <bean:define id="shire" name="shire" />
+ <bean:define id="pid" name="providerId" />
+ <a href="<bean:write name="requestURL" />?target=<%= java.net.URLEncoder.encode(targ.toString(),"utf-8") %>&shire=<%= java.net.URLEncoder.encode(shire.toString(),"utf-8") %>&providerId=<%= java.net.URLEncoder.encode(pid.toString(),"utf-8") %>&time=<bean:write name="time" />&cache=perm&action=selection&origin=<jsp:getProperty name="site" property="name" />">
+ <jsp:getProperty name="site"
+ property="displayName" />
+ </a>
+ </logic:notPresent>
+ </li>
+ </logic:iterate>
+ </ul>
+ </div>
+ </logic:iterate>
+ </div>
+ </logic:present>
+ </div>
+
+ <div class="footer">
+ <p class="text">
+<!--CONFIG-->
+Need assistance? Send mail to <a tabindex="120" href="mailto:noc@nordu.net">NORDUnet NOC</a> with description.
+ </p>
+ <div class="logo"><img src="images/NORDUnet2.jpg" alt="NORDUNet" /></div>
+ </div>
+
+</body>
+</html>
+