bees.core.security
Class PublicKeySpec
java.lang.Object
|
+--bees.core.Capability
|
+--bees.core.security.KeySpec
|
+--bees.core.security.PublicKeySpec
- All Implemented Interfaces:
- CapabilitySpec
- Direct Known Subclasses:
- PublicKey
- public class PublicKeySpec
- extends KeySpec
The PublicKeySpec class wraps a java.security.PublicKey object. While this
class extends the Capability class it does not have to be a full capability
in order to be useful. Its possible for untrusted code to create a
PublicKeySpec object from capability material and use it with a Signature
object.
|
Constructor Summary |
PublicKeySpec()
Construct an empty PublicKeySpec. |
PublicKeySpec(java.security.PublicKey pk)
Construct a PublicKeySpec with the given value. |
| Methods inherited from class bees.core.Capability |
checkPermission, clear, clonePermission, deleteCapability, equals, fromBytes, fromBytes, revokedPermission, revokePermission, revokePermissions, valid |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
PublicKeySpec
public PublicKeySpec(java.security.PublicKey pk)
- Construct a PublicKeySpec with the given value.
- Parameters:
pk - A PublicKey object to be wrapped.
PublicKeySpec
public PublicKeySpec()
- Construct an empty PublicKeySpec.
createKey
public final void createKey(java.lang.String algorithm,
byte[] encoding)
throws java.security.NoSuchAlgorithmException,
java.security.spec.InvalidKeySpecException
- See Also:
bees.core.security.KeySpec#createKey(String, byte[])
toBytes
public byte[] toBytes()
- See Also:
bees.core.security.KeySpec#toBytes()
revoke
public void revoke()
- Description copied from class:
Capability
- Revoke access to the capability.
- Overrides:
revoke in class Capability
- See Also:
Capability.revoke()
getAlgorithm
public java.lang.String getAlgorithm()
- Returns:
- The key algorithm.
getFormat
public java.lang.String getFormat()
- Returns:
- The format of the encoded key.
toString
public java.lang.String toString()
- Overrides:
toString in class KeySpec
- See Also:
Object.toString()
This documentation is Copyright (C) 2002 The University of Utah. All Rights Reserved. See the individual source files for distribution terms.
Documentation, software, and mailing lists for Bees v0.5.0 can be found at the Janos Project: http://www.cs.utah.edu/flux/janos/