Removes <code>IPermissions</code> for the <code>IAuthorizationPrincipals</code> from the
cache.

@param principals IAuthorizationPrincipal[]
770345
private void removeFromPermissionsCache(IAuthorizationPrincipal[] principals)
            throws AuthorizationException {
        for (int i = 0; i < principals.length; i++) {
            cacheRemove(principals[i]);
        }
    }
312800
public void setInboundPermissions(java.util.Collection<IpPermission> inboundPermissions) {
        if (inboundPermissions == null) {
            this.inboundPermissions = null;
            return;
        }

        this.inboundPermissions = new java.util.ArrayList<IpPermission>(inboundPermissions);
    }
276154
@Override
    public IPermission newPermission(String owner, IAuthorizationPrincipal principal) {
        IPermission p = getPermissionStore().newInstance(owner);
        if (principal != null) {
            String pString = getPrincipalString(principal);
            p.setPrincipal(pString);
        }
        return p;
    }
346140
public void setFlagsForPrincipal(I_CmsPrincipal principal) {

        setFlags(
            principal.isGroup() ? CmsAccessControlEntry.ACCESS_FLAGS_GROUP : CmsAccessControlEntry.ACCESS_FLAGS_USER);
    }
188564
public void clearSingleSignOn(String username)
    {
        synchronized(_ssoId2Principal)
        {
            Object ssoID=_ssoUsername2Id.remove(username);
            Object principal=_ssoId2Principal.remove(ssoID);
            _ssoPrincipal2Credential.remove(principal);
        }        
    }
547081
public function deletePermissions(array $ids): void
	{
		if ($this->isAjax()) {
			$permissions = $this->orm->acl->findById($ids);
			foreach ($permissions as $permission) {
				$this->orm->acl->remove($permission);
			}
			$this->orm->flush();
			$this['permissionsList']->reload();
		} else {
			$this->terminate();
		}
	}
335838
public void setIpPermissionsEgress(java.util.Collection<IpPermission> ipPermissionsEgress) {
        if (ipPermissionsEgress == null) {
            this.ipPermissionsEgress = null;
            return;
        }

        this.ipPermissionsEgress = new com.amazonaws.internal.SdkInternalList<IpPermission>(ipPermissionsEgress);
    }
991260
protected IPermissionSet cacheGet(IAuthorizationPrincipal principal)
            throws AuthorizationException {
        try {
            return (IPermissionSet)
                    EntityCachingService.getEntityCachingService()
                            .get(this.PERMISSION_SET_TYPE, principal.getPrincipalString());
        } catch (CachingException ce) {
            throw new AuthorizationException(
                    "Problem getting permissions for " + principal + " from cache", ce);
        }
    }
639022
@Override
    public void update(IPermission[] perms) throws AuthorizationException {
        if (perms.length > 0) {
            try {
                primUpdate(perms);
            } catch (Exception ex) {
                log.error("Exception updating permissions " + Arrays.toString(perms), ex);
                throw new AuthorizationException(ex);
            }
        }
    }
229433
public boolean logout() {
    subject.getPrincipals().removeAll(principals);
    subject.getPrivateCredentials().removeAll(privateCredentials);
    subject.getPublicCredentials().removeAll(publicCredentials);
    principals.clear();
    privateCredentials.clear();
    publicCredentials.clear();
    return true;
  }
848775
public void invalidateLookupCacheEntries(Set<ChannelID> channelIDs) {
		for (ChannelID id : channelIDs) {
			this.receiverCache.remove(id);
		}
	}
1009072
private function doLoadSharingPermissions(array $idSubjects, array $roles): void
    {
        /** @var RoleInterface[] $mapRoles */
        $mapRoles = [];
        $cRoles = $this->provider->getPermissionRoles($roles);

        foreach ($cRoles as $role) {
            $mapRoles[$role->getName()] = $role;
        }

        /** @var SubjectIdentityInterface $subject */
        foreach ($idSubjects as $id => $subject) {
            foreach ($this->cacheRoleSharing[$id] as $roleId) {
                if (isset($mapRoles[$roleId])) {
                    $cRole = $mapRoles[$roleId];

                    foreach ($cRole->getPermissions() as $perm) {
                        $class = $subject->getType();
                        $field = PermissionUtils::getMapAction($perm->getField());
                        $this->cacheSharing[$id][$class][$field][$perm->getOperation()] = true;
                    }
                }
            }
        }
    }
851059
public void setStaleIpPermissions(java.util.Collection<StaleIpPermission> staleIpPermissions) {
        if (staleIpPermissions == null) {
            this.staleIpPermissions = null;
            return;
        }

        this.staleIpPermissions = new com.amazonaws.internal.SdkInternalList<StaleIpPermission>(staleIpPermissions);
    }
223831
public static void clearInvalidSessions(final Principal user) {

		logger.info("Clearing invalid sessions for user {} ({})", user.getName(), user.getUuid());

		final PropertyKey<String[]> sessionIdKey = StructrApp.key(Principal.class, "sessionIds");
		final String[] sessionIds                = user.getProperty(sessionIdKey);

		if (sessionIds != null && sessionIds.length > 0) {

			final SessionCache sessionCache = Services.getInstance().getService(HttpService.class).getSessionCache();

			for (final String sessionId : sessionIds) {

				HttpSession session = null;
				try {
					session = sessionCache.get(sessionId);

				} catch (Exception ex) {
					logger.warn("Unable to retrieve session " + sessionId + " from session cache:", ex);
				}

				if (session == null || SessionHelper.isSessionTimedOut(session)) {
					SessionHelper.clearSession(sessionId);
				}
			}
		}
	}
183303
public void unregisterProviders(Collection<?> providers) {
		ProvidedResourceScanner providedResourceScanner = new ProvidedResourceScanner(getFhirContext());
		if (providers != null) {
			for (Object provider : providers) {
				removeResourceMethods(provider);
				if (provider instanceof IResourceProvider) {
					myResourceProviders.remove(provider);
					IResourceProvider rsrcProvider = (IResourceProvider) provider;
					Class<? extends IBaseResource> resourceType = rsrcProvider.getResourceType();
					providedResourceScanner.removeProvidedResources(rsrcProvider);
				} else {
					myPlainProviders.remove(provider);
				}
				invokeDestroy(provider);
			}
		}
	}
617286
private void clearAuthorizationTable() {
        accessIdToRoles.clear();
        userToAccessId.clear();
        groupToAccessId.clear();
        userToRoles.clear();
        groupToRoles.clear();
    }
958769
@Override
    public IAuthorizationPrincipal getPrincipal(IPermission permission)
            throws AuthorizationException {
        String principalString = permission.getPrincipal();
        int idx = principalString.indexOf(PRINCIPAL_SEPARATOR);
        Integer typeId = Integer.valueOf(principalString.substring(0, idx));
        Class type = EntityTypesLocator.getEntityTypes().getEntityTypeFromID(typeId);
        String key = principalString.substring(idx + 1);
        return newPrincipal(key, type);
    }