|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.atlassian.jira.bc.whitelist.DefaultWhitelistService
public class DefaultWhitelistService
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface com.atlassian.jira.bc.whitelist.WhitelistService |
|---|
WhitelistService.WhitelistResult, WhitelistService.WhitelistUpdateValidationResult |
| Constructor Summary | |
|---|---|
DefaultWhitelistService(PermissionManager permissionManager,
WhitelistManager whitelistManager,
I18nHelper.BeanFactory beanFactory)
|
|
| Method Summary | |
|---|---|
WhitelistService.WhitelistResult |
getRules(JiraServiceContext context)
Returns a list of rules that are currently allowed in the whitelist. |
boolean |
isAllowed(URI uri)
Checks if requests to the provided URI are allowed according to the current whitelist configuration |
boolean |
isDisabled()
Returns true if the whitelist is currently disabled (meaning all requests are allowed). |
WhitelistService.WhitelistResult |
updateRules(WhitelistService.WhitelistUpdateValidationResult result)
Takes the validation result from WhitelistService.validateUpdateRules(com.atlassian.jira.bc.JiraServiceContext,
java.util.List, boolean) and persists the new rules. |
WhitelistService.WhitelistUpdateValidationResult |
validateUpdateRules(JiraServiceContext context,
List<String> rules,
boolean disabled)
Validates that the current user is allowed to update the whitelist by checking if they are a system administrator. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DefaultWhitelistService(PermissionManager permissionManager,
WhitelistManager whitelistManager,
I18nHelper.BeanFactory beanFactory)
| Method Detail |
|---|
public WhitelistService.WhitelistResult getRules(JiraServiceContext context)
WhitelistService
getRules in interface WhitelistServicecontext - The service context with the current user & error collection
public WhitelistService.WhitelistUpdateValidationResult validateUpdateRules(JiraServiceContext context,
List<String> rules,
boolean disabled)
WhitelistService
validateUpdateRules in interface WhitelistServicecontext - The service context with the current user & error collectionrules - List of rule stringsdisabled - true if the whitelist should be turned off
public WhitelistService.WhitelistResult updateRules(WhitelistService.WhitelistUpdateValidationResult result)
WhitelistServiceWhitelistService.validateUpdateRules(com.atlassian.jira.bc.JiraServiceContext,
java.util.List, boolean) and persists the new rules.
updateRules in interface WhitelistServiceresult - a validation result obtained by calling WhitelistService.validateUpdateRules(com.atlassian.jira.bc.JiraServiceContext,
java.util.List, boolean)
public boolean isDisabled()
WhitelistService
isDisabled in interface WhitelistServicepublic boolean isAllowed(URI uri)
WhitelistService
isAllowed in interface WhitelistServiceuri - The uri a http request is made to
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||