Package com.atlassian.bamboo.security
Class ImpersonationHelper
java.lang.Object
com.atlassian.bamboo.security.ImpersonationHelper
-
Method Summary
Modifier and TypeMethodDescriptioncallWith(@NotNull org.acegisecurity.Authentication authentication, BambooCallables.ThrowingX<T, E1, E2, E3> callable) callWithSystemAuthority(BambooCallables.ThrowingX<T, E1, E2, E3> callable) static voidstatic RunnablemakeRunnableWithSystemAuthority(Runnable runnable) static voidnewAuthenticationForCurrentThread(org.acegisecurity.Authentication authentication) runAs(@NotNull BambooUser user, BambooRunnables.ThrowingX<E1, E2, E3> runnable) runWith(@NotNull org.acegisecurity.Authentication authentication, BambooRunnables.ThrowingX<E1, E2, E3> runnable) runWithSystemAuthority(BambooRunnables.ThrowingX<E1, E2, E3> runnable)
-
Method Details
-
runWithSystemAuthority
public static <E1 extends Throwable,E2 extends Throwable, void runWithSystemAuthorityE3 extends Throwable> (@NotNull BambooRunnables.ThrowingX<E1, E2, throws E2, E1, E3E3> runnable) - Throws:
E2E1E3
-
runWith
public static <E1 extends Throwable,E2 extends Throwable, void runWithE3 extends Throwable> (@NotNull @NotNull org.acegisecurity.Authentication authentication, @NotNull BambooRunnables.ThrowingX<E1, E2, throws E2, E1, E3E3> runnable) - Throws:
E2E1E3
-
callWithSystemAuthority
public static <T,E1 extends Throwable, T callWithSystemAuthorityE2 extends Throwable, E3 extends Throwable> (@NotNull BambooCallables.ThrowingX<T, E1, throws E2, E1, E3E2, E3> callable) - Throws:
E2E1E3
-
callWith
public static <T,E1 extends Throwable, T callWithE2 extends Throwable, E3 extends Throwable> (@NotNull @NotNull org.acegisecurity.Authentication authentication, @NotNull BambooCallables.ThrowingX<T, E1, throws E2, E1, E3E2, E3> callable) - Throws:
E2E1E3
-
newAuthenticationForCurrentThread
public static void newAuthenticationForCurrentThread(org.acegisecurity.Authentication authentication) -
makeRunnableWithSystemAuthority
-
escalateCurrentThreadToSystemAuthority
public static void escalateCurrentThreadToSystemAuthority() -
runAs
public static <E1 extends Throwable,E2 extends Throwable, void runAsE3 extends Throwable> (@NotNull @NotNull BambooUser user, @NotNull BambooRunnables.ThrowingX<E1, E2, throws E2, E1, E3E3> runnable) - Throws:
E2E1E3
-