public class GroupTypeSecurityHook extends GroupTypeTupleHooks
built in hook to grouper, which is turned on when it is configured in the grouper.properties. you can security certain group types which can only be added/removed to/from a group based on if the user doing the work is in a certain group (or wheel), or if the user is only a wheel group member. normally a user with admin rights on a group can edit the group type associations Log debug with log4j setting log4j.logger.edu.internet2.middleware.grouper.hooks.examples.GroupTypeSecurityHook = DEBUG
METHOD_GROUP_TYPE_TUPLE_POST_COMMIT_DELETE, METHOD_GROUP_TYPE_TUPLE_POST_COMMIT_INSERT, METHOD_GROUP_TYPE_TUPLE_POST_COMMIT_UPDATE, METHOD_GROUP_TYPE_TUPLE_POST_DELETE, METHOD_GROUP_TYPE_TUPLE_POST_INSERT, METHOD_GROUP_TYPE_TUPLE_POST_UPDATE, METHOD_GROUP_TYPE_TUPLE_PRE_DELETE, METHOD_GROUP_TYPE_TUPLE_PRE_INSERT, METHOD_GROUP_TYPE_TUPLE_PRE_UPDATE
Constructor and Description |
---|
GroupTypeSecurityHook() |
Modifier and Type | Method and Description |
---|---|
static void |
clearHook() |
static String |
groupNameFromAndGroupAttributeName(String attributeName) |
void |
groupTypeTuplePostDelete(HooksContext hooksContext,
HooksGroupTypeTupleBean postDeleteBean)
called right after a groupTypeTuple delete
|
void |
groupTypeTuplePostInsert(HooksContext hooksContext,
HooksGroupTypeTupleBean postInsertBean)
called right after a groupTypeTuple insert
|
static boolean |
isRegisteredSuccess()
If the hook was registered due to settings in the grouper.properties
|
static void |
registerHookIfNecessary(boolean tryAgainIfNotBefore)
see if this is configured in the grouper.properties, if so, register this hook
|
static boolean |
resetCacheSettings()
reset cached settings from config, return true if found some
|
static void |
vetoIfNecessary(String groupUuid,
String typeUuid,
String descriptionForLog)
veto a type or attribute edit if necessary
|
groupTypeTuplePostCommitDelete, groupTypeTuplePostCommitInsert, groupTypeTuplePostCommitUpdate, groupTypeTuplePostUpdate, groupTypeTuplePreDelete, groupTypeTuplePreInsert, groupTypeTuplePreUpdate
public static void clearHook()
public static void registerHookIfNecessary(boolean tryAgainIfNotBefore)
tryAgainIfNotBefore
- public static boolean resetCacheSettings()
public static void vetoIfNecessary(String groupUuid, String typeUuid, String descriptionForLog) throws HookVeto
groupUuid
- typeUuid
- descriptionForLog
- HookVeto
- if there is a problempublic static String groupNameFromAndGroupAttributeName(String attributeName)
attributeName
- public void groupTypeTuplePostDelete(HooksContext hooksContext, HooksGroupTypeTupleBean postDeleteBean)
GroupTypeTupleHooks
public void groupTypeTuplePostInsert(HooksContext hooksContext, HooksGroupTypeTupleBean postInsertBean)
GroupTypeTupleHooks
public static boolean isRegisteredSuccess()
Copyright © 2016 Internet2. All rights reserved.