Examples of WGACLEntry


Examples of de.innovationgate.webgate.api.WGACLEntry

                // The ACL
                WGFactory.getLogger().info("Importing original ACL");
                Iterator aclEntries = _importSource.getACL().getAllEntries().iterator();
                while (aclEntries.hasNext()) {
                    WGACLEntry entry = (WGACLEntry) aclEntries.next();
                    WGFactory.getLogger().info("Cloning aclentry '" + entry.getName() + "'");
                    try {
                        WGACLEntry clone = db.getACL().createEntry(entry.getName(), entry.getType(), entry.getLevel());
                        clone.setFlags(entry.getFlags());
                        db.getACL().save(clone);
                    }
                    catch (WGAPIException e) {
                        WGFactory.getLogger().info("Exception cloning aclentry", e);
                    }
View Full Code Here

Examples of de.innovationgate.webgate.api.WGACLEntry

            if (domain == null || domain.getDefaultManager() == null) {
                return;
            }
           
            // Retrieve ACL entry for default manager
            WGACLEntry aclEntry = acl.getEntry(domain.getDefaultManager());
            if (aclEntry == null) {
                acl.createUserEntry(domain.getDefaultManager(), WGDatabase.ACCESSLEVEL_MANAGER);
            }
           
            // Modify flags to include role and store
            WGACLEntryFlags flags = acl.parseFlags(aclEntry);
            if (!flags.getRoles().contains(role.getName())) {
                flags.getRoles().add(role.getName());
            }
            aclEntry.setFlags(flags.toString());
            acl.save(aclEntry);
           
        }
        catch (WGAPIException e) {
           _log.error("Error assigning role '" + role.getName() + "' to default manager for database '" + db.getDbReference() + "'", e);
View Full Code Here

Examples of de.innovationgate.webgate.api.WGACLEntry

        _log.info("Deleting old acl entries...");
       
        Iterator aclEntries = _to.getACL().getAllEntries().iterator();

        while (aclEntries.hasNext()) {
            WGACLEntry entry = (WGACLEntry) aclEntries.next();
           
            _log.info("Deleting old aclentry '" + entry.getName() + "'");
            try {
                _to.getACL().remove(entry);               
            }
            catch (WGAPIException e) {
                _log.error("Cannot delete aclentry. See application log for error details");
                throw new WGBackendException("Canceled because of failed deletion: '" + entry.getName() + "' (ACL-Entry)");
            }

        }
        _log.info("Finished deleting old acl entries");
   }
View Full Code Here

Examples of de.innovationgate.webgate.api.WGACLEntry

        _log.info("Cloning acl...");
       
        Iterator aclEntries = _from.getACL().getAllEntries().iterator();

        while (aclEntries.hasNext()) {
            WGACLEntry entry = (WGACLEntry) aclEntries.next();
           
            _log.info("Cloning aclentry '" + entry.getName() + "'");
            try {
                WGACLEntry clone = _to.getACL().createEntry(entry.getName(), entry.getType(), entry.getLevel());
                clone.setFlags(entry.getFlags());
                _to.getACL().save(clone);
            }
            catch (WGAPIException e) {
                handleException("Error cloning aclentry", e, null);
            }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.