Package hudson.security
Class PermissionAdder
- java.lang.Object
-
- hudson.security.PermissionAdder
-
- All Implemented Interfaces:
ExtensionPoint
public abstract class PermissionAdder extends Object implements ExtensionPoint
Service which can add permissions for a given user to the configured authorization strategy. Useful e.g. to make the first user created in the system be automatically granted administer privilege.- Since:
- 1.535
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson
-
-
Constructor Summary
Constructors Constructor Description PermissionAdder()
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description abstract boolean
add(AuthorizationStrategy strategy, User user, Permission perm)
Called to try to give a user global permission.
-
-
-
Method Detail
-
add
public abstract boolean add(AuthorizationStrategy strategy, User user, Permission perm)
Called to try to give a user global permission.- Parameters:
strategy
- the configured authorization strategyuser
- a userperm
- a permission to grant, such asJenkins.ADMINISTER
- Returns:
- true if the permission was added, false if this service is incapable of handling it
-
-