Package pyGlobus :: Module security :: Class GSSCred
[show private | hide private]
[frames | no frames]

Class GSSCred


A class for the underlying gss_cred_id_t object.
Method Summary
  __init__(self, handle, free)
Constructs an instance.
  __del__(self)
Destroys an instance.
  acquire_cred(self, name, desired_mechs, usage, time_requested)
Acquires a credential, for example the one created by grid_proxy_init in /tmp/x509uid
  export_external(self)
Saves the credential so it can be checkpointed and imported by import_external
  get_handle(self)
  import_external(self, credHandle)
Imports an external credential
  inquire_cred(self)
Retrieves information about the credential

Method Details

__init__(self, handle=None, free=1)
(Constructor)

Constructs an instance.

Each instance wraps a gss_cred_id_t object.
Parameters:
handle - A SWIG'ized pointer to a gss_cred_id_t object.
free - Should the underlying gss_cred_id_t object be freed when an instance is destroyed.

__del__(self)
(Destructor)

Destroys an instance.

Deletes the underlying gss_cred_id_t object, and free's the memory if the instance owns the underlying handle.

acquire_cred(self, name=None, desired_mechs=None, usage=None, time_requested=4294967295L)

Acquires a credential, for example the one created by grid_proxy_init in /tmp/x509uid
Parameters:
name - a GSSName object
desired_mechs - a GSSMechs object
usage - a GSSUsage object
time_requested - - an int which requests how long you would like the credential to be valid. Note:If you are using the globus_gssapi then this will have no effect. Their call just returns how long the credential that you created is valid(ie using grid-proxy-init)
Returns:
None
Raises:
GSSCredException - A GSSCredException is thrown if there is a problem acquiring the credential

export_external(self)

Saves the credential so it can be checkpointed and imported by import_external
Returns:
A string pointing the location of the expored credential
Raises:
GSSCredException - A GSSCredException is raised if there is a problem in the underlying cred

import_external(self, credHandle)

Imports an external credential
Parameters:
credHandle - - A string describing the type and location of the credential to import
Returns:
A GSSCred Object
Raises:
GSSCredException - A GSSCredException is raised if the the credential cannot be imported

inquire_cred(self)

Retrieves information about the credential
Returns:
A tuple of the lifetime in seconds and GSSName object
Raises:
GSSCredException - A GSSCredException is thrown if there is a problem inquiring about the credential
GSSCredException - A GSSCredException is raised if the the credential cannot be imported

Generated by Epydoc 2.1 on Tue Apr 4 14:32:56 2006 http://epydoc.sf.net