/** * @see org.opencms.main.CmsException#createException(org.opencms.i18n.CmsMessageContainer, java.lang.Throwable) */ @Override public CmsException createException(CmsMessageContainer container, Throwable cause) { return new CmsPermissionViolationException(container, cause); } }
/** * @see org.opencms.main.CmsException#createException(org.opencms.i18n.CmsMessageContainer, java.lang.Throwable) */ @Override public CmsException createException(CmsMessageContainer container, Throwable cause) { return new CmsPermissionViolationException(container, cause); } }
/** * @see org.opencms.file.wrapper.A_CmsResourceWrapper#createResource(org.opencms.file.CmsObject, java.lang.String, int, byte[], java.util.List) */ @Override public CmsResource createResource( CmsObject cms, String resourcepath, int type, byte[] content, List<CmsProperty> properties) throws CmsIllegalArgumentException { String name = CmsResource.getName(resourcepath); if (m_disabledNames.contains(name.toLowerCase())) { throw new CmsSilentWrapperException( new CmsPermissionViolationException( Messages.get().container(Messages.ERR_PERM_DENIED_2, resourcepath, "+c"))); } else { return null; } }
/** * @see org.opencms.file.wrapper.A_CmsResourceWrapper#moveResource(org.opencms.file.CmsObject, java.lang.String, java.lang.String) */ @Override public boolean moveResource(CmsObject cms, String source, String destination) throws CmsException, CmsIllegalArgumentException { String name = CmsResource.getName(destination); if (m_disabledNames.contains(name)) { throw new CmsPermissionViolationException( Messages.get().container(Messages.ERR_PERM_DENIED_2, destination, "+c")); } else { return false; } }
/** * Perform a security check against OpenCms. * * @param cms The OpenCms object. * * @throws CmsPermissionViolationException in case of the anonymous guest user */ private void performPermissionCheck(CmsObject cms) throws CmsPermissionViolationException { if (cms.getRequestContext().getCurrentUser().isGuestUser()) { throw new CmsPermissionViolationException(null); } }
throw new CmsPermissionViolationException( Messages.get().container( Messages.ERR_PERM_DENIED_2,
throw new CmsPermissionViolationException(Messages.get().container( Messages.ERR_PERM_DENIED_2, context.getSitePath(resource),
throw new CmsPermissionViolationException( org.opencms.db.Messages.get().container(org.opencms.db.Messages.ERR_PERM_DENIED_2, resourceName, "w"));
throw new CmsPermissionViolationException(org.opencms.db.Messages.get().container( org.opencms.db.Messages.ERR_PERM_DENIED_2, resourceName,