1 55 56 package org.jboss.axis.security.servlet; 57 58 import org.jboss.axis.security.AuthenticatedUser; 59 60 import javax.servlet.http.HttpServletRequest ; 61 import java.security.Principal ; 62 63 71 public class ServletAuthenticatedUser implements AuthenticatedUser 72 { 73 private String name; 74 private HttpServletRequest req; 75 76 public ServletAuthenticatedUser(HttpServletRequest req) 77 { 78 this.req = req; 79 Principal principal = req.getUserPrincipal(); 80 this.name = (principal == null) ? null : principal.getName(); 81 } 82 83 88 public String getName() 89 { 90 return name; 91 } 92 93 public HttpServletRequest getRequest() 94 { 95 return req; 96 } 97 } 98 | Popular Tags |