spki
Class ValidOffline

java.lang.Object
  |
  +--spki.BaseObj
        |
        +--spki.ValidOffline

public class ValidOffline
extends BaseObj

SPKI ValidOffline class.

Formal definitions:

 <nonce>:: <byte-string> ;
 <valid-one>:: "(" "one-time" <nonce> ")" ;
 <new-cert>:: "(" "new-cert" <loc-obj> ")" ;
 <off-line>:: "(" "off-line" <valid-one>? <new-cert>? ")" ;
 

Version:
$Id: ValidOffline.java,v 1.12 2002/06/24 18:07:41 tep Exp $
Author:
Tep Narula <tep@win.trlabs.ca>
See Also:
LocObj, Validity

Field Summary
private static String __ME
          This class's full name.
private  LocObj newcert_loc
          The location of replacement-certificate issuing service.
static String NEWCERT_SEXP_NAME
          The new-cert validity condition S-Expression type name, used by toSExpression() and other methods.
private  Sexp onetime_nonce
          The one-time nonce value.
static String ONETIME_SEXP_NAME
          The one-time validity condition S-Expression type name, used by toSExpression() and other methods.
static String SEXP_NAME
          This class S-Expression type name, used by toSExpression() and other methods.
 
Fields inherited from class spki.BaseObj
__ME, cache_sexp, cached_sexp, DEFAULT_HASH_ALG, locked, SEXP_NAME
 
Constructor Summary
protected ValidOffline()
          Don't use me!
  ValidOffline(Sexp onetime_nonce, LocObj newcert_loc)
          Create an immutable ValidOffline object from given one-time nonce value and/or replacement-certificate issuing service location.
  ValidOffline(SExpression sexp)
          Create an immutable ValidOffline object from an S-Expression.
 
Method Summary
 LocObj getNewCertLoc()
          Get the location of the replacement-certificate issuing service, if available.
 Sexp getOneTimeNonce()
          Get the one-time nonce value, if available.
 SExpression toSExpression()
          Build an SExpression representing this object.
 
Methods inherited from class spki.BaseObj
disableSExpressionCaching, enableSExpressionCaching, extractHashAlgId, getCachedSExpression, isLocked, isSListOfType, lock, providerToSPKI, setCachedSExpression, spkiToProvider, toString
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, wait, wait, wait
 

Field Detail

__ME

private static final String __ME
This class's full name.

SEXP_NAME

public static final String SEXP_NAME
This class S-Expression type name, used by toSExpression() and other methods.
See Also:
toSExpression()

ONETIME_SEXP_NAME

public static final String ONETIME_SEXP_NAME
The one-time validity condition S-Expression type name, used by toSExpression() and other methods.
See Also:
toSExpression()

onetime_nonce

private Sexp onetime_nonce
The one-time nonce value.

NEWCERT_SEXP_NAME

public static final String NEWCERT_SEXP_NAME
The new-cert validity condition S-Expression type name, used by toSExpression() and other methods.
See Also:
toSExpression()

newcert_loc

private LocObj newcert_loc
The location of replacement-certificate issuing service.
Constructor Detail

ValidOffline

protected ValidOffline()
Don't use me!
See Also:
ValidOffline(SExpression), ValidOffline(Sexp,LocObj)

ValidOffline

public ValidOffline(SExpression sexp)
             throws ParseException,
                    SPKIException
Create an immutable ValidOffline object from an S-Expression.
See Also:
BaseObj.BaseObj(SExpression)

ValidOffline

public ValidOffline(Sexp onetime_nonce,
                    LocObj newcert_loc)
             throws SPKIException
Create an immutable ValidOffline object from given one-time nonce value and/or replacement-certificate issuing service location. At least one of the two argument must be given.
Parameters:
onetime_nonce - the one-time validity nonce value, maybe null.
newcert_loc - the replacement-certificate issuing service location, maybe null.
Throws:
SPKIException - if something went wrong.
Method Detail

toSExpression

public SExpression toSExpression()
                          throws SPKIException
Description copied from interface: SPKIObject
Build an SExpression representing this object.
Overrides:
toSExpression in class BaseObj
Tags copied from interface: SPKIObject
Returns:
SExpression object representing this object, or null.
Throws:
SPKIException - if something went wrong during conversion.

getOneTimeNonce

public Sexp getOneTimeNonce()
                     throws SPKIException
Get the one-time nonce value, if available.
Returns:
Sexp containing the one-time nonce value, or null.
Throws:
SPKIException - if something went wrong.

getNewCertLoc

public LocObj getNewCertLoc()
Get the location of the replacement-certificate issuing service, if available.
Returns:
LocObj containing the location, or null.