public class DynamicPrincipal_c extends Principal_c implements DynamicPrincipal
DynamicPrincipal interface.variables| Constructor and Description |
|---|
DynamicPrincipal_c(AccessPath path,
JifTypeSystem ts,
polyglot.util.Position pos,
PrincipalToJavaExpr toJava) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equalsImpl(polyglot.types.TypeObject o) |
int |
hashCode() |
boolean |
isCanonical() |
boolean |
isRuntimeRepresentable() |
PathMap |
labelCheck(JifContext A,
LabelChecker lc)
Label check the principal, which will determine how much information may be
gained if the principal is evaluated at runtime.
|
AccessPath |
path() |
Principal |
subst(LabelSubstitution substitution) |
java.util.List<polyglot.types.Type> |
throwTypes(polyglot.types.TypeSystem ts)
If the principal is runtime representable, when it is evaluated at
runtime it may throw exceptions.
|
java.lang.String |
toString() |
hasVariables, isBottomPrincipal, isTopPrincipal, simplify, toJava, variablestypeSystemclone, finalize, getClass, notify, notifyAll, wait, wait, waithasVariables, isBottomPrincipal, isTopPrincipal, simplify, variablestoJavatypeSystempublic DynamicPrincipal_c(AccessPath path, JifTypeSystem ts, polyglot.util.Position pos, PrincipalToJavaExpr toJava)
public AccessPath path()
path in interface DynamicPrincipalpublic boolean isRuntimeRepresentable()
isRuntimeRepresentable in interface ParamisRuntimeRepresentable in class Principal_cpublic boolean isCanonical()
isCanonical in interface ParamisCanonical in interface polyglot.types.TypeObjectisCanonical in class Principal_cpublic java.lang.String toString()
toString in class java.lang.Objectpublic boolean equalsImpl(polyglot.types.TypeObject o)
equalsImpl in interface polyglot.types.TypeObjectequalsImpl in class Principal_cpublic int hashCode()
hashCode in class Principal_cpublic java.util.List<polyglot.types.Type> throwTypes(polyglot.types.TypeSystem ts)
PrincipalthrowTypes in interface PrincipalthrowTypes in class Principal_cpublic Principal subst(LabelSubstitution substitution) throws polyglot.types.SemanticException
subst in interface ActsForParamsubst in interface Principalsubst in class Principal_csubstitution - The LabelSubstitution to apply to this
principalpolyglot.types.SemanticExceptionpublic PathMap labelCheck(JifContext A, LabelChecker lc)
Principal
boolean{Alice:} secret = ...;
final principal{Alice:} p = secret?Bob:Chuck;
boolean{} leak = false;
if (p actsfor Bob) { // evaluation of p reveals
// information at level {Alice:}
leak = true;
}
labelCheck in interface PrincipallabelCheck in class Principal_cJifExt.labelCheck(LabelChecker),
Label.labelCheck(JifContext, LabelChecker)