OpenSSOPrivilege.java revision fb3b3a01405c222ae1fdbbe6f5c1d4aa696195bb
/**
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
*
* Copyright (c) 2009 Sun Microsystems Inc. All Rights Reserved
*
* The contents of this file are subject to the terms
* of the Common Development and Distribution License
* (the License). You may not use this file except in
* compliance with the License.
*
* You can obtain a copy of the License at
* See the License for the specific language governing
* permission and limitations under the License.
*
* When distributing Covered Code, include this CDDL
* Header Notice in each file and include the License file
* at opensso/legal/CDDLv1.0.txt.
* If applicable, add the following below the CDDL Header,
* with the fields enclosed by brackets [] replaced by
* your own identifying information:
* "Portions Copyrighted [year] [name of copyright owner]"
*
* $Id: OpenSSOPrivilege.java,v 1.5 2009/10/07 01:36:55 veiming Exp $
*/
/*
* Portions Copyrighted 2010-2014 ForgeRock Inc
* Portions Copyrighted 2013 Nomura Research Institute, Ltd
*/
/**
*
*
*/
public class OpenSSOPrivilege extends Privilege {
private String policyName;
private final PolicyMonitor policyMonitor;
public OpenSSOPrivilege() {
super();
}
public PrivilegeType getType() {
return PrivilegeType.OPENSSO;
}
final Subject adminSubject,
final String applicationName,
final String resourceName,
final boolean recursive,
) throws EntitlementException {
try {
new RestrictedTokenAction() {
return internalEvaluate(
);
}
});
}
return results;
}
boolean recursive
) throws EntitlementException {
if (!isActive()) {
return results;
}
resourceName, environment) &&
) {
"[PolicyEval] OpenSSOPrivilege.evaluate: resources=" +
}
r, origE.getActionValues());
e.setAdvices(advices);
}
} else {
e.setAdvices(advices);
}
if (MonitoringUtil.isRunning()) {
}
return results;
}
/**
* Returns JSONObject mapping of the object
* @return JSONObject mapping of the object
* @throws JSONException if can not map to JSONObject
*/
if (policyName != null) {
}
return jo;
}
}
/**
* Sets policy name.
*
* @param policyName Policy name.
*/
this.policyName = policyName;
}
/**
* Returns policy name.
*
* @return policyName Policy name.
*/
public String getPolicyName() {
return this.policyName;
}
}
}
return minTTL;
}
}