Top Description Fields Constructors Methods
org.bouncycastle.jcajce.provider.config

public Class ProviderConfigurationPermission

extends BasicPermission
Class Inheritance
Imports
java.security.BasicPermission, .Permission, java.util.StringTokenizer, org.bouncycastle.util.Strings

A permission class to define what can be done with the ConfigurableProvider interface.

Available permissions are "threadLocalEcImplicitlyCa" and "ecImplicitlyCa" which allow the setting of the thread local and global ecImplicitlyCa parameters respectively.

Examples:

Note

permission checks are only enforced if a security manager is present.

Field Summary

Modifier and TypeField and Description
private static final int
private static final String
private final String
private static final int
private static final String
private static final int
private static final String
private static final int
private static final String
private static final int
private static final String
private final int
private static final int
private static final String
private static final int
private static final String

Constructor Summary

AccessConstructor and Description
public
public

Method Summary

Modifier and TypeMethod and Description
private int
public boolean
equals(Object
the object we are testing for equality with this object.
obj
)

Overrides java.security.BasicPermission.equals.

Checks two BasicPermission objects for equality.
public String
getActions()

Overrides java.security.BasicPermission.getActions.

Returns the canonical string representation of the actions, which currently is the empty string "", since there are no actions for a BasicPermission.
public int
hashCode()

Overrides java.security.BasicPermission.hashCode.

Returns the hash code value for this object.
public boolean
implies(Permission
the permission to check against.
permission
)

Overrides java.security.BasicPermission.implies.

Checks if the specified permission is "implied" by this object.
Inherited from java.security.BasicPermission:
newPermissionCollection

Field Detail

ACCEPTABLE_EC_CURVESback to summary
private static final int ACCEPTABLE_EC_CURVES
ACCEPTABLE_EC_CURVES_STRback to summary
private static final String ACCEPTABLE_EC_CURVES_STR
actionsback to summary
private final String actions
ADDITIONAL_EC_PARAMETERSback to summary
private static final int ADDITIONAL_EC_PARAMETERS
ADDITIONAL_EC_PARAMETERS_STRback to summary
private static final String ADDITIONAL_EC_PARAMETERS_STR
ALLback to summary
private static final int ALL
ALL_STRback to summary
private static final String ALL_STR
DH_DEFAULT_PARAMSback to summary
private static final int DH_DEFAULT_PARAMS
DH_DEFAULT_PARAMS_STRback to summary
private static final String DH_DEFAULT_PARAMS_STR
EC_IMPLICITLY_CAback to summary
private static final int EC_IMPLICITLY_CA
EC_IMPLICITLY_CA_STRback to summary
private static final String EC_IMPLICITLY_CA_STR
permissionMaskback to summary
private final int permissionMask
THREAD_LOCAL_DH_DEFAULT_PARAMSback to summary
private static final int THREAD_LOCAL_DH_DEFAULT_PARAMS
THREAD_LOCAL_DH_DEFAULT_PARAMS_STRback to summary
private static final String THREAD_LOCAL_DH_DEFAULT_PARAMS_STR
THREAD_LOCAL_EC_IMPLICITLY_CAback to summary
private static final int THREAD_LOCAL_EC_IMPLICITLY_CA
THREAD_LOCAL_EC_IMPLICITLY_CA_STRback to summary
private static final String THREAD_LOCAL_EC_IMPLICITLY_CA_STR

Constructor Detail

ProviderConfigurationPermissionback to summary
public ProviderConfigurationPermission(String name)
ProviderConfigurationPermissionback to summary
public ProviderConfigurationPermission(String name, String actions)

Method Detail

calculateMaskback to summary
private int calculateMask(String actions)
equalsback to summary
public boolean equals(Object obj)

Overrides java.security.BasicPermission.equals.

Doc from java.security.BasicPermission.equals.

Checks two BasicPermission objects for equality. Checks that obj's class is the same as this object's class and has the same name as this object.

Parameters
obj:Object

the object we are testing for equality with this object.

Returns:boolean

true if obj's class is the same as this object's class and has the same name as this BasicPermission object, false otherwise.

getActionsback to summary
public String getActions()

Overrides java.security.BasicPermission.getActions.

Doc from java.security.BasicPermission.getActions.

Returns the canonical string representation of the actions, which currently is the empty string "", since there are no actions for a BasicPermission.

Returns:String

the empty string "".

hashCodeback to summary
public int hashCode()

Overrides java.security.BasicPermission.hashCode.

Doc from java.security.BasicPermission.hashCode.

Returns the hash code value for this object. The hash code used is the hash code of the name, that is, getName().hashCode(), where getName is from the Permission superclass.

Returns:int

a hash code value for this object.

impliesback to summary
public boolean implies(Permission permission)

Overrides java.security.BasicPermission.implies.

Doc from java.security.BasicPermission.implies.

Checks if the specified permission is "implied" by this object.

More specifically, this method returns true if:

  • p's class is the same as this object's class, and
  • p's name equals or (in the case of wildcards) is implied by this object's name. For example, "a.b.*" implies "a.b.c".
Parameters
permission:Permission

the permission to check against.

Returns:boolean

true if the passed permission is equal to or implied by this permission, false otherwise.