}
if (xsdFile.endsWith(".xsd")) {
InputStream stream =
- context.getResourceAsStream("/WEB-INF/schemas/" + xsdFile);
+ context.getResourceAsStream("/WEB-INF/classes/schemas/" + xsdFile);
if (stream != null) {
return new InputSource(stream);
}
* Determines if a given string matches one of the registered names/aliases of this origin.
* @param str The string to match on
*/
- public boolean isMatch(String str) {
+ public boolean isMatch(String str, WayfConfig config) {
Enumeration input = new StringTokenizer(str);
while (input.hasMoreElements()) {
String currentToken = (String) input.nextElement();
- if (WayfConfig.isIgnoredForMatch(currentToken)) {
+ if (config.isIgnoredForMatch(currentToken)) {
continue;
}
import java.util.ArrayList;
+import org.apache.log4j.Logger;
+
/**
* This class is used to create logical groupings of shibboleth Origin Sites.
* Each grouping is associated with a textual name that might be displayed
public class OriginSet {
private ArrayList origins = new ArrayList();
- ;
+ private static Logger log = Logger.getLogger(OriginSet.class.getName());
private String name;
- /**
- * Gets the name.
- * @return Returns a String
- */
+
public String getName() {
return name;
}
- /**
- * Sets the name.
- * @param name The name to set
- */
public void setName(String name) {
this.name = name;
}
- /**
- * Gets the origins.
- * @return Returns a Origin[]
- */
public Origin[] getOrigins() {
return (Origin[]) origins.toArray(new Origin[0]);
}
- /**
- * Sets the origins.
- * @param origins The origins to set
- */
public void addOrigin(Origin origin) {
origins.add(origin);
+ log.debug("Adding an origin site to configuration.");
}
}
--- /dev/null
+package edu.internet2.middleware.shibboleth.wayf;
+
+import javax.servlet.ServletContext;
+import javax.xml.parsers.SAXParser;
+
+import org.xml.sax.XMLReader;
+
+import edu.internet2.middleware.shibboleth.common.ServletDigester;
+
+/**
+ * @author Administrator
+ *
+ * To change this generated comment edit the template variable "typecomment":
+ * Window>Preferences>Java>Templates.
+ * To enable and disable the creation of type comments go to
+ * Window>Preferences>Java>Code Generation.
+ */
+public class OriginSitesDigester extends ServletDigester {
+
+ protected String originClass =
+ "edu.internet2.middleware.shibboleth.wayf.Origin";
+ protected String wayfDataClass =
+ "edu.internet2.middleware.shibboleth.wayf.WayfOrigins";
+ protected String originSetClass =
+ "edu.internet2.middleware.shibboleth.wayf.OriginSet";
+
+ private boolean configured = false;
+
+ /**
+ * Constructor for OriginSitesDigester.
+ */
+ public OriginSitesDigester() {
+ super();
+ }
+
+ /**
+ * Constructor for OriginSitesDigester.
+ * @param context
+ */
+ public OriginSitesDigester(ServletContext context) {
+ super(context);
+ }
+
+ /**
+ * Constructor for OriginSitesDigester.
+ * @param parser
+ */
+ public OriginSitesDigester(SAXParser parser) {
+ super(parser);
+ }
+
+ /**
+ * Constructor for OriginSitesDigester.
+ * @param reader
+ */
+ public OriginSitesDigester(XMLReader reader) {
+ super(reader);
+ }
+
+ /**
+ * @see Digester#configure()
+ */
+ protected void configure() {
+
+ if (configured == true) {
+ return;
+ }
+ addObjectCreate("Sites", wayfDataClass);
+ addObjectCreate("Sites/SiteGroup", originSetClass);
+ addSetNext("Sites/SiteGroup", "addOriginSet", originSetClass);
+ addCallMethod("Sites/SiteGroup", "setName", 1);
+ addCallParam("Sites/SiteGroup", 0, "Name");
+ addObjectCreate("Sites/SiteGroup/OriginSite", originClass);
+ addSetNext("Sites/SiteGroup/OriginSite", "addOrigin", originClass);
+ addCallMethod("Sites/SiteGroup/OriginSite", "setName", 1);
+ addCallParam("Sites/SiteGroup/OriginSite", 0, "Name");
+ addSetProperties("Sites/SiteGroup/OriginSite");
+ addCallMethod("Sites/SiteGroup/OriginSite/Alias", "addAlias", 0);
+ addCallMethod("Sites/SiteGroup/OriginSite", "setHandleService", 1);
+ addCallParam("Sites/SiteGroup/OriginSite/HandleService", 0, "Location");
+
+ configured = true;
+
+ }
+
+}
+
private static Logger log =
Logger.getLogger(WayfCacheFactory.class.getName());
- public static WayfCache getInstance() {
+ public static WayfCache getInstance(String cacheType) {
- if (WayfConfig.getCache().equals("NONE")) {
+ if (cacheType.equals("NONE")) {
return new NullWayfCache();
- } else if (WayfConfig.getCache().equals("SESSION")) {
+ } else if (cacheType.equals("SESSION")) {
return new SessionWayfCache();
- } else if (WayfConfig.getCache().equals("COOKIES")) {
+ } else if (cacheType.equals("COOKIES")) {
return new CookieWayfCache();
} else {
log.warn(
private static Logger log = Logger.getLogger(WayfConfig.class.getName());
- private static WayfOrigins wd;
- private static String location;
- private static String logoLocation = "images/internet2.gif";
- private static String supportContact = "mailto:shib-support@internet2.org";
- private static String helpText =
+ private String logoLocation = "images/internet2.gif";
+ private String supportContact = "mailto:shib-support@internet2.org";
+ private String helpText =
"In order to fulfill the request for the web resource you "
+ "have just chosen, information must first be obtained from "
+ "your home institution. Please select the institution with "
+ "which you are affiliated.";
- private static String searchResultEmptyText =
- "No institution found that matches your search "
- + "criteria, please try again.";
- private static HashSet ignoredForMatch = new HashSet();
+ private String searchResultEmptyText =
+ "No institution found that matches your search " + "criteria, please try again.";
+ private HashSet ignoredForMatch = new HashSet();
- private static String cache = "SESSION";
+ private String cacheType = "COOKIES";
public WayfConfig() {
super();
}
- public static WayfOrigins getWAYFData() {
- return wd;
- }
-
- public void setWAYFData(WayfOrigins wd) {
- WayfConfig.wd = wd;
- }
-
- public static String getSearchResultEmptyText() {
+ public String getSearchResultEmptyText() {
return searchResultEmptyText;
}
public void setSearchResultEmptyText(String searchResultEmptyText) {
- WayfConfig.searchResultEmptyText = searchResultEmptyText;
+ this.searchResultEmptyText = searchResultEmptyText;
}
- public static String getHelpText() {
+ public String getHelpText() {
return helpText;
}
public void setHelpText(String helpText) {
- WayfConfig.helpText = helpText;
+ this.helpText = helpText;
}
- public static String getSupportContact() {
+ public String getSupportContact() {
return supportContact;
}
public void setSupportContact(String supportContact) {
- WayfConfig.supportContact = supportContact;
+ this.supportContact = supportContact;
}
- public static String getLogoLocation() {
+ public String getLogoLocation() {
return logoLocation;
}
public void setLogoLocation(String logoLocation) {
- WayfConfig.logoLocation = logoLocation;
- }
-
- public static String getLocation() {
- return location;
- }
-
- public void setLocation(String location) {
- WayfConfig.location = location;
+ this.logoLocation = logoLocation;
}
/**
* Determines if a particular string token should be used for matching when a user searches for origins.
* @param str The string to lookup
*/
- public static boolean isIgnoredForMatch(String str) {
+ public boolean isIgnoredForMatch(String str) {
if (ignoredForMatch.contains(str.toLowerCase())) {
return true;
ignoredForMatch.add(s.toLowerCase());
}
- public static String getCache() {
- return cache;
+ public String getCacheType() {
+ return cacheType;
}
- public void setCache(String cache) {
+ public void setCacheType(String cache) {
if (cache.toUpperCase().equals("NONE")
|| cache.toUpperCase().equals("SESSION")
|| cache.toUpperCase().equals("COOKIES")) {
- WayfConfig.cache = cache.toUpperCase();
+ this.cacheType = cache.toUpperCase();
} else {
- log.warn(
- "Cache type :" + cache + ": not recognized, using default.");
+ log.warn("Cache type :" + cache + ": not recognized, using default.");
}
}
package edu.internet2.middleware.shibboleth.wayf;
+import javax.servlet.ServletContext;
import javax.xml.parsers.SAXParser;
-import org.apache.commons.digester.Digester;
+
import org.xml.sax.XMLReader;
+import edu.internet2.middleware.shibboleth.common.ServletDigester;
+
/**
* This class is a jakarta Digester style parser for the WAYF configuration file.
* It should populate the WayfConfig object during WAYF initilization. NOTE: It is
* @author Walter Hoehn wassa@columbia.edu
*/
-public class WayfConfigDigester extends Digester {
+public class WayfConfigDigester extends ServletDigester {
- protected String originClass =
- "edu.internet2.middleware.shibboleth.wayf.Origin";
- protected String wayfDataClass =
- "edu.internet2.middleware.shibboleth.wayf.WayfOrigins";
- protected String originSetClass =
- "edu.internet2.middleware.shibboleth.wayf.OriginSet";
protected String wayfConfigClass =
"edu.internet2.middleware.shibboleth.wayf.WayfConfig";
private boolean configured = false;
configure();
}
- public WayfConfigDigester(XMLReader reader) {
- super(reader);
- configure();
+ public WayfConfigDigester(ServletContext context) {
+ super(context);
}
- public String getOriginClass() {
- return originClass;
- }
- public void setOriginClass(String originClass) {
- this.originClass = originClass;
+ public WayfConfigDigester(XMLReader reader) {
+ super(reader);
+ configure();
}
/**
if (configured == true) {
return;
}
- addObjectCreate("ShibbolethConfig", wayfConfigClass);
- addSetProperties("ShibbolethConfig/WayfConfig");
- addCallMethod("ShibbolethConfig/WayfConfig/HelpText", "setHelpText", 0);
+ addObjectCreate("WayfConfig", wayfConfigClass);
+ addSetProperties("WayfConfig");
+ addCallMethod("WayfConfig/HelpText", "setHelpText", 0);
addCallMethod(
- "ShibbolethConfig/WayfConfig/SearchResultEmptyText",
+ "WayfConfig/SearchResultEmptyText",
"setSearchResultEmptyText",
0);
addCallMethod(
- "ShibbolethConfig/WayfConfig/SearchIgnore/String",
+ "WayfConfig/SearchIgnore/IgnoreText",
"addIgnoredForMatch",
0);
- addObjectCreate("ShibbolethConfig/CommonConfig", wayfDataClass);
- addSetNext(
- "ShibbolethConfig/CommonConfig",
- "setWAYFData",
- wayfDataClass);
-
- addObjectCreate(
- "ShibbolethConfig/CommonConfig/OriginSet",
- originSetClass);
- addSetNext(
- "ShibbolethConfig/CommonConfig/OriginSet",
- "addOriginSet",
- originSetClass);
- addSetProperties("ShibbolethConfig/CommonConfig/OriginSet");
-
- addObjectCreate(
- "ShibbolethConfig/CommonConfig/OriginSet/Origin",
- originClass);
- addSetNext(
- "ShibbolethConfig/CommonConfig/OriginSet/Origin",
- "addOrigin",
- originClass);
- addSetProperties("ShibbolethConfig/CommonConfig/OriginSet/Origin");
-
- addCallMethod(
- "ShibbolethConfig/CommonConfig/OriginSet/Origin/Alias",
- "addAlias",
- 1);
- addCallParam(
- "ShibbolethConfig/CommonConfig/OriginSet/Origin/Alias",
- 0,
- "name");
-
configured = true;
}
- public String getOriginSetClass() {
- return originSetClass;
- }
-
- public void setOriginSetClass(String originSetClass) {
- this.originSetClass = originSetClass;
- }
-
- public String getWayfDataClass() {
- return wayfDataClass;
- }
-
- public void setWayfDataClass(String wayfDataClass) {
- this.wayfDataClass = wayfDataClass;
- }
-
}
\ No newline at end of file
import java.util.HashSet;
import java.util.Iterator;
+import org.apache.log4j.Logger;
+
/**
* This class is a container for OriginSets, allowing lookup and searching of the same.
*
public class WayfOrigins {
private ArrayList originSets = new ArrayList();
+ private static Logger log = Logger.getLogger(WayfOrigins.class.getName());
public OriginSet[] getOriginSets() {
return (OriginSet[]) originSets.toArray(new OriginSet[0]);
public void addOriginSet(OriginSet originSet) {
originSets.add(originSet);
+ log.debug("Adding an origin set to configuration");
}
public String lookupHSbyName(String originName) {
}
- public Origin[] seachForMatchingOrigins(String searchString) {
+ public Origin[] seachForMatchingOrigins(String searchString, WayfConfig config) {
Iterator originSetIt = originSets.iterator();
HashSet searchResults = new HashSet();
OriginSet originSet = (OriginSet) originSetIt.next();
Origin[] origins = originSet.getOrigins();
for (int i = 0;(i < origins.length); i++) {
- if (origins[i].isMatch(searchString)) {
+ if (origins[i].isMatch(searchString, config)) {
searchResults.add(origins[i]);
}
}
import javax.servlet.RequestDispatcher;
import javax.servlet.ServletException;
+import javax.servlet.UnavailableException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
public class WayfService extends HttpServlet {
private String wayfConfigFileLocation;
+ private String siteConfigFileLocation;
+ private WayfConfig config;
+ private WayfOrigins originConfig;
private static Logger log = Logger.getLogger(WayfService.class.getName());
/**
public void init() throws ServletException {
super.init();
+ log.info("Initializing WAYF.");
loadInitParams();
- //initialize configuration from file
+ log.info("Loading configuration from file.");
InputStream is = getServletContext().getResourceAsStream(wayfConfigFileLocation);
- WayfConfigDigester digester = new WayfConfigDigester();
+ WayfConfigDigester digester = new WayfConfigDigester(getServletContext());
+
+ InputStream siteIs = getServletContext().getResourceAsStream(siteConfigFileLocation);
+ OriginSitesDigester siteDigester = new OriginSitesDigester(getServletContext());
+
try {
- digester.parse(is);
+ //digester.setValidating(true);
+ config = (WayfConfig) digester.parse(is);
+
+ //siteDigester.setValidating(true);
+ originConfig = (WayfOrigins) siteDigester.parse(siteIs);
+
+
} catch (SAXException se) {
log.fatal("Error parsing WAYF configuration file.", se);
- throw new ServletException("Error parsing WAYF configuration file.", se);
+ throw new UnavailableException("Error parsing WAYF configuration file.");
} catch (IOException ioe) {
log.fatal("Error reading WAYF configuration file.", ioe);
- throw new ServletException("Error reading WAYF configuration file.", ioe);
+ throw new UnavailableException("Error reading WAYF configuration file.");
}
//Setup appliation-wide beans from config
- getServletContext().setAttribute("originsets", WayfConfig.getWAYFData().getOriginSets());
- String wayfLocation = WayfConfig.getLocation();
- if (wayfLocation == null) {
- wayfLocation = "WAYF";
- }
- getServletContext().setAttribute("wayfLocation", wayfLocation);
- getServletContext().setAttribute("supportContact", WayfConfig.getSupportContact());
- getServletContext().setAttribute("helpText", WayfConfig.getHelpText());
- getServletContext().setAttribute("searchResultEmptyText", WayfConfig.getSearchResultEmptyText());
- getServletContext().setAttribute("logoLocation", WayfConfig.getLogoLocation());
+ getServletContext().setAttribute("originsets", originConfig.getOriginSets());
+ getServletContext().setAttribute("supportContact", config.getSupportContact());
+ getServletContext().setAttribute("helpText", config.getHelpText());
+ getServletContext().setAttribute("searchResultEmptyText", config.getSearchResultEmptyText());
+ getServletContext().setAttribute("logoLocation", config.getLogoLocation());
+ log.info("WAYF initialization completed.");
}
private void loadInitParams() {
wayfConfigFileLocation = getServletConfig().getInitParameter("WAYFConfigFileLocation");
if (wayfConfigFileLocation == null) {
- wayfConfigFileLocation = "/WEB-INF/conf/shibboleth.xml";
+ log.warn("No WAYFConfigFileLocation parameter found... using default location.");
+ wayfConfigFileLocation = "/WEB-INF/conf/wayfconfig.xml";
+ }
+ siteConfigFileLocation = getServletConfig().getInitParameter("SiteConfigFileLocation");
+ if (siteConfigFileLocation == null) {
+ log.warn("No SiteonfigFileLocation parameter found... using default location.");
+ siteConfigFileLocation = "/WEB-INF/conf/sites.xml";
}
}
*/
public void doGet(HttpServletRequest req, HttpServletResponse res) {
+ log.info("Handling WAYF request.");
//Tell the browser not to cache the WAYF page
res.setHeader("Cache-Control", "no-cache");
res.setHeader("Pragma", "no-cache");
res.setDateHeader("Expires", 0);
-
+
//Decide how to route the request based on query string
String requestType = req.getParameter("action");
if (requestType == null) {
}
try {
if (requestType.equals("deleteFromCache")) {
- WayfCacheFactory.getInstance().deleteHsFromCache(req, res);
+ log.debug("Deleting saved HS from cache");
+ WayfCacheFactory.getInstance(config.getCacheType()).deleteHsFromCache(req, res);
handleLookup(req, res);
- } else if (WayfCacheFactory.getInstance().hasCachedHS(req)) {
- handleRedirect(req, res, WayfCacheFactory.getInstance().getCachedHS(req));
+ } else if (WayfCacheFactory.getInstance(config.getCacheType()).hasCachedHS(req)) {
+ handleRedirect(req, res, WayfCacheFactory.getInstance(config.getCacheType()).getCachedHS(req));
} else if (requestType.equals("search")) {
handleSearch(req, res);
} else if (requestType.equals("selection")) {
req.setAttribute("target", getTarget(req));
req.setAttribute("encodedShire", URLEncoder.encode(getSHIRE(req)));
req.setAttribute("encodedTarget", URLEncoder.encode(getTarget(req)));
-
+
+ log.debug("Displaying WAYF selection page.");
RequestDispatcher rd = req.getRequestDispatcher("/wayf.jsp");
try {
rd.forward(req, res);
private void handleSearch(HttpServletRequest req, HttpServletResponse res) throws WayfException {
if (req.getParameter("string") != null) {
- Origin[] origins = WayfConfig.getWAYFData().seachForMatchingOrigins(req.getParameter("string"));
+ Origin[] origins = originConfig.seachForMatchingOrigins(req.getParameter("string"), config);
if (origins.length != 0) {
req.setAttribute("searchresults", origins);
} else {
private void handleSelection(HttpServletRequest req, HttpServletResponse res) throws WayfException {
- String handleService = WayfConfig.getWAYFData().lookupHSbyName(req.getParameter("origin"));
+ String handleService = originConfig.lookupHSbyName(req.getParameter("origin"));
if (handleService == null) {
handleLookup(req, res);
} else {
- WayfCacheFactory.getInstance().addHsToCache(handleService, req, res);
+ WayfCacheFactory.getInstance(config.getCacheType()).addHsToCache(handleService, req, res);
handleRedirect(req, res, handleService);
}
private void handleRedirect(HttpServletRequest req, HttpServletResponse res, String handleService)
throws WayfException {
-
+
String shire = getSHIRE(req);
String target = getTarget(req);
-
+ log.info("Redirecting to selected Handle Service");
try {
res.sendRedirect(
handleService
private void handleError(HttpServletRequest req, HttpServletResponse res, WayfException we) {
log.error("WAYF Failure: " + we.toString());
+ log.debug("Displaying WAYF error page.");
req.setAttribute("errorText", we.toString());
+ req.setAttribute("requestURL", req.getRequestURI().toString());
RequestDispatcher rd = req.getRequestDispatcher("/wayferror.jsp");
try {
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Schema for the Shibboleth WAYF Service configuration file - Walter Hoehn - 06/14/2002 -->
+<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="unqualified">
+ <xs:element name="WayfConfig" >
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="HelpText" type="xs:string" minOccurs="0" maxOccurs="1"/>
+ <xs:element name="SearchResultEmptyText" type="xs:string" minOccurs="0" maxOccurs="1"/>
+ <xs:element name="SearchIgnore" minOccurs="0" maxOccurs="1">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="IgnoreText" type="xs:string" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+ </xs:sequence>
+ <xs:attribute name="supportContact" type="xs:string" use="optional"/>
+ <xs:attribute name="logoLocation" type="xs:string" use="optional"/>
+ <xs:attribute name="cacheType" type="xs:string" use="optional"/>
+ </xs:complexType>
+ </xs:element>
+</xs:schema>
+++ /dev/null
-<?xml version="1.0"?>
-<ShibbolethConfig>
-
- <CommonConfig>
- <OriginSet name="Higher Education">
- <Origin name="Carnegie Mellon" handleService="https://nada.andrew.cmu.edu/shibb/servlet/HandleServlet">
- <Alias name="cmu" />
- <Alias name="Tartans" />
- </Origin>
- <Origin name="The Ohio State University" handleService="https://usfs2.us.ohio-state.edu/webdev/Shibboleth/secure/servlet/HandleServlet">
- <Alias name="osu" />
- <Alias name="Buckeyes" />
- </Origin>
- <Origin name="University of Washington" handleService="https://abajo.cac.washington.edu/shibb/servlet/HandleServlet">
- <Alias name="uwash" />
- <Alias name="Huskies" />
- </Origin>
- <Origin name="Brown University" handleService="http://dilbert2.cis.brown.edu:1080/shibb/servlet/HandleServlet">
- <Alias name="Bears" />
- </Origin>
- </OriginSet>
- <OriginSet name="Other">
- <Origin name="Walter's Test" handleService="http://wassa.org:8080/shibb/servlet/HandleServlet">
- <Alias name="wassa" />
- <Alias name="columbia" />
- </Origin>
- <Origin name="Internet2" handleService="https://shib2.internet2.edu/shibb/servlet/HandleServlet">
- <Alias name="I2" />
- </Origin>
- </OriginSet>
- </CommonConfig>
-
- <WayfConfig cache="COOKIES"
- supportContact="mailto:shib-test@internet2.org"
- logoLocation="images/internet2.gif">
- <SearchIgnore>
- <String>Institution</String>
- <String>University</String>
- <String>State </String>
- <String>School</String>
- </SearchIgnore>
- </WayfConfig>
-
-</ShibbolethConfig>
--- /dev/null
+<Sites xmlns:ds="http://www.w3.org/2000/09/xmldsig#" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://shibboleth.internet2.edu/wayf/alpha-2/wayfconfig.xsd">
+<SiteGroup Name="Test">
+ <OriginSite Name="demo.edu">
+ <Alias>Demo State University</Alias>
+ <HandleService Name="shib2.internet2.edu" Location="https://shib2.internet2.edu/shibboleth-origin/servlet/HS"/>
+ </OriginSite>
+</SiteGroup>
+ <OriginSite Name="cmu.edu">
+ <Alias>Carnegie Mellon University</Alias>
+ <Alias>cmu</Alias>
+ <Alias>Tartans</Alias>
+ <HandleService Name="nada.andrew.cmu.edu" Location="https://nada.andrew.cmu.edu/shibb/servlet/HandleServlet"/>
+ </OriginSite>
+ <OriginSite Name="osu.edu">
+ <Alias>Ohio State University</Alias>
+ <Alias>osu</Alias>
+ <Alias>Buckeyes</Alias>
+ <HandleService Name="usfs2.us.ohio-state.edu" Location="https://usfs2.us.ohio-state.edu/webdev/Shibboleth/secure/servlet/HandleServlet"/>
+ </OriginSite>
+ <OriginSite Name="brown.edu">
+ <Alias>Brown University</Alias>
+ <Alias>Bears</Alias>
+ <HandleService Name="dilbert2.cis.brown.edu" Location="http://dilbert2.cis.brown.edu:1080/shibb/servlet/HandleServlet"/>
+ </OriginSite>
+</Sites>
--- /dev/null
+<?xml version="1.0"?>
+<WayfConfig xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://shibboleth.internet2.edu/wayf/alpha-2/wayfconfig.xsd"
+ cacheType="COOKIES"
+ supportContact="mailto:shib-test@internet2.org"
+ logoLocation="images/internet2.gif">
+ <HelpText>This is the help text.</HelpText>
+ <SearchResultEmptyText>This is the search result empty text.</SearchResultEmptyText>
+ <SearchIgnore>
+ <IgnoreText>Institution</IgnoreText>
+ <IgnoreText>University</IgnoreText>
+ <IgnoreText>State </IgnoreText>
+ <IgnoreText>School</IgnoreText>
+ </SearchIgnore>
+</WayfConfig>
<%@ taglib uri="/WEB-INF/tlds/struts-logic.tld" prefix="logic" %>
<%@ taglib uri="/WEB-INF/tlds/struts-bean.tld" prefix="bean" %>
<jsp:useBean id="originsets" scope="application" class="edu.internet2.middleware.shibboleth.wayf.OriginSet[]"/>
- <jsp:useBean id="wayfLocation" scope="application" class="java.lang.String"/>
+ <jsp:useBean id="requestURL" scope="request" class="java.lang.String"/>
<jsp:useBean id="helpText" scope="application" class="java.lang.String"/>
<jsp:useBean id="supportContact" scope="application" class="java.lang.String"/>
<jsp:useBean id="shire" scope="request" class="java.lang.String"/>
<ul>
<logic:iterate id="currResult" name="searchresults">
<li>
- <a href="<bean:write name="wayfLocation" />?action=selection&origin=<jsp:getProperty name="currResult" property="urlEncodedName" />&shire=<bean:write name="encodedShire" />&target=<bean:write name="encodedTarget" />"><jsp:getProperty name="currResult" property="name" /></a>
+ <a href="<bean:write name="requestURL" />?action=selection&origin=<jsp:getProperty name="currResult" property="urlEncodedName" />&shire=<bean:write name="encodedShire" />&target=<bean:write name="encodedTarget" />"><jsp:getProperty name="currResult" property="name" /></a>
</li>
</logic:iterate>
</ul>
</logic:present>
- <form method="get" action="<bean:write name="wayfLocation" />">
+ <form method="get" action="<bean:write name="requestURL" />">
<p>
<input type="hidden" name="shire" value="<bean:write name="shire" />" />
<input type="hidden" name="target" value="<bean:write name="target" />" />
<logic:iterate id="originset" name="originsets">
<h2><jsp:getProperty name="originset" property="name" /></h2>
-<form method="get" action="<bean:write name="wayfLocation" />">
+<form method="get" action="<bean:write name="requestURL" />">
<p>
<input type="hidden" name="shire" value="<bean:write name="shire" />" />
<input type="hidden" name="target" value="<bean:write name="target" />" />
<%@ taglib uri="/WEB-INF/tlds/struts-logic.tld" prefix="logic" %>
<%@ taglib uri="/WEB-INF/tlds/struts-bean.tld" prefix="bean" %>
- <jsp:useBean id="wayfLocation" scope="application" class="java.lang.String"/>
+ <jsp:useBean id="requestURL" scope="application" class="java.lang.String"/>
<jsp:useBean id="errorText" scope="request" class="java.lang.String"/>
<jsp:useBean id="supportContact" scope="application" class="java.lang.String"/>
<jsp:useBean id="logoLocation" scope="application" class="java.lang.String"/>
<p>Please email <a href="mailto:<bean:write name="supportContact" />"><bean:write name="supportContact" /></a> and include the following error message:</p>
-<p class="error">WAYF failure at (<bean:write name="wayfLocation" />)</p>
+<p class="error">WAYF failure at (<bean:write name="requestURL" />)</p>
<p><bean:write name="errorText" /></p>