ok let me try

On Tue, Sep 13, 2011 at 4:45 PM, Martin <[email protected]> wrote:

>  On 13/09/2011 14:25, SEBUDANDI ROBERT wrote:
>
> can you send me a web.xml file with the filters
> thanks
>
> On Tue, Sep 13, 2011 at 4:00 PM, Martin <[email protected]> wrote:
>
>>   On 13/09/2011 13:37, SEBUDANDI ROBERT wrote:
>>
>>  Thanks for your response
>>  may be let me give you the files a want to protect and the web.xml and
>> you try to make for me the necessary changes thanks
>>  index.jsp
>>
>> <%@ page language="java" contentType="text/html; charset=UTF-8"
>>     pageEncoding="UTF-8"%>
>>   <%@taglib uri="http://java.sun.com/jsp/jstl/core"; prefix="c"%>
>> <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "
>> http://www.w3.org/TR/html4/loose.dtd";>
>> <HTML>
>> <HEAD>
>>
>> <TITLE>Student Schedule</TITLE>
>> </HEAD>
>>
>> <BODY>
>>
>> <FORM action="ScheduleServlet2" method="post">
>>
>> Course Name: <INPUT type="text" name="title" size="35"><BR>
>> Course Time:
>> Sun<INPUT type="checkbox" name="day" value="sun">
>> Mon<INPUT type="checkbox" name="day" value="mon">
>> Tue<INPUT type="checkbox" name="day" value="tue">
>> Wed<INPUT type="checkbox" name="day" value="wed">
>> Thu<INPUT type="checkbox" name="day" value="thu">
>> Fri<INPUT type="checkbox" name="day" value="fri">
>> Sat<INPUT type="checkbox" name="day" value="sat">
>> <SELECT name="starttime">
>> <OPTION value="8">8:00am</OPTION>
>> <OPTION value="9">9:00am</OPTION>
>> <OPTION value="10">10:00am</OPTION>
>> <OPTION value="11">11:00am</OPTION>
>> <OPTION value="12">12:00pm</OPTION>
>> <OPTION value="13">1:00pm</OPTION>
>> <OPTION value="14">2:00pm</OPTION>
>> <OPTION value="15">3:00pm</OPTION>
>> <OPTION value="16">4:00pm</OPTION>
>> <OPTION value="17">5:00pm</OPTION>
>> <OPTION value="18">6:00pm</OPTION>
>> <OPTION value="19">7:00pm</OPTION>
>> <OPTION value="20">8:00pm</OPTION>
>> <OPTION value="21">9:00pm</OPTION>
>> </SELECT>
>> to
>> <SELECT name="endtime">
>> <OPTION value="9">9:00am</OPTION>
>> <OPTION value="10">10:00am</OPTION>
>> <OPTION value="11">11:00am</OPTION>
>> <OPTION value="12">12:00pm</OPTION>
>> <OPTION value="13">1:00pm</OPTION>
>> <OPTION value="14">2:00pm</OPTION>
>> <OPTION value="15">3:00pm</OPTION>
>> <OPTION value="16">4:00pm</OPTION>
>> <OPTION value="17">5:00pm</OPTION>
>> <OPTION value="18">6:00pm</OPTION>
>> <OPTION value="19">7:00pm</OPTION>
>> <OPTION value="20">8:00pm</OPTION>
>> <OPTION value="21">9:00pm</OPTION>
>> <OPTION value="22">10:00pm</OPTION>
>> </SELECT>
>> <BR>
>> <BR>
>> <INPUT type="submit" name="Submit" value="Add Course">
>> </FORM>
>> <TABLE border="1" cellspacing="0">
>> <TBODY>
>> <TR>
>> <TH align="center" valign="middle" width="80"></TH>
>> <TH align="center" valign="middle" width="100">Sunday</TH>
>> <TH align="center" valign="middle">Monday</TH>
>> <TH align="center" valign="middle">Tuesday</TH>
>> <TH align="center" valign="middle">Wednesday</TH>
>> <TH align="center" valign="middle">Thursday</TH>
>> <TH align="center" valign="middle">Friday</TH>
>> <TH align="center" valign="middle">Saturday</TH>
>> </TR>
>> <c:forEach begin="8" end="21" step="1" var="time">
>> <TR>
>> <TD align="center" valign="middle" width="80">
>> <c:choose>
>> <c:when test="${time == 12}">
>> <c:out value="${time}" />:00pm
>> </c:when>
>> <c:when test="${time > 12}">
>> <c:out value="${time - 12}" />:00pm
>> </c:when>
>> <c:otherwise>
>> <c:out value="${time}" />:00am
>> </c:otherwise>
>> </c:choose></TD>
>> <c:forEach begin="0" end="6" step="1" var="day">
>> <TD align="center" valign="middle" width="100">
>> <c:forEach items="${schoolschedule.classes}" var="clazz">
>> <c:if test="${clazz.startTime <= time
>> && clazz.endTime > time
>> && clazz.day == day}">
>> <c:out value="${clazz.title}" />
>> </c:if>
>> </c:forEach>
>> </TD>
>> </c:forEach>
>> </TR>
>> </c:forEach>
>> </TBODY>
>> </TABLE>
>> </BODY>
>> </HTML>
>>
>> web. xml
>> what should i chang here i tried what you recommended it didnt work
>> <?xml version="1.0" encoding="UTF-8"?>
>> <web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; xmlns="
>> http://java.sun.com/xml/ns/javaee"; xmlns:web="
>> http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"; xsi:schemaLocation="
>> http://java.sun.com/xml/ns/javaee
>> http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"; id="WebApp_ID"
>> version="2.5">
>>   <display-name>SchoolSchedule</display-name>
>>   <welcome-file-list>
>>     <welcome-file>index.html</welcome-file>
>>     <welcome-file>index.htm</welcome-file>
>>     <welcome-file>index.jsp</welcome-file>
>>     <welcome-file>default.html</welcome-file>
>>     <welcome-file>default.htm</welcome-file>
>>     <welcome-file>default.jsp</welcome-file>
>>   </welcome-file-list>
>>
>>
>>   <servlet>
>>     <description></description>
>>     <display-name>ScheduleServlet2</display-name>
>>     <servlet-name>ScheduleServlet2</servlet-name>
>>
>> <servlet-class>rg.eclipse.wtp.sample.classschedule.ScheduleServlet2</servlet-class>
>>   </servlet>
>>   <servlet-mapping>
>>     <servlet-name>ScheduleServlet2</servlet-name>
>>     <url-pattern>/ScheduleServlet2</url-pattern>
>>   </servlet-mapping>
>> </web-app>
>> can you please send me like an example that is working am using CAS 3.3.1
>> thanks
>>
>>
>> On Tue, Sep 13, 2011 at 11:08 AM, Martin <[email protected]> wrote:
>>
>>>  On 13/09/2011 09:47, sebudandi wrote:
>>>
>>>> hey i CASified a servlet by putting the code below in the web.xml when i
>>>> run it it shows the cas login screen but when i enter password and username
>>>> it doesnt redirect me to the servlet it says
>>>> The connection to localhost:8080 was interrupted while the page was
>>>> loading.
>>>>  can someone tell me why .please
>>>>
>>>> web.xml
>>>>
>>>> <?xml version="1.0" encoding="ISO-8859-1"?>
>>>>
>>>> <!DOCTYPE web-app
>>>>     PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
>>>>     "http://java.sun.com/dtd/web-app_2_3.dtd";>
>>>>
>>>> <web-app>
>>>> <display-name>process</display-name>
>>>>   <welcome-file-list>
>>>>     <welcome-file>process</welcome-file>
>>>>
>>>>   </welcome-file-list>
>>>> <servlet>
>>>>  <description></description>
>>>>     <display-name>process</display-name>
>>>>
>>>>           <servlet-name>process</servlet-name>
>>>>           <servlet-class>process</servlet-class>
>>>>
>>>>       </servlet>
>>>>
>>>>
>>>>     <servlet-mapping>
>>>>                 <servlet-name>process</servlet-name>
>>>>                 <url-pattern>/process</url-pattern>
>>>>     </servlet-mapping>
>>>>
>>>>      <filter>
>>>>     <filter-name>CAS Filter</filter-name>
>>>>     <filter-class>edu.yale.its.tp
>>>> .cas.client.filter.CASFilter</filter-class>
>>>>     <init-param>
>>>>       <param-name>edu.yale.its.tp
>>>> .cas.client.filter.loginUrl</param-name>
>>>>       <param-value>http://localhost:8080/cas/login</param-value>
>>>>     </init-param>
>>>>     <init-param>
>>>>       <param-name>edu.yale.its.tp
>>>> .cas.client.filter.validateUrl</param-name>
>>>>       <param-value>https://localhost:8080/cas/serviceValidate
>>>> </param-value>
>>>>     </init-param>
>>>>     <init-param>
>>>>       <param-name>edu.yale.its.tp
>>>> .cas.client.filter.serviceUrl</param-name>
>>>>       <param-value>https://localhost:8080/menu.jsp</param-value>
>>>>     </init-param>
>>>>
>>>>   </filter>
>>>>
>>>>   <filter-mapping>
>>>>     <filter-name>CAS Filter</filter-name>
>>>>     <url-pattern>/*</url-pattern>
>>>>   </filter-mapping>
>>>>
>>>> </web-app>
>>>> - Show quoted text -
>>>>
>>>  It looks as if your using the yale.* package to access CAS, which if
>>> its a new installation, I'm guessing you might be uing the CAS3 then you
>>> need to start using the new package system.  I know I had the same problem.
>>>  try looking at
>>> https://wiki.jasig.org/display/CASC/Configuring+the+JA-SIG+CAS+Client+for+Java+in+the+web.xmlthis
>>>  might help you
>>>
>>>
>>> --
>>> You are currently subscribed to [email protected] as:
>>> [email protected]
>>> To unsubscribe, change settings or access archives, see
>>> http://www.ja-sig.org/wiki/display/JSG/cas-user
>>>
>>
>>  --
>> You are currently subscribed to [email protected] as: 
>> [email protected]
>>
>> To unsubscribe, change settings or access archives, see 
>> http://www.ja-sig.org/wiki/display/JSG/cas-user
>>
>>  You should be able to just add the filters to the web.xml and have it
>> work, although i did notice in the web.xml, the line:
>>
>> <servlet-class>rg.eclipse.wtp.sample.classschedule.ScheduleServlet2</servlet-class>
>>
>>  I'm thinking it should maybe be :
>>
>>
>> <servlet-class>org.eclipse.wtp.sample.classschedule.ScheduleServlet2</servlet-class>
>>
>> Hope that helps, other than that I'm not sure what else to suggest, maybe
>> if you can post the error log I could be of more help
>>
>> --
>> You are currently subscribed to [email protected] as: 
>> [email protected]
>> To unsubscribe, change settings or access archives, see 
>> http://www.ja-sig.org/wiki/display/JSG/cas-user
>>
>>
> --
> You are currently subscribed to [email protected] as: 
> [email protected]
> To unsubscribe, change settings or access archives, see 
> http://www.ja-sig.org/wiki/display/JSG/cas-user
>
>  You really should just add the filters from the tutorial and it should
> work, if  you get stuck on that then post the error log, Sorry but i really
> don't have time right now to generate a custome web.xml file for you
>
> --
> You are currently subscribed to [email protected] as: 
> [email protected]
> To unsubscribe, change settings or access archives, see 
> http://www.ja-sig.org/wiki/display/JSG/cas-user
>
>

-- 
You are currently subscribed to [email protected] as: 
[email protected]
To unsubscribe, change settings or access archives, see 
http://www.ja-sig.org/wiki/display/JSG/cas-user

Reply via email to