|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectuk.ac.soton.itinnovation.grid.pbac2.pdp.webadmin.ACLadmin
public class ACLadmin
Provides code to create a web administration interface for PBAC access control lists. To use it, create a new ACLadmin object in your JSP page and then call processPOST(). Call showRules() to display a table showing the current rules, and allowing the user to add and remove rules.
| Field Summary | |
|---|---|
static int |
TYPE_ANYONE
|
static int |
TYPE_CA
|
static int |
TYPE_MEMBER
|
static int |
TYPE_NONE
|
static int |
TYPE_SAML
|
static int |
TYPE_SUBJECT_DN
|
static int |
TYPE_TRUSTED_START
|
| Constructor Summary | |
|---|---|
ACLadmin(HttpServletRequest request)
Convenience constructor with other arguments set to null. |
|
ACLadmin(HttpServletRequest request,
HttpServletResponse response)
|
|
ACLadmin(HttpServletRequest request,
String resourceID)
Convenience constructor with other arguments set to null. |
|
ACLadmin(HttpServletRequest request,
String resourceID,
HttpServletResponse response)
|
|
ACLadmin(HttpServletRequest request,
String resourceID,
String fragment,
HttpServletResponse response)
Create a new ACLadmin from the parameters in this request. |
|
| Method Summary | |
|---|---|
void |
addTrustedAttributeType(String name,
String menuText,
String formText)
Add a trusted attribute that the user can add to this ACL. |
static String |
escapeHTML(Object object)
|
String |
formatAuthorityHTML(MatchRule rule)
Format the authority field of a MatchRule. |
String |
formatRuleTypeHTML(MatchRule rule)
Format the deny field of a MatchRule. |
String |
formatSubjectHTML(MatchRule rule)
Format the subject field of a MatchRule. |
String |
formatTrustedAttributeTypeHTML(int typeid)
Format the label for a TrustedAttributeType value box (e.g. |
Map<String,String> |
getDeleteParameters(MatchRule rule)
Get the details needed to identify a match rule to be deleted. |
static String |
getGroupAdminPrefix()
Deprecated. See getGroupAdminPrefix(HttpServletRequest) |
static String |
getGroupAdminPrefix(HttpServletRequest request)
Get the prefix for a relative link to the group ACL admin page. |
String |
getResourceType()
|
boolean |
hasAuthorityCertificate(MatchRule rule)
Check whether this match rule has a certificate. |
String |
processPOST()
Check whether this request is a POST asking us to update the ACLs. |
void |
showRules(Writer out)
Show the access control list for this resource. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int TYPE_NONE
public static final int TYPE_SUBJECT_DN
public static final int TYPE_CA
public static final int TYPE_SAML
public static final int TYPE_MEMBER
public static final int TYPE_ANYONE
public static final int TYPE_TRUSTED_START
| Constructor Detail |
|---|
public ACLadmin(HttpServletRequest request)
throws Stop,
InvalidResourceIDException
Stop
InvalidResourceIDException
public ACLadmin(HttpServletRequest request,
String resourceID)
throws Stop,
InvalidResourceIDException
Stop
InvalidResourceIDException
public ACLadmin(HttpServletRequest request,
String resourceID,
HttpServletResponse response)
throws Stop,
InvalidResourceIDException
Stop
InvalidResourceIDException
public ACLadmin(HttpServletRequest request,
HttpServletResponse response)
throws Stop,
InvalidResourceIDException
Stop
InvalidResourceIDException
public ACLadmin(HttpServletRequest request,
String resourceID,
String fragment,
HttpServletResponse response)
throws Stop,
InvalidResourceIDException
request - servlet's request objectresourceID - resource to use. If null, uses request.getParameter("resource")fragment - fragment identifier to add to links (e.g. "acl" to link to "page.jsp#acl")
Stop
InvalidResourceIDException| Method Detail |
|---|
public static String getGroupAdminPrefix()
getGroupAdminPrefix(HttpServletRequest)
public static String getGroupAdminPrefix(HttpServletRequest request)
request - HttpServletRequest
public String processPOST()
throws Stop,
GridFailureException,
org.apache.commons.fileupload.FileUploadException,
CertificateException,
IOException
Stop
GridFailureException
org.apache.commons.fileupload.FileUploadException
CertificateException
IOException
public void showRules(Writer out)
throws IOException,
GridFailureException
IOException
GridFailureExceptionpublic String formatRuleTypeHTML(MatchRule rule)
rule - the rule to be formatted for display
public String formatSubjectHTML(MatchRule rule)
rule - the rule to be formatted for display
public String formatAuthorityHTML(MatchRule rule)
rule - the rule to be formatted for display
public String formatTrustedAttributeTypeHTML(int typeid)
typeid - the id of the TrustedAttributeType to be formatted for display
public boolean hasAuthorityCertificate(MatchRule rule)
rule - the rule to be checked
public Map<String,String> getDeleteParameters(MatchRule rule)
rule - the rule to be deleted
public static String escapeHTML(Object object)
public String getResourceType()
public void addTrustedAttributeType(String name,
String menuText,
String formText)
name - the attribute namemenuText - the label for the menu (e.g. "User name is ...")formText - the label for the value box (e.g. "User name:")TrustedAttribute
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||