X-Git-Url: https://git.argeo.org/?a=blobdiff_plain;f=org.argeo.cms%2Fsrc%2Forg%2Fargeo%2Fsecurity%2Fcore%2FAbstractSystemExecution.java;h=9c3e5cd8390f43f875e588f6f7890f1c5e039813;hb=c873a0359345503b8e3ca07828bd99d525ec7cc0;hp=c4beeed52444dcc5f40612d5ad7b1714c234da49;hpb=d4630044f17e0423772be6b1a0b93c01f518f31c;p=lgpl%2Fargeo-commons.git diff --git a/org.argeo.cms/src/org/argeo/security/core/AbstractSystemExecution.java b/org.argeo.cms/src/org/argeo/security/core/AbstractSystemExecution.java index c4beeed52..9c3e5cd83 100644 --- a/org.argeo.cms/src/org/argeo/security/core/AbstractSystemExecution.java +++ b/org.argeo.cms/src/org/argeo/security/core/AbstractSystemExecution.java @@ -21,7 +21,7 @@ import javax.security.auth.login.LoginException; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; -import org.argeo.ArgeoException; +import org.argeo.cms.CmsException; /** Provides base method for executing code with system authorization. */ public abstract class AbstractSystemExecution { @@ -41,7 +41,7 @@ public abstract class AbstractSystemExecution { LoginContext lc = new LoginContext(loginModule, subject); lc.login(); } catch (LoginException e) { - throw new ArgeoException("Cannot login as system", e); + throw new CmsException("Cannot login as system", e); } finally { Thread.currentThread().setContextClassLoader(origClassLoader); } @@ -56,7 +56,7 @@ public abstract class AbstractSystemExecution { LoginContext lc = new LoginContext(loginModule, subject); lc.logout(); } catch (LoginException e) { - throw new ArgeoException("Cannot logout as system", e); + throw new CmsException("Cannot logout as system", e); } finally { Thread.currentThread().setContextClassLoader(origClassLoader); }