Repository URL to install this package:
|
Version:
2.5 ▾
|
ó
͍EYc @ sJ d Z d d l Z d d l Z e j e j d e f d Y Z d S( s
Key manager API
iÿÿÿÿNt
KeyManagerc B s e Z d Z e j d Z e j d d d Z e j d d d Z e j d d Z e j e
d Z e j d Z RS( s¶ Base Key Manager Interface
A Key Manager is responsible for managing encryption keys for volumes. A
Key Manager is responsible for creating, reading, and deleting keys.
c C s d S( s¥ Instantiate a KeyManager object.
Creates a KeyManager object with implementation specific details
obtained from the supplied configuration.
N( ( t selft
configuration( ( sV /home/tvault/.virtenv/lib/python2.7/site-packages/castellan/key_manager/key_manager.pyt __init__! s c C s d S( sê Creates a symmetric key.
This method creates a symmetric key and returns the key's UUID. If the
specified context does not permit the creation of keys, then a
NotAuthorized exception should be raised.
N( ( R t contextt algorithmt lengtht
expirationt name( ( sV /home/tvault/.virtenv/lib/python2.7/site-packages/castellan/key_manager/key_manager.pyt
create_key* s c C s d S( s9 Creates an asymmetric key pair.
This method creates an asymmetric key pair and returns the pair of key
UUIDs. If the specified context does not permit the creation of keys,
then a NotAuthorized exception should be raised. The order of the UUIDs
will be (private, public).
N( ( R R R R R R ( ( sV /home/tvault/.virtenv/lib/python2.7/site-packages/castellan/key_manager/key_manager.pyt create_key_pair5 s
c C s d S( s7 Stores a managed object with the key manager.
This method stores the specified managed object and returns its UUID
that identifies it within the key manager. If the specified context
does not permit the creation of keys, then a NotAuthorized exception
should be raised.
N( ( R R t managed_objectR ( ( sV /home/tvault/.virtenv/lib/python2.7/site-packages/castellan/key_manager/key_manager.pyt storeA s c C s d S( s# Retrieves the specified managed object.
Implementations should verify that the caller has permissions to
retrieve the managed object by checking the context object passed in
as context. If the user lacks permission then a NotAuthorized
exception is raised.
If the caller requests only metadata, then the object that is
returned will contain only the secret metadata and no secret bytes.
If the specified object does not exist, then a KeyError should be
raised. Implementations should preclude users from discerning the
UUIDs of objects that belong to other users by repeatedly calling
this method. That is, objects that belong to other users should be
considered "non-existent" and completely invisible.
N( ( R R t managed_object_idt
metadata_only( ( sV /home/tvault/.virtenv/lib/python2.7/site-packages/castellan/key_manager/key_manager.pyt getL s c C s d S( s Deletes the specified managed object.
Implementations should verify that the caller has permission to delete
the managed object by checking the context object (context). A
NotAuthorized exception should be raised if the caller lacks
permission.
If the specified object does not exist, then a KeyError should be
raised. Implementations should preclude users from discerning the
UUIDs of objects that belong to other users by repeatedly calling this
method. That is, objects that belong to other users should be
considered "non-existent" and completely invisible.
N( ( R R R
( ( sV /home/tvault/.virtenv/lib/python2.7/site-packages/castellan/key_manager/key_manager.pyt delete` s N(
t __name__t
__module__t __doc__t abct abstractmethodR t NoneR R
R t FalseR R ( ( ( sV /home/tvault/.virtenv/lib/python2.7/site-packages/castellan/key_manager/key_manager.pyR s
( R R t sixt
add_metaclasst ABCMetat objectR ( ( ( sV /home/tvault/.virtenv/lib/python2.7/site-packages/castellan/key_manager/key_manager.pyt <module> s