org.dvb.net.ca
Class CAPermission

java.lang.Object
  extended byjava.security.Permission
      extended byjava.security.BasicPermission
          extended byorg.dvb.net.ca.CAPermission
All Implemented Interfaces:
java.security.Guard, java.io.Serializable

public class CAPermission
extends java.security.BasicPermission

This class is for CA permissions. A CAPermission contains a name, but no actions list.

A CAPermission contains a range of CA system ids and a specific permission for that range of CA system ids. Instead of a range of CA system ids, the CAPermission can also refer to a single CA system id.

The name has the following syntax:

CASystemIdRange ":" Permission

where CASystemIdRange = CASystemId [ "-" CASystemId ] | "*"
and Permission = "MMI" | "buy" | "entitlementInfo" | "messagePassing" | "*"

Examples:

Note: The CASystemId is expressed as a hexadecimal value.

The permission "MMI" corresponds with the SecurityException on CAModuleManager.addMMIListener(). The permission "buy" corresponds with the SecurityException on CAModule.buyEntitlement(). The permission "entitlementInfo" corresponds with the SecurityException on CAModule.queryEntitlement() and CAModule.listEntitlements(). The permission "messagePassing" corresponds with CAModule.openMessageSession(MessageListener)

See Also:
Serialized Form

Constructor Summary
CAPermission(java.lang.String name)
          Creates a new CAPermission with the specified name.
CAPermission(java.lang.String name, java.lang.String actions)
          Creates a new CAPermission object with the specified name.
 
Method Summary
 boolean implies(java.security.Permission p)
          Checks if the specified permission is "implied" by this object.
 
Methods inherited from class java.security.BasicPermission
equals, getActions, hashCode, newPermissionCollection
 
Methods inherited from class java.security.Permission
checkGuard, getName, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CAPermission

public CAPermission(java.lang.String name)
Creates a new CAPermission with the specified name. The name is the symbolic name of the CAPermission.

Parameters:
name - the name of the CAPermission

CAPermission

public CAPermission(java.lang.String name,
                    java.lang.String actions)
Creates a new CAPermission object with the specified name. The name is the symbolic name of the CAPermission, and the actions String is unused and should be null. This constructor exists for use by the Policy object to instantiate new Permission objects.

Parameters:
name - the name of the CAPermission
actions - should be null.
Method Detail

implies

public boolean implies(java.security.Permission p)
Checks if the specified permission is "implied" by this object.

Parameters:
p - the permission to check against.
Returns:
true if the passed permission is equal to or implied by this permission, false otherwise.