|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object issrg.policytester.testing.PolicyTester
public class PolicyTester
Field Summary | |
---|---|
java.util.Vector<java.lang.String> |
actionResultString
|
static java.lang.String |
ATTRIBUTE_CERTIFICATE_ATTRIBUTE_NAME
|
java.lang.String |
decisionString
|
protected static Logger |
logger
|
java.lang.String |
resultString
|
Constructor Summary | |
---|---|
PolicyTester(java.util.Vector<java.lang.String> state,
java.lang.String xmlPolicyFilePath,
java.util.Vector<PTLDAPAC> ACs)
Creates a new instance of PolicyTester |
Method Summary | |
---|---|
boolean |
checkValidPolicy(java.lang.String filePath)
|
void |
execute()
Asks for a decision based on the information available from the latest pass of parseVector . |
java.lang.String |
execute(java.security.Principal user,
Action action,
Target target,
java.util.Map env)
The execute method is used to make a pull decision based on the certificate attributes provided |
Action |
getAction()
Creates an object of type Action corresponding to the latest pass of parseVector . |
static byte[] |
getBytes(java.lang.Object obj)
|
java.lang.String |
getDecisionString()
|
java.util.Map<java.lang.String,java.lang.Object> |
getEnvironment()
Creates a Map representing the environment corresponding to the latest pass of parseVector . |
java.util.Vector<java.lang.String> |
getExeResult()
|
java.lang.String |
getOID()
|
boolean |
getParsingResult()
|
java.security.Principal |
getPrincipal()
Creates an object of type Principal corresponding to the latest pass of parseVector . |
java.lang.String |
getResultString()
|
Target |
getTarget()
Creates a PermisTarget object corresponding to the latest pass of parseVector . |
boolean |
getTestResult()
|
void |
loadATT(VirtualRepository vr,
java.lang.String filename)
The loadATT method is used to load Text Based attributes into the virtual repositry vr as |
void |
loadPKC(VirtualRepository vr,
java.lang.String filename)
The loadPKC method is used to load the PKC certificate that the filename string points to into the VirtualRepositry vr |
void |
loadPolicy(java.lang.String filename)
The loadPolicy method is used to load an XML policy if specified by the user it takes a virtual repositry vr and the filename of the policy to be loaded as its parameters it then creates a Simple permis Policy finder to be used by the system |
java.lang.String |
makeString(SetOfSubsetsCredentials set)
|
void |
parseVectorContents(java.util.Vector<java.lang.String> parseVector)
|
static java.lang.String |
removeSystemTag(java.lang.String xml)
This method does simplistic XML policy pre-processing to remove a <!DOCTYPE SYSTEM> tag from it. |
void |
resetExeResult(java.util.Vector<java.lang.String> v)
|
void |
setDecisionString(java.lang.String s)
|
void |
setExeResult(java.lang.String actionResult)
|
void |
setParsingResult(boolean result)
|
void |
setResultString(java.lang.String s)
|
void |
setTestResult(boolean result)
|
void |
stopAgent()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public java.util.Vector<java.lang.String> actionResultString
public java.lang.String resultString
public java.lang.String decisionString
public static final java.lang.String ATTRIBUTE_CERTIFICATE_ATTRIBUTE_NAME
protected static Logger logger
Constructor Detail |
---|
public PolicyTester(java.util.Vector<java.lang.String> state, java.lang.String xmlPolicyFilePath, java.util.Vector<PTLDAPAC> ACs)
Method Detail |
---|
public void stopAgent()
public Target getTarget() throws BadURLException, RFC2253ParsingException
PermisTarget
object corresponding to the latest pass of parseVector
.
BadURLException
RFC2253ParsingException
public Action getAction()
Action
corresponding to the latest pass of parseVector
.
public java.security.Principal getPrincipal() throws RFC2253ParsingException
Principal
corresponding to the latest pass of parseVector
.
RFC2253ParsingException
public java.util.Map<java.lang.String,java.lang.Object> getEnvironment()
parseVector
.
public java.lang.String getOID()
public boolean checkValidPolicy(java.lang.String filePath)
public void parseVectorContents(java.util.Vector<java.lang.String> parseVector)
public static byte[] getBytes(java.lang.Object obj)
public static java.lang.String removeSystemTag(java.lang.String xml)
xml
- - the XML to remove the SYSTEM tag from
public void loadPolicy(java.lang.String filename)
vr
- -filename
- public void loadATT(VirtualRepository vr, java.lang.String filename)
vr
- filename
- public void loadPKC(VirtualRepository vr, java.lang.String filename)
vr
- filename
- public java.lang.String execute(java.security.Principal user, Action action, Target target, java.util.Map env)
user
- action
- target
-
public void execute()
parseVector
.
XXX: isn't finished yet!
public java.lang.String makeString(SetOfSubsetsCredentials set)
set
-
public void setParsingResult(boolean result)
public boolean getParsingResult()
public void setExeResult(java.lang.String actionResult)
public java.util.Vector<java.lang.String> getExeResult()
public void resetExeResult(java.util.Vector<java.lang.String> v)
public void setResultString(java.lang.String s)
public java.lang.String getResultString()
public void setTestResult(boolean result)
public boolean getTestResult()
public void setDecisionString(java.lang.String s)
public java.lang.String getDecisionString()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |