planetj.dataengine.security.http
Class LocalUsersOnlyOrOperatingSystemProfile
java.lang.Object
|
+--planetj.dataengine.security.http.GenericSignOn
|
+--planetj.dataengine.security.http.DBCommonConnectionPoolSignOn
|
+--planetj.dataengine.security.http.LocalUsersOnlyOrOperatingSystemProfile
- All Implemented Interfaces:
- ISignOn, Serializable
- public class LocalUsersOnlyOrOperatingSystemProfile
- extends DBCommonConnectionPoolSignOn
This class checks that the incoming user has a local ip address. If they don't
have a local ip address, then they are prompted to enter their user id and password
for a given operating system.
A local ip address is considered to be any ip starting with:
10. or 127. or 192.
- Author:
- PlanetJ Corp.
- See Also:
- Serialized Form
Method Summary |
boolean |
isUserPromptRequired(ISecured secured,
javax.servlet.http.HttpServletRequest request)
Tests if the user should be prompted for user id, password, etc
when this class is used to sign on. |
boolean |
signOn(String user,
String password,
ISecured secured,
javax.servlet.http.HttpServletRequest request)
Check that the incoming user has a local ip address then treat the application as
unsecured. |
LocalUsersOnlyOrOperatingSystemProfile
public LocalUsersOnlyOrOperatingSystemProfile()
isUserPromptRequired
public boolean isUserPromptRequired(ISecured secured,
javax.servlet.http.HttpServletRequest request)
throws CMException
- Tests if the user should be prompted for user id, password, etc
when this class is used to sign on.
- Specified by:
isUserPromptRequired
in interface ISignOn
- Overrides:
isUserPromptRequired
in class GenericSignOn
- Parameters:
secured
- The secured object being signed into.request
- The HttpServletRequest from the user.
- Returns:
- true if user should be prompted for sign on.
CMException
signOn
public boolean signOn(String user,
String password,
ISecured secured,
javax.servlet.http.HttpServletRequest request)
throws CMException
- Check that the incoming user has a local ip address then treat the application as
unsecured. If the incoming user isn't local, prompt them for their operating system
user id.
- Specified by:
signOn
in interface ISignOn
- Overrides:
signOn
in class DBCommonConnectionPoolSignOn
- Parameters:
user
- user id entered if operating system sign onpassword
- password user entered if operating system sign onsecured
- the secured object to sign intorequest
- the HttpServletRequest sent from the user
- Returns:
- true if user signed on successfully; false otherwise.
CMException