01: /*
02: * Copyright 2007 The Kuali Foundation.
03: *
04: * Licensed under the Educational Community License, Version 1.0 (the "License");
05: * you may not use this file except in compliance with the License.
06: * You may obtain a copy of the License at
07: *
08: * http://www.opensource.org/licenses/ecl1.php
09: *
10: * Unless required by applicable law or agreed to in writing, software
11: * distributed under the License is distributed on an "AS IS" BASIS,
12: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13: * See the License for the specific language governing permissions and
14: * limitations under the License.
15: */
16: package org.kuali.kfs.service.impl;
17:
18: import javax.servlet.http.HttpServletRequest;
19:
20: import org.kuali.core.service.WebAuthenticationService;
21: import org.kuali.core.web.filter.KualiCasFilter;
22:
23: import edu.iu.uis.eden.web.session.UserSession;
24:
25: /**
26: * This class is used to perform the webAuthentication Service when using the Kuali Cas Filter.
27: */
28: public class WebAuthenticationServiceCas implements
29: WebAuthenticationService {
30: private boolean validatePassword = true;
31:
32: /**
33: * @see org.kuali.core.service.WebAuthenticationService#getNetworkId(javax.servlet.http.HttpServletRequest)
34: */
35: public String getNetworkId(HttpServletRequest request) {
36: return KualiCasFilter.getRemoteUser(request);
37: }
38:
39: /**
40: * @see edu.iu.uis.eden.web.WebAuthenticationService#updateUserSession(edu.iu.uis.eden.web.session.UserSession,
41: * javax.servlet.http.HttpServletRequest)
42: */
43: public UserSession updateUserSession(UserSession userSession,
44: HttpServletRequest request) {
45: return userSession;
46: }
47:
48: /**
49: * @see org.kuali.core.service.WebAuthenticationService#isValidatePassword()
50: */
51: public boolean isValidatePassword() {
52: return validatePassword;
53: }
54:
55: public void setValidatePassword(boolean validatePassword) {
56: this.validatePassword = validatePassword;
57: }
58: }
|