Annotation of win32/sql/oracle/include/oci/nzt.h, revision 1.1

1.1     ! parser      1: /* DISABLE check_long_lines */
        !             2: 
        !             3: /* Copyright (c) Oracle Corporation 1996, 1997, 1998, 1999.  All Rights Reserved. */
        !             4: /* Copyright (c) Oracle Corporation 1996, 1997, 1998, 1999.  All Rights Reserved. */
        !             5: 
        !             6: /*
        !             7:  * $Header: /var/lib/cvsroot/parser3/parser3/src/sql/oracle/oracle32/include/oci/nzt.h,v 1.1 2001/08/22 14:02:18 parser Exp $ 
        !             8:  * $Header: /var/lib/cvsroot/parser3/parser3/src/sql/oracle/oracle32/include/oci/nzt.h,v 1.1 2001/08/22 14:02:18 parser Exp $ 
        !             9:  */
        !            10: 
        !            11: /* 
        !            12:  * NAME
        !            13:  *    nzt.h
        !            14:  * 
        !            15:  * DESCRIPTION
        !            16:  *    Toolkit public declarations.
        !            17:  *    
        !            18:  * PUBLIC FUNCTIONS
        !            19:  *    nztwOpenWallet           - Open a wallet based on a WRL and pwd.
        !            20:  *    nztwCloseWallet          - Close a wallet.
        !            21:  * +  nztwCreateWallet         - Create a new wallet.
        !            22:  * +  nztwDestroyWallet        - Destroy an existing wallet.
        !            23:  *    nztwRetrievePersonaCopy  - Retieve a copy of a particular persona.
        !            24:  * +  nzteStorePersona         - Store a persona in the wallet.
        !            25:  *    nzteOpenPersona          - Open a persona.
        !            26:  *    nzteClosePersona         - Close a persona.
        !            27:  * +  nzteRemovePersona        - Remove a persona from a wallet.
        !            28:  * +  nzteCreatePersona        - Create a persona.
        !            29:  *    nzteDestroyPersona       - Destroy a persona.
        !            30:  *    nztiStoreTrustedIdentity - Store an identity with associated trust.
        !            31:  *    nzteRetrieveTrustedIdentCopy - Retrieves a trusted identity from persona
        !            32:  * +  nzteSetProtection        - Modify the protection set in a persona.
        !            33:  * +  nzteGetProtection        - Get the protection set in a persona
        !            34:  *    nztePriKey               - Get the Private Key (X509 Only)
        !            35:  *    nzteMyCert               - Get the Certificate (X509 only)
        !            36:  *    nzteX509CreatePersona    - Create a persona given an X509 Certificate.
        !            37:  * +  nztiRemoveIdentity       - Remove an identity from a persona.
        !            38:  *    nztiCreateIdentity       - Create an identity.
        !            39:  *    nztiDuplicateIdentity    - Create a complete copy of an identity.
        !            40:  *    nztiAbortIdentity        - Discard an unstored identity.
        !            41:  *    nztidGetIdentityDesc     - Gets Identity Description from Identity.
        !            42:  *    nztidFreeIdentityDesc    - Frees memory for Identity Desc object.
        !            43:  *    nztSign                  - Generate an attached signature.
        !            44:  * +  nztxSignExpansion        - Determine size of signature.
        !            45:  *    nztVerify                - Verify an attached signature.               
        !            46:  *    nztValidate              - Validate an identity.                       
        !            47:  *    nztsd_SignDetached       - Generate a detached signature.
        !            48:  * +  nztxsd_SignDetachedExpansion - Determine size of detached signature.
        !            49:  *    nztved_VerifyDetached    - Verify a detached signature.                 
        !            50:  * +  nztEncrypt               - Symmetric key encryption.   
        !            51:  * +  nztxEncryptExpansion     - Determine the tdu length for encryption.
        !            52:  * +  nztDecrypt               - Symmetric key decryption.                   
        !            53:  * +  nztEnvelope              - Sign then encrypt data for recipient(s).    
        !            54:  * +  nztDeEnvelope            - Reverse nztEnvelope.                        
        !            55:  * +  nztKeyedHash             - Generate keyed hash.                        
        !            56:  * +  nztxKeyedHashExpansion   - Determine size of TDU for keyed hash.
        !            57:  *    nztHash                  - Generate hash.   
        !            58:  * +  nztxHashExpansion        - Determine the size of the TDU for a hash.
        !            59:  *    nztSeedRandom            - See the random number generator.
        !            60:  *    nztrb_RandomBytes        - Generate a series of random bytes.          
        !            61:  *    nztrn_RandomNumber       - Generate a random number.                   
        !            62:  *    nztbbInitBlock           - Initialize a buffer block.                  
        !            63:  *    nztbbReuseBlock          - Reuse a buffer block.           
        !            64:  *    nztbbSizeBlock           - Find the size of the buffer block.
        !            65:  *    nztbbGrowBlock           - Grow initialized buffer block by 'inc' bytes.
        !            66:  *    nztbbPurgeBlock          - Purge the memory used within a buffer block.
        !            67:  *    nztbbSetBlock            - Set block to known state.
        !            68:  *    nztkec_PKEncrypt         - Encrypt data then encrypt key for recipient.
        !            69:  *    nztkdc_PKDecrypt         - Decrypt PKEncrypt'ed data.                  
        !            70:  *    nztific_FreeIdentityContent - Free the contents of an identity.
        !            71:  *    nztifdn                  - Create an identity from a distinguished name
        !            72:  *    nztcts_CipherSpecToStr   - Converts the Cipher Spec Code To String
        !            73:  *    nztiae_IsAuthEnabled     - Checks to see if Authentication is Enabled
        !            74:  *                               in the current Cipher Spec.
        !            75:  *    nztiae_IsEncrEnabled     - Checks to see if Encryption is Enabled
        !            76:  *                               in the current Cipher Spec.
        !            77:  *    nztiae_IsHashEnabled     - Checks to see if Hashing is Enabled
        !            78:  *                               in the current Cipher Spec.
        !            79:  *
        !            80:  * NOTE: the '+' indicates that these functions are UNSUPPORTED at this time.
        !            81:  * 
        !            82:  * NOTES
        !            83:  *    
        !            84:  * MODIFIED
        !            85:  *    skanjila   06/25/99 - Remove nztcts_CipherSpecToStr() to NZOS.
        !            86:  *    skanjila   06/23/99 - Change API of nztcts_CipherSpecToStr.
        !            87:  *    lkethana   06/18/99 - rem nztIPrivateAlloc, etc
        !            88:  *    lkethana   06/10/99 - changing size_t to ub4
        !            89:  *    lkethana   06/02/99 - add api for getting auth/encry/hash capability of c
        !            90:  *    arswamin   12/28/98 - add NZT_MAX_MD5.
        !            91:  *    arswamin   12/21/98 - change signature of compareDN
        !            92:  *    qdinh      12/21/98 - change size_t to ub4.
        !            93:  *    inetwork   11/22/98 - Removing NZDEPRECATED definition
        !            94:  *    amthakur   09/14/98 - deprecating and updating the c-structures.
        !            95:  *    arswamin   09/24/98 - adding NZTTWRL_NULL for SSO support.
        !            96:  *    amthakur   07/30/98 - changing the prototype of nztGetCertChain.
        !            97:  *    qdinh      05/01/98 - add NZTTIDENTTYPE_INVALID_TYPE
        !            98:  *    qdinh      04/17/98 - add NZTTWRL_ORACLE.
        !            99:  *    ascott     10/08/97 - implement nztiStoreTrustedIdentity
        !           100:  *    ascott     10/07/97 - add nztiGetIdentityDesc
        !           101:  *    ascott     09/28/97 - clarify prototype comments and error codes
        !           102:  *    ascott     09/05/97 - update identity: create, destroy, duplicate
        !           103:  *    ascott     08/21/97 - add GetCert and GetPriKey
        !           104:  *    ascott     08/07/97 - add other WRL settings
        !           105:  *    asriniva   03/25/97 - Add ANSI prototypes
        !           106:  *    rwessman   03/19/97 - Added prototypes for nztific_FreeIdentityContent()
        !           107:  *    asriniva   03/11/97 - Fix olint errors
        !           108:  *    sdange     02/28/97 - Removed inclusion of nz0decl.h
        !           109:  *    sdange     02/18/97 - Moved nzt specific declarations from nz0decl.h
        !           110:  *    asriniva   01/21/97 - Remove prototypes.
        !           111:  *    asriniva   10/31/96 - Include oratypes.h
        !           112:  *    asriniva   10/15/96 - Declare buffer block helper functions
        !           113:  *    asriniva   10/08/96 - First pass at wallet open/close
        !           114:  *    asriniva   10/04/96 - Add random number seed function
        !           115:  *    asriniva   10/03/96 - Reorder parameters in nztbbSetBlock
        !           116:  *    asriniva   10/03/96 - Keep editing.
        !           117:  *    asriniva   10/03/96 - Continued edits.
        !           118:  *    asriniva   10/02/96 - Continue editing.
        !           119:  *    asriniva   09/26/96 -
        !           120:  */
        !           121:    
        !           122: /* ENABLE check_long_lines */
        !           123: 
        !           124: #ifndef NZT_ORACLE
        !           125: #define NZT_ORACLE
        !           126: 
        !           127: #ifndef ORATYPES
        !           128: # include <oratypes.h>
        !           129: #endif /* ORATYPES */
        !           130: 
        !           131: #ifndef NZERROR_ORACLE
        !           132: # include <nzerror.h>         /* NZ error type */
        !           133: #endif /* NZERROR_ORACLE */
        !           134: 
        !           135: #define NZT_MAX_SHA1 20
        !           136: #define NZT_MAX_MD5  16
        !           137: 
        !           138: /***************************************/
        !           139: /* PUBLIC CONSTANTS, MACROS, AND TYPES */
        !           140: /***************************************/
        !           141: 
        !           142: /*
        !           143:  * Wallet Resource Locator Type Strings
        !           144:  *
        !           145:  * WRL TYPE        PARAMETERS      BEHAVIOR
        !           146:  * ========        ==========      =====================================
        !           147:  * default:          <none>        Uses directory defined by the parameter
        !           148:  *                                 SNZD_DEFAULT_FILE_DIRECTORY which in 
        !           149:  *                                 unix is "$HOME/oracle/oss"
        !           150:  * 
        !           151:  * file:            file path      example: file:/home/ascott
        !           152:  * 
        !           153:  * sqlnet:           <none>        In this case, the directory path will be 
        !           154:  *                                 retrieved from the sqlnet.ora file under
        !           155:  *                                 the oss.source.my_wallet parameter.
        !           156:  * 
        !           157:  */
        !           158: /* Note that there is no NZT_NULL_WRL.  Instead look in snzd.h for DEFAULT_WRP
        !           159:  * which is used in our new defaulting mechanism.  The NZT_DEFAULT_WRL
        !           160:  * should be deprecated.
        !           161:  */
        !           162: #define NZT_DEFAULT_WRL    ((text *)"default:")
        !           163: #define NZT_SQLNET_WRL     ((text *)"sqlnet:")
        !           164: #define NZT_FILE_WRL       ((text *)"file:")
        !           165: #define NZT_ORACLE_WRL    ((text *)"oracle:")
        !           166: #define NZT_NO_PASSWORD    ((text *)"")  /* NEVER USED */
        !           167: 
        !           168: enum nzttwrl 
        !           169: {
        !           170:    NZTTWRL_DEFAULT = 1,    /* Default, use SNZD_DEFAULT_FILE_DIRECTORY */
        !           171:    NZTTWRL_SQLNET,         /* Use oss.source.my_wallet in sqlnet.ora file */
        !           172:    NZTTWRL_FILE,           /* Find the wallet in this directory */
        !           173:    NZTTWRL_ORACLE,        /* Get the wallet from OSS db */
        !           174:    NZTTWRL_NULL            /* New SSO defaulting mechanism */
        !           175: };
        !           176: typedef enum nzttwrl nzttwrl;
        !           177: 
        !           178: #ifndef NZ0DECL_ORACLE
        !           179:    /*
        !           180:     * With the elimination of nz0decl.h from public, we need this
        !           181:     * redundant typedef.
        !           182:     */
        !           183:    typedef struct nzctx nzctx;
        !           184: #endif /* NZ0DECL_ORACLE */
        !           185: 
        !           186: /* Moved from nz0decl.h */
        !           187: 
        !           188: typedef struct nzttIdentity nzttIdentity;
        !           189: typedef struct nzttIdentityPrivate nzttIdentityPrivate;
        !           190: typedef struct nzttPersona nzttPersona;
        !           191: typedef struct nzttPersonaPrivate nzttPersonaPrivate;
        !           192: typedef struct nzttWallet nzttWallet;
        !           193: typedef struct nzttWalletPrivate nzttWalletPrivate;
        !           194: typedef struct nzttWalletObj nzttWalletObj; /* For wallet object */
        !           195: 
        !           196: /*
        !           197:  * Crypto Engine State
        !           198:  *
        !           199:  * Once the crypto engine (CE) has been initialized for a particular
        !           200:  * cipher, it is either at the initial state, or it is continuing to
        !           201:  * use the cipher.  NZTCES_END is used to change the state back to
        !           202:  * initialized and flush any remaining output.  NZTTCES_RESET can be
        !           203:  * used to change the state back to initialized and throw away any
        !           204:  * remaining output.
        !           205:  */
        !           206: enum nzttces 
        !           207: {
        !           208:    NZTTCES_CONTINUE = 1,    /* Continue processing input */
        !           209:    NZTTCES_END,             /* End processing input */
        !           210:    NZTTCES_RESET            /* Reset processing and skip generating output */
        !           211: };
        !           212: typedef enum nzttces nzttces;
        !           213: 
        !           214: /*
        !           215:  * Crypto Engine Functions
        !           216:  *
        !           217:  * List of crypto engine categories; used to index into protection
        !           218:  * vector.
        !           219:  */
        !           220: enum nzttcef
        !           221: {
        !           222:    NZTTCEF_DETACHEDSIGNATURE = 1,   /* Signature, detached from content */
        !           223:    NZTTCEF_SIGNATURE,               /* Signature combined with content */
        !           224:    NZTTCEF_ENVELOPING,              /* Signature and encryption with content */
        !           225:    NZTTCEF_PKENCRYPTION,            /* Encryption for one or more recipients */
        !           226:    NZTTCEF_ENCRYPTION,              /* Symmetric encryption */
        !           227:    NZTTCEF_KEYEDHASH,               /* Keyed hash/checkusm */
        !           228:    NZTTCEF_HASH,                    /* Hash/checsum */
        !           229:    NZTTCEF_RANDOM,                  /* Random byte generation */
        !           230: 
        !           231:    NZTTCEF_LAST                     /* Used for array size */
        !           232: };
        !           233: typedef enum nzttcef nzttcef;
        !           234: 
        !           235: /*
        !           236:  * State of the persona.
        !           237:  */
        !           238: enum nzttState
        !           239: {
        !           240:    NZTTSTATE_EMPTY = 0,     /* is not in any state(senseless???) */
        !           241:    NZTTSTATE_REQUESTED,     /* cert-request */
        !           242:    NZTTSTATE_READY,         /* certificate */
        !           243:    NZTTSTATE_INVALID,         /* certificate */
        !           244:    NZTTSTATE_RENEWAL        /* renewal-requested */
        !           245: };
        !           246: typedef enum nzttState nzttState;
        !           247: 
        !           248: /*
        !           249:  * Cert-version types
        !           250:  * 
        !           251:  * This is used to quickly look-up the cert-type
        !           252:  */
        !           253: enum nzttVersion
        !           254: {
        !           255:    NZTTVERSION_X509v1 = 1,        /* X.509v1 */
        !           256:    NZTTVERSION_X509v3,            /* X.509v3 */
        !           257: #ifdef NZDEPRECATED
        !           258:    NZTTVERSION_SYMMETRIC,         /* Symmetric */
        !           259: #endif
        !           260:    NZTTVERSION_INVALID_TYPE       /* For Initialization */
        !           261: };
        !           262: typedef enum nzttVersion nzttVersion;
        !           263: 
        !           264: /*
        !           265:  * Cipher Types
        !           266:  *
        !           267:  * List of all cryptographic algorithms, some of which may not be
        !           268:  * available.
        !           269:  */
        !           270: enum nzttCipherType 
        !           271: {
        !           272:    NZTTCIPHERTYPE_RSA = 1,          /* RSA public key */
        !           273:    NZTTCIPHERTYPE_DES,              /* DES */
        !           274:    NZTTCIPHERTYPE_RC4,              /* RC4 */
        !           275:    NZTTCIPHERTYPE_MD5DES,           /* DES encrypted MD5 with salt (PBE) */
        !           276:    NZTTCIPHERTYPE_MD5RC2,           /* RC2 encrypted MD5 with salt (PBE) */
        !           277:    NZTTCIPHERTYPE_MD5,              /* MD5 */
        !           278:    NZTTCIPHERTYPE_SHA               /* SHA */
        !           279: };
        !           280: typedef enum nzttCipherType nzttCipherType;
        !           281: 
        !           282: /*
        !           283:  * TDU Formats
        !           284:  *
        !           285:  * List of possible toolkit data unit (TDU) formats.  Depending on the
        !           286:  * function and cipher used some may be not be available.
        !           287:  */
        !           288: enum nztttdufmt
        !           289: {
        !           290:    NZTTTDUFMT_PKCS7 = 1,            /* PKCS7 format */
        !           291:    NZTTTDUFMT_RSAPAD,               /* RSA padded format */
        !           292:    NZTTTDUFMT_ORACLEv1,             /* Oracle v1 format */
        !           293:    NZTTTDUFMT_LAST                  /* Used for array size */
        !           294: };
        !           295: typedef enum nztttdufmt nztttdufmt;
        !           296: 
        !           297: /*
        !           298:  * Validate State
        !           299:  *
        !           300:  * Possible validation states an identity can be in.
        !           301:  */
        !           302: enum nzttValState
        !           303: {
        !           304:    NZTTVALSTATE_NONE = 1,        /* Needs to be validated */
        !           305:    NZTTVALSTATE_GOOD,            /* Validated */
        !           306:    NZTTVALSTATE_REVOKED          /* Failed to validate */
        !           307: };
        !           308: typedef enum nzttValState nzttValState;
        !           309: 
        !           310: /*
        !           311:  * Policy Fields <----NEW (09/14/98)
        !           312:  *
        !           313:  * Policies enforced
        !           314:  */
        !           315: enum nzttPolicy
        !           316: {
        !           317:    NZTTPOLICY_NONE = 0,
        !           318:    NZTTPOLICY_RETRY_1, /* number of retries for decryption = 1 */
        !           319:    NZTTPOLICY_RETRY_2, /* number of retries for decryption = 2 */
        !           320:    NZTTPOLICY_RETRY_3  /* number of retries for decryption = 3 */
        !           321: };
        !           322: typedef enum nzttPolicy nzttPolicy;
        !           323: 
        !           324: /*
        !           325:  * Persona Usage <----NEW (09/14/98)
        !           326:  *
        !           327:  * what a persona will be used for?
        !           328:  */
        !           329: enum nzttUsage
        !           330: {
        !           331:    NZTTUSAGE_NONE = 0,
        !           332:    NZTTUSAGE_SSL  /* persona for SSL usage */
        !           333: };
        !           334: typedef enum nzttUsage nzttUsage;
        !           335: 
        !           336: /*
        !           337:  * Personas and identities have unique id's that are represented with
        !           338:  * 128 bits.
        !           339:  */
        !           340: typedef ub1 nzttID[16];
        !           341: 
        !           342: /*
        !           343:  * Identity Types
        !           344:  *
        !           345:  * List of all Identity types..
        !           346:  */
        !           347: enum nzttIdentType 
        !           348: {
        !           349:    NZTTIDENTITYTYPE_INVALID_TYPE = 0,  
        !           350:    NZTTIDENTITYTYPE_CERTIFICTAE,      
        !           351:    NZTTIDENTITYTYPE_CERT_REQ,      
        !           352:    NZTTIDENTITYTYPE_RENEW_CERT_REQ,      
        !           353:    NZTTIDENTITYTYPE_CLEAR_ETP,      
        !           354:    NZTTIDENTITYTYPE_CLEAR_UTP,      
        !           355:    NZTTIDENTITYTYPE_CLEAR_PTP       
        !           356: };
        !           357: typedef enum nzttIdentType nzttIdentType;
        !           358: 
        !           359: /*
        !           360:  * Timestamp as 32 bit quantity in UTC.
        !           361:  */
        !           362: typedef ub1 nzttTStamp[4];
        !           363: 
        !           364: /*
        !           365:  * Buffer Block
        !           366:  *
        !           367:  * A function that needs to fill (and possibly grow) an output buffer
        !           368:  * uses an output parameter block to describe each buffer.
        !           369:  *
        !           370:  * The flags_nzttBufferBlock member tells the function whether the
        !           371:  * buffer can be grown or not.  If flags_nzttBufferBlock is 0, then
        !           372:  * the buffer will be realloc'ed automatically.  
        !           373:  *
        !           374:  * The buflen_nzttBufferBLock member is set to the length of the
        !           375:  * buffer before the function is called and will be the length of the
        !           376:  * buffer when the function is finished.  If buflen_nzttBufferBlock is
        !           377:  * 0, then the initial pointer stored in pobj_nzttBufferBlock is
        !           378:  * ignored.
        !           379:  *
        !           380:  * The objlen_nzttBufferBlock member is set to the length of the
        !           381:  * object stored in the buffer when the function is finished.  If the
        !           382:  * initial buffer had a non-0 length, then it is possible that the
        !           383:  * object length is shorter than the buffer length.
        !           384:  *
        !           385:  * The pobj_nzttBufferBlock member is a pointer to the output object.
        !           386:  */
        !           387: struct nzttBufferBlock
        !           388: {
        !           389: # define NZT_NO_AUTO_REALLOC     0x1
        !           390: 
        !           391:    uword flags_nzttBufferBlock;     /* Flags */
        !           392:    ub4 buflen_nzttBufferBlock;   /* Total length of buffer */
        !           393:    ub4 usedlen_nzttBufferBlock;  /* Length of used buffer part */
        !           394:    ub1 *buffer_nzttBufferBlock;     /* Pointer to buffer */
        !           395: };
        !           396: typedef struct nzttBufferBlock nzttBufferBlock;
        !           397: 
        !           398: /*
        !           399:  * Wallet.
        !           400:  */
        !           401: struct nzttWallet
        !           402: {
        !           403:    ub1 *ldapName_nzttWallet;              /* user's LDAP Name */
        !           404:    ub4  ldapNamelen_nzttWallet;           /* len of user's LDAP Name */
        !           405:    nzttPolicy securePolicy_nzttWallet;    /* secured-policy of the wallet */
        !           406:    nzttPolicy openPolicy_nzttWallet;      /* open-policy of the wallet */
        !           407:    nzttPersona *persona_nzttWallet;       /* List of personas in wallet */
        !           408:    nzttWalletPrivate *private_nzttWallet; /* Private wallet information */
        !           409: #ifdef NZDEPRECATED
        !           410:    ub4 npersona_nzttWallet;            /* Number of personas */
        !           411: #endif
        !           412: };
        !           413: 
        !           414: /*
        !           415:  * The wallet contains, one or more personas.  A persona always
        !           416:  * contains its private key and its identity.  It may also contain
        !           417:  * other 3rd party identites.  All identities qualified with trust
        !           418:  * where the qualifier can indicate anything from untrusted to trusted
        !           419:  * for specific operations.
        !           420:  */
        !           421: 
        !           422: /*
        !           423:  * Persona
        !           424:  *
        !           425:  * Structure containing information about a persona.
        !           426:  */
        !           427: struct nzttPersona
        !           428: {
        !           429:    ub1 *genericName_nzttPersona;              /* user-friendly persona name  */
        !           430:    ub4  genericNamelen_nzttPersona;           /* persona-name length */
        !           431:    nzttUsage usage_nzttPersona;               /* persona usage; SSL/SET/.. */
        !           432:    nzttState state_nzttPersona;               /* persona state-requested/ready */
        !           433:    nzttPersonaPrivate *private_nzttPersona;   /* Opaque part of persona */
        !           434:    nzttIdentity *mycertreqs_nzttPersona;      /* My cert-requests */
        !           435:    nzttIdentity *mycerts_nzttPersona;         /* My certificates */
        !           436:    nzttIdentity *mytps_nzttPersona;           /* List of trusted identities */
        !           437:    struct nzttPersona *next_nzttPersona;      /* Next persona */
        !           438: #ifdef NZDEPRECATED
        !           439:    ub4 ntps_nzttPersona;                   /* Num of trusted identities */
        !           440: #endif
        !           441: };
        !           442: 
        !           443: /*
        !           444:  * Identity
        !           445:  *
        !           446:  * Structure containing information about an identity.
        !           447:  *
        !           448:  * NOTE
        !           449:  *  -- the next_trustpoint field only applies to trusted identities and
        !           450:  *     has no meaning (i.e. is NULL) for self identities.
        !           451:  */
        !           452: struct nzttIdentity
        !           453: {
        !           454:    text *dn_nzttIdentity;                      /* Alias */
        !           455:    ub4 dnlen_nzttIdentity;                  /* Length of alias */
        !           456:    text *comment_nzttIdentity;                 /* Comment  */
        !           457:    ub4 commentlen_nzttIdentity;             /* Length of comment */
        !           458:    nzttIdentityPrivate *private_nzttIdentity;  /* Opaque part of identity */
        !           459:    nzttIdentity *next_nzttIdentity;            /* next identity in list */
        !           460: };
        !           461: 
        !           462: struct nzttPKCS7ProtInfo
        !           463: {
        !           464:    nzttCipherType mictype_nzttPKCS7ProtInfo;    /* Hash cipher */
        !           465:    nzttCipherType symmtype_nzttPKCS7ProtInfo;   /* Symmetric cipher */
        !           466:    ub4 keylen_nzttPKCS7ProtInfo;             /* Length of key to use */
        !           467: };
        !           468: typedef struct nzttPKCS7ProtInfo nzttPKCS7ProtInfo;
        !           469: 
        !           470: /*
        !           471:  * Protection Information.
        !           472:  *
        !           473:  * Information specific to a type of protection.
        !           474:  */
        !           475: union nzttProtInfo
        !           476: {
        !           477:    nzttPKCS7ProtInfo pkcs7_nzttProtInfo;
        !           478: };
        !           479: typedef union nzttProtInfo nzttProtInfo;
        !           480: 
        !           481: /*
        !           482:  * A description of a persona so that the toolkit can create one.  A
        !           483:  * persona can be symmetric or asymmetric and both contain an
        !           484:  * identity.  The identity for an asymmetric persona will be the
        !           485:  * certificate and the identity for the symmetric persona will be
        !           486:  * descriptive information about the persona.  In either case, an
        !           487:  * identity will have been created before the persona is created.
        !           488:  *
        !           489:  * A persona can be stored separately from the wallet that references
        !           490:  * it.  By default, a persona is stored with the wallet (it inherits
        !           491:  * with WRL used to open the wallet).  If a WRL is specified, then it
        !           492:  * is used to store the actuall persona and the wallet will have a
        !           493:  * reference to it.
        !           494:  */
        !           495: struct nzttPersonaDesc
        !           496: {
        !           497:    ub4 privlen_nzttPersonaDesc;        /* Length of private info (key)*/
        !           498:    ub1 *priv_nzttPersonaDesc;             /* Private information */
        !           499:    ub4 prllen_nzttPersonaDesc;         /* Length of PRL */
        !           500:    text *prl_nzttPersonaDesc;             /* PRL for storage */
        !           501:    ub4 aliaslen_nzttPersonaDesc;       /* Length of alias */
        !           502:    text *alias_nzttPersonaDesc;           /* Alias */
        !           503:    ub4 longlen_nzttPersonaDesc;        /* Length of longer description*/
        !           504:    text *long_nzttPersonaDesc;            /* Longer persona description */
        !           505: };
        !           506: typedef struct nzttPersonaDesc nzttPersonaDesc;
        !           507: 
        !           508: /*
        !           509:  * A description of an identity so that the toolkit can create one.
        !           510:  * Since an identity can be symmetric or asymmetric, the asymmetric
        !           511:  * identity information will not be used when a symmetric identity is
        !           512:  * created.  This means the publen_nzttIdentityDesc and
        !           513:  * pub_nzttIdentityDesc members will not be used when creating a
        !           514:  * symmetric identity.
        !           515:  */
        !           516: struct nzttIdentityDesc
        !           517: {
        !           518:    ub4 publen_nzttIdentityDesc;        /* Length of identity */
        !           519:    ub1 *pub_nzttIdentityDesc;             /* Type specific identity */
        !           520:    ub4 dnlen_nzttIdentityDesc;         /* Length of alias */
        !           521:    text *dn_nzttIdentityDesc;             /* Alias */
        !           522:    ub4 longlen_nzttIdentityDesc;       /* Length of longer description */
        !           523:    text *long_nzttIdentityDesc;           /* Longer description */
        !           524:    ub4 quallen_nzttIdentityDesc;       /* Length of trust qualifier */
        !           525:    text *trustqual_nzttIdentityDesc;      /* Trust qualifier */
        !           526: };
        !           527: typedef struct nzttIdentityDesc nzttIdentityDesc;
        !           528: 
        !           529: /********************************/
        !           530: /* PUBLIC FUNCTION DECLARATIONS */
        !           531: /********************************/
        !           532: 
        !           533: /*---------------------- nztwOpenWallet ----------------------*/
        !           534: 
        !           535: /*
        !           536:  * NAME
        !           537:  *    nztwOpenWallet - Open a wallet based on a wallet Resource Locator (WRL).
        !           538:  * 
        !           539:  * PARAMETERS
        !           540:  *    osscntxt {IN}     OSS context. 
        !           541:  *    wrllen   {IN}     Length of WRL.
        !           542:  *    wrl      {IN}     WRL.
        !           543:  *    pwdlen   {IN}     Length of password.
        !           544:  *    pwd      {IN}     Password.
        !           545:  *    wallet   {IN/OUT} Initialized wallet structure.   
        !           546:  * 
        !           547:  * NOTES
        !           548:  *    The syntax for a WRL is <Wallet Type>:<Wallet Type Parameters>.
        !           549:  *
        !           550:  *    Wallet Type       Wallet Type Parameters.
        !           551:  *    -----------       ----------------------
        !           552:  *    File              Pathname (e.g. "file:/home/asriniva")
        !           553:  *    Oracle            Connect string (e.g. "oracle:scott/tiger@oss")
        !           554:  *
        !           555:  *    There are also defaults.  If the WRL is NZT_DEFAULT_WRL, then
        !           556:  *    the platform specific WRL default is used.  If only the wallet
        !           557:  *    type is specified, then the WRL type specific default is used
        !           558:  *    (e.g. "oracle:")
        !           559:  *
        !           560:  *    There is an implication with Oracle that should be stated: An
        !           561:  *    Oracle based wallet can be implemented in a user's private space
        !           562:  *    or in world readable space.
        !           563:  *
        !           564:  *    When the wallet is opened, the password is verified by hashing
        !           565:  *    it and comparing against the password hash stored with the
        !           566:  *    wallet.  The list of personas (and their associated identities)
        !           567:  *    is built and stored into the wallet structure.
        !           568:  *    
        !           569:  * RETURNS
        !           570:  *    NZERROR_OK           Success.
        !           571:  *    NZERROR_RIO_OPEN     RIO could not open wallet (see network trace file).
        !           572:  *    NZERROR_TK_PASSWORD  Password verification failed.
        !           573:  *    NZERROR_TK_WRLTYPE   WRL type is not known.
        !           574:  *    NZERROR_TK_WRLPARM   WRL parm does not match type.
        !           575:  */
        !           576: #ifdef __STDC__
        !           577: nzerror nztwOpenWallet(nzctx *, ub4, text *, ub4, text *, 
        !           578:                            nzttWallet *);
        !           579: #else
        !           580: nzerror nztwOpenWallet(/*_ nzctx *, ub4, text *, ub4, text *, 
        !           581:                            nzttWallet * _*/);
        !           582: #endif /* __STDC __*/
        !           583: 
        !           584: /*---------------------- nztwCloseWallet ----------------------*/
        !           585: 
        !           586: /*
        !           587:  * NAME
        !           588:  *    nztwCloseWallet - Close a wallet
        !           589:  * 
        !           590:  * PARAMETERS
        !           591:  *    osscntxt {IN}     OSS context.
        !           592:  *    wallet   {IN/OUT} Wallet.
        !           593:  * 
        !           594:  * NOTES
        !           595:  *    Closing a wallet also closes all personas associated with that
        !           596:  *    wallet.  It does not cause a persona to automatically be saved
        !           597:  *    if it has changed.  The implication is that a persona can be
        !           598:  *    modified by an application but if it is not explicitly saved it
        !           599:  *    reverts back to what was in the wallet.
        !           600:  *
        !           601:  * RETURNS
        !           602:  *    NZERROR_OK           Success.
        !           603:  *    NZERROR_RIO_CLOSE    RIO could not close wallet (see network trace file).
        !           604:  */
        !           605: #ifdef __STDC__
        !           606: nzerror nztwCloseWallet(nzctx *, nzttWallet *);
        !           607: #else
        !           608: nzerror nztwCloseWallet(/*_ nzctx *, nzttWallet * _*/);
        !           609: #endif /* __STDC__ */
        !           610: 
        !           611: /*------------------------ nztwConstructWallet -----------------------*/
        !           612: /*
        !           613:  * 
        !           614:  * nzerror nztwConstructWallet( nzctx *oss_context,    
        !           615:  *                               nzttPolicy openPolicy,
        !           616:  *                               nzttPolicy securePolicy,
        !           617:  *                               ub1 *ldapName,
        !           618:  *                               ub4 ldapNamelen,
        !           619:  *                               nzstrc *wrl,
        !           620:  *                               nzttPersona *personas,
        !           621:  *                               nzttWallet **wallet );
        !           622:  */
        !           623: 
        !           624: /*---------------------- nztwRetrievePersonaCopy ----------------------*/
        !           625: 
        !           626: /*
        !           627:  * NAME
        !           628:  *    nztwRetrievePersonaCopy - Retrieves a persona based from wallet
        !           629:  * 
        !           630:  * PARAMETERS
        !           631:  *    osscntxt {IN}     OSS context. 
        !           632:  *    wallet   {IN}     Wallet.
        !           633:  *    index    {IN}     Which wallet index to remove (first persona is zero).
        !           634:  *    persona  {OUT}    Persona found.
        !           635:  * 
        !           636:  * NOTES
        !           637:  *    Retrieves a persona from the wallet based on the index number passed
        !           638:  *    in.  This persona is a COPY of the one stored in the wallet, therefore
        !           639:  *    it is perfectly fine for the wallet to be closed after this call is 
        !           640:  *    made.
        !           641:  *
        !           642:  *    The caller is responsible for disposing of the persona when completed.
        !           643:  *
        !           644:  * RETURNS
        !           645:  *    NZERROR_OK           Success.
        !           646:  */
        !           647: #ifdef __STDC__
        !           648: nzerror nztwRetrievePersonaCopy(nzctx *, nzttWallet *, ub4, nzttPersona **);
        !           649: #else
        !           650: nzerror nztwRetrievePersonaCopy(/*_ nzctx *, nzttWallet *, ub4, 
        !           651:                            nzttPersona ** _*/);
        !           652: #endif /* __STDC __*/
        !           653: 
        !           654: 
        !           655: /*---------------------- nzteOpenPersona ----------------------*/
        !           656: 
        !           657: /*
        !           658:  * NAME
        !           659:  *    nzteOpenPersona - Open a persona.
        !           660:  * 
        !           661:  * PARAMETERS
        !           662:  *    osscntxt {IN}     OSS context. 
        !           663:  *    persona  {IN/OUT} Persona.
        !           664:  * 
        !           665:  * NOTES
        !           666:  *    
        !           667:  * RETURNS
        !           668:  *    NZERROR_OK           Success.
        !           669:  *    NZERROR_TK_PASSWORD  Password failed to decrypt persona.
        !           670:  *    NZERROR_TK_BADPRL    Persona resource locator did not work.
        !           671:  *    NZERROR_RIO_OPEN     Could not open persona (see network trace file).
        !           672:  */
        !           673: #ifdef __STDC__
        !           674: nzerror nzteOpenPersona(nzctx *, nzttPersona *);
        !           675: #else
        !           676: nzerror nzteOpenPersona(/*_ nzctx *, nzttPersona * _*/);
        !           677: #endif /* __STDC __*/
        !           678: 
        !           679: /*--------------------- nzteClosePersona ---------------------*/
        !           680: 
        !           681: /*
        !           682:  * NAME
        !           683:  *    nzteClosePersona - Close a persona.
        !           684:  * 
        !           685:  * PARAMETERS
        !           686:  *    osscntxt {IN}     OSS context.
        !           687:  *    persona  {IN/OUT} Persona.
        !           688:  * 
        !           689:  * NOTES
        !           690:  *    Closing a persona does not store the persona, it simply releases
        !           691:  *    the memory associated with the crypto engine.
        !           692:  *    
        !           693:  * RETURNS
        !           694:  *    NZERROR_OK        Success.
        !           695:  */
        !           696: #ifdef __STDC__
        !           697: nzerror nzteClosePersona(nzctx *, nzttPersona *);
        !           698: #else
        !           699: nzerror nzteClosePersona(/*_ nzctx *, nzttPersona * _*/);
        !           700: #endif /* __STDC __*/
        !           701: 
        !           702: /*--------------------- nzteDestroyPersona ---------------------*/
        !           703: 
        !           704: /*
        !           705:  * NAME
        !           706:  *    nzteDestroyPersona - Destroy a persona.
        !           707:  * 
        !           708:  * PARAMETERS
        !           709:  *    osscntxt {IN}        OSS context.
        !           710:  *    persona  {IN/OUT}    Persona.
        !           711:  * 
        !           712:  * NOTES
        !           713:  *    The persona is destroyd in the open state, but it will
        !           714:  *    not be associated with a wallet.
        !           715:  *    
        !           716:  *    The persona parameter is doubly indirect so that at the
        !           717:  *    conclusion of the function, the pointer can be set to NULL.
        !           718:  *
        !           719:  *
        !           720:  * RETURNS
        !           721:  *    NZERROR_OK        Success.
        !           722:  *    NZERROR_TK_TYPE   Unsupported itype/ctype combination.
        !           723:  *    NZERROR_TK_PARMS  Error in persona description.
        !           724:  */
        !           725: #ifdef __STDC__
        !           726: nzerror nzteDestroyPersona(nzctx *,  nzttPersona **);
        !           727: #else
        !           728: nzerror nzteDestroyPersona(/*_ nzctx *, nzttPersona ** _*/);
        !           729: #endif /* __STDC __*/
        !           730: 
        !           731: /*---------------------- nzteRetrieveTrustedIdentCopy ----------------------*/
        !           732: 
        !           733: /*
        !           734:  * NAME
        !           735:  *    nzteRetrieveTrustedIdentCopy - Retrieves a trusted identity from persona
        !           736:  * 
        !           737:  * PARAMETERS
        !           738:  *    osscntxt {IN}     OSS context. 
        !           739:  *    persona  {IN}     Persona.
        !           740:  *    index    {IN}     Which wallet index to remove (first element is zero).
        !           741:  *    identity {OUT}    Trusted Identity from this persona.
        !           742:  * 
        !           743:  * NOTES
        !           744:  *    Retrieves a trusted identity from the persona based on the index 
        !           745:  *    number passed in.  This identity is a COPY of the one stored in 
        !           746:  *    the persona, therefore it is perfectly fine to close the persona
        !           747:  *    after this call is made.
        !           748:  *
        !           749:  *    The caller is responsible for freeing the memory of this object 
        !           750:  *    by calling nztiAbortIdentity it is no longer needed
        !           751:  *
        !           752:  * RETURNS
        !           753:  *    NZERROR_OK           Success.
        !           754:  */
        !           755: #ifdef __STDC__
        !           756: nzerror nzteRetrieveTrustedIdentCopy(nzctx *, nzttPersona *, ub4, 
        !           757:                                     nzttIdentity **);
        !           758: #else
        !           759: nzerror nzteRetrieveTrustedIdentCopy(/*_ nzctx *, nzttPersona *, ub4, 
        !           760:                            nzttIdentity ** _*/);
        !           761: #endif /* __STDC __*/
        !           762: 
        !           763: /*--------------------- nztePriKey ---------------------*/
        !           764: 
        !           765: /*
        !           766:  * NAME
        !           767:  *    nztePriKey - Get the decrypted Private Key for the Persona
        !           768:  * 
        !           769:  * PARAMETERS
        !           770:  *    osscntxt {IN}     OSS context.
        !           771:  *    persona  {IN}     Persona.
        !           772:  *    vkey     {OUT}    Private Key [B_KEY_OBJ]
        !           773:  *    vkey_len {OUT}    Private Key Length
        !           774:  * 
        !           775:  * NOTES
        !           776:  *    This funiction will only work for X.509 based persona which contain
        !           777:  *    a private key.  
        !           778:  *    A copy of the private key is returned to the caller so that they do not 
        !           779:  *    have to worry about the key changeing "underneath them".
        !           780:  *    Memory will be allocated for the vkey and therefore, the CALLER
        !           781:  *    will be responsible for freeing this memory.
        !           782:  *
        !           783:  * RETURNS
        !           784:  *    NZERROR_OK           Success.
        !           785:  *    NZERROR_NO_MEMORY    ossctx is null.
        !           786:  *    NZERROR_TK_BADPRL    Persona resource locator did not work.
        !           787:  */
        !           788: #ifdef __STDC__
        !           789: nzerror nztePriKey(nzctx *, nzttPersona *, ub1 **, ub4 *);
        !           790: #else
        !           791: nzerror nztePriKey(/*_ nzctx *, nzttPersona *, ub1 **, ub4 * _*/);
        !           792: #endif /* __STDC __*/
        !           793: 
        !           794: /*--------------------- nzteMyCert ---------------------*/
        !           795: 
        !           796: /*
        !           797:  * NAME
        !           798:  *    nzteMyCert - Get the X.509 Certificate for a persona
        !           799:  * 
        !           800:  * PARAMETERS
        !           801:  *    osscntxt {IN}     OSS context.
        !           802:  *    persona  {IN}     Persona.
        !           803:  *    cert     {OUT}    X.509 Certificate [BER encoded]
        !           804:  *    cert_len {OUT}    Certificate length
        !           805:  * 
        !           806:  * NOTES
        !           807:  *    This funiction will only work for X.509 based persona which contain
        !           808:  *    a certificate for the self identity. 
        !           809:  *    A copy of the certificate is returned to the caller so that they do not 
        !           810:  *    have to worry about the certificate changeing "underneath them".
        !           811:  *    Memory will be allocated for the cert and therefore, the CALLER
        !           812:  *    will be responsible for freeing this memory.
        !           813:  *
        !           814:  * RETURNS
        !           815:  *    NZERROR_OK           Success.
        !           816:  *    NZERROR_NO_MEMORY    ossctx is null.
        !           817:  */
        !           818: #ifdef __STDC__
        !           819: nzerror nzteMyCert(nzctx *, nzttPersona *, ub1 **, ub4 *);
        !           820: #else
        !           821: nzerror nzteMyCert(/*_ nzctx *, nzttPersona *, ub1 **, ub4 * _*/);
        !           822: #endif /* __STDC __*/
        !           823: 
        !           824: /*--------------------- nzteX509CreatePersona ---------------------*/
        !           825: 
        !           826: /*
        !           827:  * NAME
        !           828:  *    nzteX509CreatePersona - Given a BER X.509 cert, create a persona
        !           829:  * 
        !           830:  * PARAMETERS
        !           831:  *    osscntxt {IN}     OSS context.
        !           832:  *    cert     {IN}     X.509 Certificate [BER encoded]
        !           833:  *    cert_len {IN}     Certificate length
        !           834:  *    persona  {OUT}    Persona.
        !           835:  * 
        !           836:  * NOTES
        !           837:  *    Memory will be allocated for the persona and therefore, the CALLER
        !           838:  *    will be responsible for freeing this memory.
        !           839:  *
        !           840:  * RETURNS
        !           841:  *    NZERROR_OK           Success.
        !           842:  *    NZERROR_NO_MEMORY    ossctx is null.
        !           843:  */
        !           844: #ifdef __STDC__
        !           845: nzerror nzteX509CreatePersona(nzctx *, ub1 *, ub4, nzttPersona **);
        !           846: #else
        !           847: nzerror nzteX509CreatePersona(/*_ nzctx *, ub1 *, ub4, nzttPersona ** _*/);
        !           848: #endif /* __STDC __*/
        !           849: 
        !           850: /*-------------------- nztiCreateIdentity --------------------*/
        !           851: 
        !           852: /*
        !           853:  * NAME
        !           854:  *    nztiCreateIdentity - Create an identity.
        !           855:  * 
        !           856:  * PARAMETERS
        !           857:  *    osscntxt {IN}     OSS context.
        !           858:  *    itype    {IN}     Identity type.
        !           859:  *    desc     {IN}     Description of identity.
        !           860:  *    identity {IN/OUT} Identity.
        !           861:  * 
        !           862:  * NOTES
        !           863:  *    Memory is only allocated for the identity structure.  The elements in
        !           864:  *    the description struct are not copied.  Rather their pointers are copied
        !           865:  *    into the identity structure.  Therefore, the caller should not free
        !           866:  *    the elements referenced by the desc.  These elements will be freed
        !           867:  *    when the nztiDestroyIdentity is called.
        !           868:  *    
        !           869:  * RETURNS
        !           870:  *    NZERROR_OK        Success.
        !           871:  *    NZERROR_PARMS     Error in description.
        !           872:  */
        !           873: #ifdef __STDC__
        !           874: nzerror nztiCreateIdentity(nzctx *, nzttVersion, nzttIdentityDesc *,
        !           875:                                nzttIdentity **);
        !           876: #else
        !           877: nzerror nztiCreateIdentity(/*_ nzctx *, nzttVersion, nzttIdentityDesc *,
        !           878:                                nzttIdentity ** _*/);
        !           879: #endif /* __STDC __*/
        !           880: 
        !           881: #ifdef NZ_OLD_TOOLS
        !           882: /*-------------------- nztiDuplicateIdentity --------------------*/
        !           883: 
        !           884: /*
        !           885:  * NAME
        !           886:  *    nztiDuplicateIdentity - Duplicate an identity.
        !           887:  * 
        !           888:  * PARAMETERS
        !           889:  *    osscntxt     {IN}     OSS context.
        !           890:  *    identity     {IN}     Target Identity.
        !           891:  *    new_identity {IN}     New Identity.
        !           892:  * 
        !           893:  * NOTES
        !           894:  *    Memory for the identity is allocated inside the function, and all
        !           895:  *    internal identity elements as well.
        !           896:  *    
        !           897:  * RETURNS
        !           898:  *    NZERROR_OK        Success.
        !           899:  *    NZERROR_TK_NOTFOUND  Identity not found.
        !           900:  *    NZERROR_PARMS     Error in description.
        !           901:  */
        !           902: #ifdef __STDC__
        !           903: nzerror nztiDuplicateIdentity(nzctx *, nzttIdentity *, 
        !           904:                               nzttIdentity **);
        !           905: #else
        !           906: nzerror nztiDuplicateIdentity(/*_ nzctx *, nzttIdentity *, 
        !           907:                               nzttIdentity ** _*/);
        !           908: #endif /* __STDC __*/
        !           909: #endif /* NZ_OLD_TOOLS */
        !           910: 
        !           911: /*--------------------- nztiAbortIdentity ---------------------*/
        !           912: 
        !           913: /*
        !           914:  * NAME
        !           915:  *    nztiAbortIdentity - Abort an unassociated identity.
        !           916:  * 
        !           917:  * PARAMETERS
        !           918:  *    osscntxt {IN}     OSS context.
        !           919:  *    identity {IN/OUT} Identity.
        !           920:  * 
        !           921:  * NOTES
        !           922:  *    It is an error to try to abort an identity that can be
        !           923:  *    referenced through a persona.
        !           924:  *    
        !           925:  *    The identity pointer is set to NULL at the conclusion.
        !           926:  * 
        !           927:  * RETURNS
        !           928:  *    NZERROR_OK           Success.
        !           929:  *    NZERROR_CANTABORT    Identity is associated with persona.
        !           930:  */
        !           931: #ifdef __STDC__
        !           932: nzerror nztiAbortIdentity(nzctx *, nzttIdentity **);
        !           933: #else
        !           934: nzerror nztiAbortIdentity(/*_ nzctx *, nzttIdentity ** _*/);
        !           935: #endif /* __STDC __*/
        !           936: 
        !           937: #ifdef NZ_OLD_TOOLS
        !           938: /*----------------- nztidGetIdentityDesc -----------------*/
        !           939: 
        !           940: /*
        !           941:  * NAME
        !           942:  *    nztidGetIdentityDesc - Gets an Identity Description from the identity
        !           943:  * 
        !           944:  * PARAMETERS
        !           945:  *    osscntxt    {IN}     Success.
        !           946:  *    identity    {IN}     Identity.
        !           947:  *    description {IN/OUT} Identity Description.
        !           948:  * 
        !           949:  * NOTES
        !           950:  *    Memory is allocated for the Identity Description. It
        !           951:  *    is the callers responsibility to free this memory by calling 
        !           952:  *    nztiFreeIdentityDesc.
        !           953:  *
        !           954:  * RETURNS
        !           955:  *    NZERROR_OK     Success.
        !           956:  */
        !           957: #ifdef __STDC__
        !           958: nzerror nztidGetIdentityDesc(nzctx *, nzttIdentity *, 
        !           959:                              nzttIdentityDesc **);
        !           960: #else
        !           961: nzerror nztidGetIdentityDesc(/*_ nzctx *, nzttIdentity *,
        !           962:                                      nzttIdentityDesc ** _*/);
        !           963: #endif /* __STDC __*/
        !           964: 
        !           965: /*----------------- nztidFreeIdentityDesc -----------------*/
        !           966: 
        !           967: /*
        !           968:  * NAME
        !           969:  *    nztidFreeIdentityDesc - Frees memory for Identity Desc object.
        !           970:  * 
        !           971:  * PARAMETERS
        !           972:  *    osscntxt    {IN}     oss context.
        !           973:  *    description {IN/OUT} Identity Description.
        !           974:  * 
        !           975:  * NOTES
        !           976:  *    Memory is freed for all Identity description elements.  Pointer is 
        !           977:  *    then set to null.
        !           978:  *
        !           979:  * RETURNS
        !           980:  *    NZERROR_OK     Success.
        !           981:  */
        !           982: #ifdef __STDC__
        !           983: nzerror nztidFreeIdentityDesc(nzctx *, nzttIdentityDesc **);
        !           984: #else
        !           985: nzerror nztidFreeIdentityDesc(/*_ nzctx *, nzttIdentityDesc ** _*/);
        !           986: #endif /* __STDC __*/
        !           987: #endif /* NZ_OLD_TOOLS */
        !           988: 
        !           989: /*---------------- nztific_FreeIdentityContent ----------------*/
        !           990: 
        !           991: /*
        !           992:  * NAME
        !           993:  *     nztific_FreeIdentityContent - free the contents of an identity.
        !           994:  * 
        !           995:  * PARAMETERS
        !           996:  *    osscntxt         {IN}     OSS context.
        !           997:  *    identity         {IN/OUT} freed identity
        !           998:  * 
        !           999:  * NOTES
        !          1000:  *    Free a created identity.
        !          1001:  *
        !          1002:  * RETURNS
        !          1003:  *    NZERROR_OK     Success.
        !          1004:  */
        !          1005: /*
        !          1006:  * Free the identity content.
        !          1007:  */
        !          1008: #ifdef __STDC__
        !          1009: nzerror nztific_FreeIdentityContent(nzctx *ossctx,
        !          1010:                                         nzttIdentity *identity);
        !          1011: #else
        !          1012: nzerror nztific_FreeIdentityContent(/*_ nzctx *ossctx,
        !          1013:                                         nzttIdentity *identity _*/);
        !          1014: #endif /* __STDC __*/
        !          1015: 
        !          1016: 
        !          1017: /*-------------------------- nztSign --------------------------*/
        !          1018: 
        !          1019: /*
        !          1020:  * NAME
        !          1021:  *    nztSign - Create an attached signature.
        !          1022:  * 
        !          1023:  * PARAMETERS
        !          1024:  *    osscntxt {IN}     OSS context.
        !          1025:  *    persona  {IN}     Open persona acting as signer.
        !          1026:  *    state    {IN}     State of signature.
        !          1027:  *    inlen    {IN}     Length of this input part.
        !          1028:  *    in       {IN}     This input part.
        !          1029:  *    tdubuf   {IN/OUT} TDU buffer.
        !          1030:  * 
        !          1031:  * NOTES
        !          1032:  *    
        !          1033:  * RETURNS
        !          1034:  *    NZERROR_OK           Success.
        !          1035:  *    NZERROR_TK_CANTGROW  Needed to grow output buffer but could not.
        !          1036:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          1037:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          1038:  */
        !          1039: #ifdef __STDC__
        !          1040: nzerror nztSign(nzctx *, nzttPersona *, nzttces, ub4, ub1 *,
        !          1041:                     nzttBufferBlock *);
        !          1042: #else
        !          1043: nzerror nztSign(/*_ nzctx *, nzttPersona *, nzttces, ub4, ub1 *,
        !          1044:                     nzttBufferBlock * _*/);
        !          1045: #endif /* __STDC __*/
        !          1046: 
        !          1047: /*------------------------- nztVerify -------------------------*/
        !          1048: 
        !          1049: /*
        !          1050:  * NAME
        !          1051:  *    nztVerify - Verify an attached signature.
        !          1052:  * 
        !          1053:  * PARAMETERS
        !          1054:  *    osscntxt {IN}     OSS context.
        !          1055:  *    persona  {IN}     Persona.
        !          1056:  *    state    {IN}     State of verification.
        !          1057:  *    intdulen {IN}     TDU length.
        !          1058:  *    intdu    {IN}     TDU.
        !          1059:  *    out      {IN/OUT} Extracted message.
        !          1060:  *    verified {OUT}    TRUE if signature verified.
        !          1061:  *    validated{OUT}    TRUE if signing identity validated.
        !          1062:  *    identity {OUT} Identity of signing party.
        !          1063:  * 
        !          1064:  * NOTES
        !          1065:  *    
        !          1066:  * RETURNS
        !          1067:  *    NZERROR_OK           Success.
        !          1068:  *    NZERROR_TK_CANTGROW  Needed to grow outptu buffer but could not.
        !          1069:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          1070:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          1071:  */
        !          1072: #ifdef __STDC__
        !          1073: nzerror nztVerify(nzctx *, nzttPersona *, nzttces, ub4, ub1 *,
        !          1074:                       nzttBufferBlock *, boolean *, boolean *,
        !          1075:                       nzttIdentity **);
        !          1076: #else
        !          1077: nzerror nztVerify(/*_ nzctx *, nzttPersona *, nzttces, ub4, ub1 *,
        !          1078:                       nzttBufferBlock *, boolean *, boolean *,
        !          1079:                       nzttIdentity ** _*/);
        !          1080: #endif /* __STDC __*/
        !          1081: 
        !          1082: /*------------------------ nztValidate ------------------------*/
        !          1083: 
        !          1084: /*
        !          1085:  * NAME
        !          1086:  *    nztValidate - Validate an identity.
        !          1087:  * 
        !          1088:  * PARAMETERS
        !          1089:  *    osscntxt {IN}  OSS context.
        !          1090:  *    persona  {IN}  Persona.
        !          1091:  *    identity {IN}  Identity.
        !          1092:  *    validated{OUT} TRUE if identity was validated.  
        !          1093:  * 
        !          1094:  * NOTES
        !          1095:  *    
        !          1096:  * RETURNS
        !          1097:  *    NZERROR_OK           Success.
        !          1098:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          1099:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          1100:  */
        !          1101: #ifdef __STDC__
        !          1102: nzerror nztValidate(nzctx *, nzttPersona *, nzttIdentity *, boolean *);
        !          1103: #else
        !          1104: nzerror nztValidate(/*_ nzctx *, nzttPersona *, nzttIdentity *, boolean * _*/);
        !          1105: #endif /* __STDC __*/
        !          1106: 
        !          1107: /*-------------------- nztsd_SignDetached --------------------*/
        !          1108: 
        !          1109: /*
        !          1110:  * NAME
        !          1111:  *    nztsd_SignDetached - Generate a detached signature.
        !          1112:  * 
        !          1113:  * PARAMETERS
        !          1114:  *    osscntxt {IN}     OSS context.
        !          1115:  *    persona  {IN}     Persona.
        !          1116:  *    state    {IN}     State of signature.
        !          1117:  *    inlen    {IN}     Length of this input part.
        !          1118:  *    in       {IN}     This input part.
        !          1119:  *    tdubuf   {IN/OUT} TDU buffer.
        !          1120:  * 
        !          1121:  * NOTES
        !          1122:  *    
        !          1123:  * RETURNS
        !          1124:  *    NZERROR_OK           Success.
        !          1125:  *    NZERROR_TK_CANTGROW  Needed to grow output buffer but could not.
        !          1126:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          1127:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          1128:  */
        !          1129: #ifdef __STDC__
        !          1130: nzerror nztsd_SignDetached(nzctx *, nzttPersona *, nzttces, ub4, ub1 *, 
        !          1131:                                nzttBufferBlock *);
        !          1132: #else
        !          1133: nzerror nztsd_SignDetached(/*_ nzctx *, nzttPersona *, nzttces, ub4, ub1 *, 
        !          1134:                                nzttBufferBlock * _*/);
        !          1135: #endif /* __STDC __*/
        !          1136: 
        !          1137: /*------------------- nztved_VerifyDetached -------------------*/
        !          1138: 
        !          1139: /*
        !          1140:  * NAME
        !          1141:  *    nztved_VerifyDetached - Verify a detached signature.
        !          1142:  * 
        !          1143:  * PARAMETERS
        !          1144:  *    osscntxt {IN}     OSS context.
        !          1145:  *    persona  {IN}     Persona.
        !          1146:  *    state    {IN}     State of verification.
        !          1147:  *    inlen    {IN}     Length of data.
        !          1148:  *    in       {IN}     Data.
        !          1149:  *    intdulen {IN}     Input TDU length.
        !          1150:  *    tdu      {IN}     Input TDU.
        !          1151:  *    verified {OUT}    TRUE if signature verified.
        !          1152:  *    validated{OUT}    TRUE if signing identity validated.
        !          1153:  *    identity {OUT} Identity of signing party.
        !          1154:  * 
        !          1155:  * NOTES
        !          1156:  *    
        !          1157:  * RETURNS
        !          1158:  *    NZERROR_OK           Success.
        !          1159:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          1160:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          1161:  */
        !          1162: #ifdef __STDC__
        !          1163: nzerror nztved_VerifyDetached(nzctx *, nzttPersona *, nzttces, ub4, 
        !          1164:                                   ub1 *, ub4, ub1 *, boolean *, boolean *, 
        !          1165:                                   nzttIdentity **);
        !          1166: #else
        !          1167: nzerror nztved_VerifyDetached(/*_ nzctx *, nzttPersona *, nzttces, ub4, 
        !          1168:                                   ub1 *, ub4, ub1 *, boolean *, boolean *, 
        !          1169:                                   nzttIdentity ** _*/);
        !          1170: #endif /* __STDC __*/
        !          1171: 
        !          1172: /*--------------------- nztkec_PKEncrypt ---------------------*/
        !          1173: 
        !          1174: /*
        !          1175:  * NAME
        !          1176:  *    nztkec_PKEncrypt - Encrypt data symmetrically, encrypt key asymmetrically
        !          1177:  * 
        !          1178:  * PARAMETERS
        !          1179:  *    osscntxt    {IN}     OSS context.
        !          1180:  *    persona     {IN}     Persona.
        !          1181:  *    nrecipients {IN}     Number of recipients for this encryption.
        !          1182:  *    recipients  {IN}     List of recipients.
        !          1183:  *    state       {IN}     State of encryption.
        !          1184:  *    inlen       {IN}     Length of this input part.
        !          1185:  *    in          {IN}     This input part.
        !          1186:  *    tdubuf      {IN/OUT} TDU buffer.
        !          1187:  * 
        !          1188:  * NOTES
        !          1189:  *    There is a limitation of 1 recipient (nrecipients = 1) at this
        !          1190:  *    time.
        !          1191:  *    
        !          1192:  * RETURNS
        !          1193:  *    NZERROR_OK           Success.
        !          1194:  *    NZERROR_TK_CANTGROW  Needed to grow output buffer but could not.
        !          1195:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          1196:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          1197:  */
        !          1198: #ifdef __STDC__
        !          1199: nzerror nztkec_PKEncrypt(nzctx *, nzttPersona *, ub4, nzttIdentity *, 
        !          1200:                              nzttces, ub4, ub1 *, nzttBufferBlock *);
        !          1201: #else
        !          1202: nzerror nztkec_PKEncrypt(/*_ nzctx *, nzttPersona *, ub4, nzttIdentity *, 
        !          1203:                              nzttces, ub4, ub1 *, nzttBufferBlock * _*/);
        !          1204: #endif /* __STDC __*/
        !          1205: 
        !          1206: /*---------------- nztxkec_PKEncryptExpansion ----------------*/
        !          1207: 
        !          1208: /*
        !          1209:  * NAME
        !          1210:  *    nztxkec_PKEncryptExpansion - Determine the buffer needed for PKEncrypt
        !          1211:  * 
        !          1212:  * PARAMETERS
        !          1213:  *    osscntxt    {IN}     OSS context. 
        !          1214:  *    persona     {IN}     Persona.
        !          1215:  *    nrecipients {IN}     Number of recipients.
        !          1216:  *    inlen       {IN}     Length of input.
        !          1217:  *    tdulen      {out}    Length of buffer need.
        !          1218:  * 
        !          1219:  * NOTES
        !          1220:  *    
        !          1221:  * RETURNS
        !          1222:  *    NZERROR_OK           Success.
        !          1223:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          1224:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          1225:  */
        !          1226: #ifdef __STDC__
        !          1227: nzerror nztxkec_PKEncryptExpansion(nzctx *, nzttPersona *, ub4, ub4,
        !          1228:                                        ub4 *);
        !          1229: #else
        !          1230: nzerror nztxkec_PKEncryptExpansion(/*_ nzctx *, nzttPersona *, ub4, ub4,
        !          1231:                                        ub4 * _*/);
        !          1232: #endif /* __STDC __*/
        !          1233: 
        !          1234: /*--------------------- nztkdc_PKDecrypt ---------------------*/
        !          1235: 
        !          1236: /*
        !          1237:  * NAME
        !          1238:  *    nztkdc_PKDecrypt - Decrypt a PKEncrypted message.
        !          1239:  * 
        !          1240:  * PARAMETERS
        !          1241:  *    osscntxt    {IN}     OSS context.
        !          1242:  *    persona     {IN}     Persona.
        !          1243:  *    state       {IN}     State of encryption.
        !          1244:  *    inlen       {IN}     Length of this input part.
        !          1245:  *    in          {IN}     This input part.
        !          1246:  *    tdubuf      {IN/OUT} TDU buffer.
        !          1247:  * 
        !          1248:  * NOTES
        !          1249:  *    
        !          1250:  * RETURNS
        !          1251:  *    NZERROR_OK           Success.
        !          1252:  *    NZERROR_TK_CANTGROW  Needed to grow output buffer but could not.
        !          1253:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          1254:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          1255:  */
        !          1256: #ifdef __STDC__
        !          1257: nzerror nztkdc_PKDecrypt(nzctx *, nzttPersona *, nzttces, ub4, ub1 *,
        !          1258:                              nzttBufferBlock *);
        !          1259: #else
        !          1260: nzerror nztkdc_PKDecrypt(/*_ nzctx *, nzttPersona *, nzttces, ub4, ub1 *,
        !          1261:                              nzttBufferBlock * _*/);
        !          1262: #endif /* __STDC __*/
        !          1263: 
        !          1264: /*-------------------------- nztHash --------------------------*/
        !          1265: 
        !          1266: /*
        !          1267:  * NAME
        !          1268:  *    nztHash - Generate a hash.
        !          1269:  * 
        !          1270:  * PARAMETERS
        !          1271:  *    osscntxt {IN}     OSS context.
        !          1272:  *    persona  {IN}     Persona.
        !          1273:  *    state    {IN}     State of hash.
        !          1274:  *    inlen    {IN}     Length of this input.
        !          1275:  *    in       {IN}     This input.
        !          1276:  *    tdu      {IN/OUT} Output tdu.
        !          1277:  * 
        !          1278:  * NOTES
        !          1279:  *    
        !          1280:  * RETURNS
        !          1281:  *    NZERROR_OK           Success.
        !          1282:  *    NZERROR_TK_CANTGROW  Needed to grow TDU buffer but could not.
        !          1283:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          1284:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          1285:  */
        !          1286: #ifdef __STDC__
        !          1287: nzerror nztHash(nzctx *, nzttPersona *, nzttces, ub4, ub1 *,
        !          1288:                     nzttBufferBlock *);
        !          1289: #else
        !          1290: nzerror nztHash(/*_ nzctx *, nzttPersona *, nzttces, ub4, ub1 *,
        !          1291:                     nzttBufferBlock * _*/);
        !          1292: #endif /* __STDC __*/
        !          1293: 
        !          1294: /*----------------------- nztSeedRandom -----------------------*/
        !          1295: 
        !          1296: /*
        !          1297:  * NAME
        !          1298:  *    nztSeedRandom - Seed the random function
        !          1299:  * 
        !          1300:  * PARAMETERS
        !          1301:  *    osscntxt {IN}  OSS context.
        !          1302:  *    persona  {IN}  Persona.
        !          1303:  *    seedlen  {IN}  Length of seed.
        !          1304:  *    seed     {IN}  Seed.
        !          1305:  * 
        !          1306:  * NOTES
        !          1307:  *    
        !          1308:  * RETURNS
        !          1309:  *    NZERROR_OK           Success.
        !          1310:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          1311:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          1312:  */
        !          1313: #ifdef __STDC__
        !          1314: nzerror nztSeedRandom(nzctx *, nzttPersona *, ub4, ub1 *);
        !          1315: #else
        !          1316: nzerror nztSeedRandom(/*_ nzctx *, nzttPersona *, ub4, ub1 * _*/);
        !          1317: #endif /* __STDC __*/
        !          1318: 
        !          1319: /*--------------------- nztrb_RandomBytes ---------------------*/
        !          1320: 
        !          1321: /*
        !          1322:  * NAME
        !          1323:  *    nztrb_RandomBytes - Generate a buffer random bytes.
        !          1324:  * 
        !          1325:  * PARAMETERS
        !          1326:  *    osscntxt {IN}     OSS context.
        !          1327:  *    persona  {IN}     Persona.
        !          1328:  *    nbytes   {IN}     Number of bytes desired.
        !          1329:  *    out      {IN/OUT} Buffer block for bytes.
        !          1330:  * 
        !          1331:  * NOTES
        !          1332:  *    
        !          1333:  * RETURNS
        !          1334:  *    NZERROR_OK           Success.
        !          1335:  *    NZERROR_TK_CANTGROW  Needed to grow TDU buffer but could not.
        !          1336:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          1337:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          1338:  */
        !          1339: #ifdef __STDC__
        !          1340: nzerror nztrb_RandomBytes(nzctx *, nzttPersona *, ub4, 
        !          1341:                               nzttBufferBlock *);
        !          1342: #else
        !          1343: nzerror nztrb_RandomBytes(/*_ nzctx *, nzttPersona *, ub4, 
        !          1344:                               nzttBufferBlock * _*/);
        !          1345: #endif /* __STDC __*/
        !          1346: 
        !          1347: /*-------------------- nztrn_RandomNumber --------------------*/
        !          1348: 
        !          1349: /*
        !          1350:  * NAME
        !          1351:  *    nztrn_RandomNumber - Generate a random number
        !          1352:  * 
        !          1353:  * PARAMETERS
        !          1354:  *    osscntxt {IN}     OSS context.
        !          1355:  *    persona  {IN}     Persona.
        !          1356:  *    num      {OUT}    Number.
        !          1357:  * 
        !          1358:  * NOTES
        !          1359:  *    
        !          1360:  * RETURNS
        !          1361:  *    NZERROR_OK           Success.
        !          1362:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          1363:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          1364:  */
        !          1365: #ifdef __STDC__
        !          1366: nzerror nztrn_RandomNumber(nzctx *, nzttPersona *, uword *);
        !          1367: #else
        !          1368: nzerror nztrn_RandomNumber(/*_ nzctx *, nzttPersona *, uword * _*/);
        !          1369: #endif /* __STDC __*/
        !          1370: 
        !          1371: /*---------------------- nztbbInitBlock ----------------------*/
        !          1372: 
        !          1373: /*
        !          1374:  * NAME
        !          1375:  *    nztbbInitBlock - Initialize a buffer block.
        !          1376:  * 
        !          1377:  * PARAMETERS
        !          1378:  *    osscntxt {IN}     OSS context.
        !          1379:  *    block    {IN/OUT} Buffer block.
        !          1380:  * 
        !          1381:  * NOTES
        !          1382:  *    The buffer block is initialized to be empty (all members are set
        !          1383:  *    to 0/NULL).  Such a block will be allocated memory as needed.
        !          1384:  *    
        !          1385:  * RETURNS
        !          1386:  *    NZERROR_OK        Success.
        !          1387:  */
        !          1388: #ifdef __STDC__
        !          1389: nzerror nztbbInitBlock(nzctx *, nzttBufferBlock *);
        !          1390: #else
        !          1391: nzerror nztbbInitBlock(/*_ nzctx *, nzttBufferBlock * _*/);
        !          1392: #endif /* __STDC __*/
        !          1393: 
        !          1394: /*---------------------- nztbbReuseBlock ----------------------*/
        !          1395: 
        !          1396: /*
        !          1397:  * NAME
        !          1398:  *    nztbbReuseBlock - Reuse an already initialized and possibly used block.
        !          1399:  * 
        !          1400:  * PARAMETERS
        !          1401:  *    osscntxt {IN}     OSS context.
        !          1402:  *    block    {IN/OUT} Buffer block.
        !          1403:  * 
        !          1404:  * NOTES
        !          1405:  *    This function simply sets the used length member of the buffer
        !          1406:  *    block to 0.  If the block already has memory allocated to it,
        !          1407:  *    this will cause it to be reused.
        !          1408:  *    
        !          1409:  * RETURNS
        !          1410:  *    NZERROR_OK        Success.
        !          1411:  */
        !          1412: #ifdef __STDC__
        !          1413: nzerror nztbbReuseBlock(nzctx *, nzttBufferBlock *);
        !          1414: #else
        !          1415: nzerror nztbbReuseBlock(/*_ nzctx *, nzttBufferBlock * _*/);
        !          1416: #endif /* __STDC __*/
        !          1417: 
        !          1418: /*---------------------- nztbbSizeBlock ----------------------*/
        !          1419: 
        !          1420: /*
        !          1421:  * NAME
        !          1422:  *    nztbbSizeBlock - Size an initialized block to a particular size.
        !          1423:  * 
        !          1424:  * PARAMETERS
        !          1425:  *    osscntxt {IN}     OSS context.
        !          1426:  *    len      {IN}     Minimum number of unused bytes desired.
        !          1427:  *    block    {IN/OUT} Buffer block.
        !          1428:  *
        !          1429:  * NOTES
        !          1430:  *    
        !          1431:  * RETURNS
        !          1432:  *    NZERROR_OK        Success.
        !          1433:  */
        !          1434: #ifdef __STDC__
        !          1435: nzerror nztbbSizeBlock(nzctx *, ub4, nzttBufferBlock *);
        !          1436: #else
        !          1437: nzerror nztbbSizeBlock(/*_ nzctx *, ub4, nzttBufferBlock * _*/);
        !          1438: #endif /* __STDC __*/
        !          1439: 
        !          1440: /*----------------------- nztbbGrowBlock -----------------------*/
        !          1441: 
        !          1442: /*
        !          1443:  * NAME
        !          1444:  *    nzbbGrowBlock - Increase the size of the buffer block.
        !          1445:  * 
        !          1446:  * PARAMETERS
        !          1447:  *    osscntxt {IN}     OSS context.
        !          1448:  *    inc      {IN}     Number of bytes to increase.
        !          1449:  *    block    {IN/OUT} Buffer block.
        !          1450:  *
        !          1451:  * NOTES
        !          1452:  *    
        !          1453:  * RETURNS
        !          1454:  *    NZERROR_OK        Success.
        !          1455:  */
        !          1456: #ifdef __STDC__
        !          1457: nzerror nztbbGrowBlock(nzctx *, ub4, nzttBufferBlock *);
        !          1458: #else
        !          1459: nzerror nztbbGrowBlock(/*_ nzctx *, ub4, nzttBufferBlock * _*/);
        !          1460: #endif /* __STDC __*/
        !          1461: 
        !          1462: /*---------------------- nztbbPurgeBlock ----------------------*/
        !          1463: 
        !          1464: /*
        !          1465:  * NAME
        !          1466:  *    nztbbPurgeBlock - Purge a buffer block of its memory.
        !          1467:  * 
        !          1468:  * PARAMETERS
        !          1469:  *    osscntxt {IN}     OSS context.
        !          1470:  *    block    {IN/OUT} Buffer block.
        !          1471:  * 
        !          1472:  * NOTES
        !          1473:  *    The memory used by the buffer block as the buffer is released.
        !          1474:  *    The buffer block itself is not affected.
        !          1475:  *    
        !          1476:  * RETURNS
        !          1477:  *    NZERROR_OK        Success.
        !          1478:  */
        !          1479: #ifdef __STDC__
        !          1480: nzerror nztbbPurgeBlock(nzctx *, nzttBufferBlock *);
        !          1481: #else
        !          1482: nzerror nztbbPurgeBlock(/*_ nzctx *, nzttBufferBlock * _*/);
        !          1483: #endif /* __STDC __*/
        !          1484: 
        !          1485: /*----------------------- nztbbSetBlock -----------------------*/
        !          1486: 
        !          1487: /*
        !          1488:  * NAME
        !          1489:  *    nztbbSetBlock - Set a buffer block to a known state.
        !          1490:  * 
        !          1491:  * PARAMETERS
        !          1492:  *    osscntxt {IN}     OSS context.
        !          1493:  *    flags    {IN}     Flags to set.
        !          1494:  *    buflen   {IN}     Length of buffer.
        !          1495:  *    usedlen  {IN}     Used length.
        !          1496:  *    buffer   {IN}     Buffer.
        !          1497:  *    block    {IN/OUT} Buffer block
        !          1498:  * 
        !          1499:  * NOTES
        !          1500:  *    If buflen > 0, objlen == 0, and obj == NULL, then buflen bytes
        !          1501:  *    of memory is allocated and a pointer is stored in the buffer
        !          1502:  *    block.
        !          1503:  *
        !          1504:  *    The buffer parameter remains unchanged.
        !          1505:  *    
        !          1506:  * RETURNS
        !          1507:  *    NZERROR_OK        Success.
        !          1508:  */
        !          1509: #ifdef __STDC__
        !          1510: nzerror nztbbSetBlock(nzctx *,  uword, ub4, ub4, ub1 *, 
        !          1511:                           nzttBufferBlock *);
        !          1512: #else
        !          1513: nzerror nztbbSetBlock(/*_ nzctx *,  uword, ub4, ub4, ub1 *, 
        !          1514:                           nzttBufferBlock * _*/);
        !          1515: #endif /* __STDC __*/
        !          1516: 
        !          1517: 
        !          1518: /*--------------------- nztiGetSecInfo ---------------------*/
        !          1519: 
        !          1520: /*
        !          1521:  * NAME
        !          1522:  *     nztiGetSecInfo - Get some security information for SSL
        !          1523:  * 
        !          1524:  * PARAMETERS
        !          1525:  *     Name    {IN/OUT}        Description
        !          1526:  *     osscntxt {IN}           OSS context.
        !          1527:  *     persona  {IN}           persona
        !          1528:  *     dname    {OUT}          distinguished name of the certificate
        !          1529:  *     dnamelen {OUT}          length of the distinguished name 
        !          1530:  *     issuername {OUT}        issuer name of the certificate
        !          1531:  *     certhash {OUT}          SHA1 hash of the certificate
        !          1532:  *     certhashlen{OUT}        length of the hash
        !          1533:  * NOTES
        !          1534:  *     This function allocate memories for issuername, certhash, and dname.
        !          1535:  *     To deallocate memory for those params, you should call nztdbuf_DestroyBuf.
        !          1536:  * RETURNS
        !          1537:  *     
        !          1538:  */
        !          1539: #ifdef __STDC__
        !          1540: nzerror nztiGetSecInfo(nzctx *, nzttPersona *, text **, ub4 *,
        !          1541:                         text **, ub4 *, ub1 **, ub4 *);
        !          1542: #else
        !          1543: nzerror nztiGetSecInfo(/*_ nzctx *, nzttPersona *, text **, ub4 *,
        !          1544:                           text **, ub4 *, ub1 **, ub4 * _*/);
        !          1545: #endif /* __STDC__ */
        !          1546: 
        !          1547: 
        !          1548: /*---------------------- nztiGetDName ----------------------*/
        !          1549: 
        !          1550: /*
        !          1551:  * NAME
        !          1552:  *     nztiGetDName - Get the distinguished name for the given identity
        !          1553:  * 
        !          1554:  * PARAMETERS
        !          1555:  *     Name    {IN/OUT}        Description
        !          1556:  *     osscntxt {IN}           OSS context.
        !          1557:  *     identity {IN}           identity need to get dname from
        !          1558:  *     dn      {OUT}           distinguished name
        !          1559:  *     dnlen   {OUT}           length of the dname
        !          1560:  *
        !          1561:  * NOTES
        !          1562:  *     
        !          1563:  * RETURNS
        !          1564:  *     
        !          1565:  */
        !          1566: 
        !          1567: #ifdef __STDC__
        !          1568: nzerror nztiGetDName(nzctx *, nzttIdentity *,
        !          1569:                     text **, ub4 *);
        !          1570: #else
        !          1571: nzerror nztiGetDName(/*_ nzctx *, nzttIdentity *,
        !          1572:                             text **, ub4 * _*/);
        !          1573: #endif /* __STDC__ */
        !          1574: 
        !          1575: /*------------------- nztiGetIssuerName -------------------*/
        !          1576: 
        !          1577: /*
        !          1578:  * NAME
        !          1579:  *     nztiGetIssuerName -  Get IssuerName for the given identity 
        !          1580:  * 
        !          1581:  * PARAMETERS
        !          1582:  *     Name    {IN/OUT}        Description
        !          1583:  *     osscntxt {IN}           OSS context.
        !          1584:  *     identity {IN}           identity need to get issuername from
        !          1585:  *     issuername {OUT}        issuer's name
        !          1586:  *     issuernamelen {OUT}     length of the issuer's name
        !          1587:  * 
        !          1588:  * NOTES
        !          1589:  *     
        !          1590:  * RETURNS
        !          1591:  *     
        !          1592:  */
        !          1593: #ifdef __STDC__
        !          1594: nzerror nztiGetIssuerName(nzctx *, nzttIdentity *,
        !          1595:                             text **, ub4 *);
        !          1596: #else
        !          1597: nzerror nztiGetIssuerName(/*_ nzctx *, nzttIdentity *,
        !          1598:                              text **, ub4 * _*/);
        !          1599: #endif /* __STDC__ */
        !          1600: 
        !          1601: 
        !          1602: /*-------------------- nztgch_GetCertHash --------------------*/
        !          1603: 
        !          1604: /*
        !          1605:  * NAME
        !          1606:  *     nztgch_GetCertHash -  Get SHA1 hash for the certificate of the identity 
        !          1607:  * 
        !          1608:  * PARAMETERS
        !          1609:  *     Name    {IN/OUT}        Description
        !          1610:  *     osscntxt {IN}           OSS context.
        !          1611:  *     identity {IN}           identity need to get issuername from
        !          1612:  *     certHash {OUT}          certHash buffer 
        !          1613:  *     hashLen {OUT}           length of the certHash 
        !          1614:  * 
        !          1615:  * NOTES
        !          1616:  *     Need to call nztdbuf_DestroyBuf to deallocate memory for certHash.      
        !          1617:  * RETURNS
        !          1618:  *     
        !          1619:  */
        !          1620: #ifdef __STDC__
        !          1621: nzerror nztgch_GetCertHash(nzctx *, nzttIdentity *,
        !          1622:                             ub1 **, ub4 *);
        !          1623: #else
        !          1624: nzerror nztgch_GetCertHash(/*_ nzctx *, nzttIdentity *,
        !          1625:                             ub1 **, ub4 * _*/);
        !          1626: #endif /* __STDC__ */
        !          1627: 
        !          1628: /*-------------------- nztdbuf_DestroyBuf --------------------*/
        !          1629: 
        !          1630: /*
        !          1631:  * NAME
        !          1632:  *     nztdbuf_DestroyBuf - Deallocation funtions for ub1 and text buffer 
        !          1633:  * 
        !          1634:  * PARAMETERS
        !          1635:  *     Name    {IN/OUT}        Description
        !          1636:  *     osscntxt {IN}           OSS context.
        !          1637:  *     buf      {IN}           Allocated buffer to be destroyed.
        !          1638:  * 
        !          1639:  * NOTES
        !          1640:  *     
        !          1641:  * RETURNS
        !          1642:  *     
        !          1643:  */
        !          1644: #ifdef __STDC__
        !          1645: nzerror nztdbuf_DestroyBuf( nzctx *, dvoid **);
        !          1646: #else
        !          1647: nzerror nztdbuf_DestroyBuf(/*_ nzctx *, dvoid ** _*/);
        !          1648: #endif /* __STDC__ */
        !          1649: 
        !          1650: 
        !          1651: /*----------------------- nztGetCertChain -----------------------*/
        !          1652: 
        !          1653: /*
        !          1654:  * NAME
        !          1655:  *     nztGetCertChain - 
        !          1656:  * 
        !          1657:  * PARAMETERS
        !          1658:  *     Name    {IN/OUT}        Description
        !          1659:  *     osscntxt {IN}           OSS context.
        !          1660:  * 
        !          1661:  * NOTES
        !          1662:  *     
        !          1663:  * RETURNS
        !          1664:  *     
        !          1665:  */
        !          1666: #ifdef __STDC__
        !          1667: nzerror nztGetCertChain(nzctx *, nzttWallet * );
        !          1668: #else
        !          1669: nzerror nztGetCertChain(/*_ nzctx *, nzttWallet _*/);
        !          1670: #endif /* __STDC__ */
        !          1671: 
        !          1672: /*----------------------- nztCompareDN -----------------------*/
        !          1673: 
        !          1674: /*
        !          1675:  * NAME
        !          1676:  *     nztCompareDN - 
        !          1677:  * 
        !          1678:  * PARAMETERS
        !          1679:  *     Name    {IN/OUT}        Description
        !          1680:  *     osscntxt {IN}           OSS context.
        !          1681:  *     dn1     {IN}            distinguished name 1
        !          1682:  *     dn2     {IN}            distinguished name 2
        !          1683:  * 
        !          1684:  * NOTES
        !          1685:  *     
        !          1686:  * RETURNS
        !          1687:  *     NZERROR_OK              succeeded
        !          1688:  *     others                  failed
        !          1689:  *     
        !          1690:  */
        !          1691: #ifdef __STDC__
        !          1692: nzerror nztCompareDN(nzctx *, ub1 *, ub4,  ub1 *, ub4, boolean * );
        !          1693: #else
        !          1694: nzerror nztCompareDN(/*_ nzctx *, ub1 *,ub4 ,  ub1 *, ub4, boolean * _*/);
        !          1695: #endif/* __STDC__ */
        !          1696: 
        !          1697: 
        !          1698: #ifdef NZ_OLD_TOOLS
        !          1699: /*--------------------- nztIdentityAlloc ---------------------*/
        !          1700: 
        !          1701: /*
        !          1702:  * NAME
        !          1703:  *     nztIdentityAlloc - Allocate memory for nzttIdentity context
        !          1704:  * 
        !          1705:  * PARAMETERS
        !          1706:  *     Name    {IN/OUT}        Description
        !          1707:  *     osscntxt {IN}           OSS context.
        !          1708:  *     identity {OUT}          nzttIdentity context
        !          1709:  * 
        !          1710:  * NOTES
        !          1711:  *     
        !          1712:  * RETURNS
        !          1713:  *     NZERROR_OK              succeeded
        !          1714:  *     others                  failed
        !          1715:  *     
        !          1716:  */
        !          1717: #ifdef __STDC__
        !          1718: nzerror nztIdentityAlloc(nzctx *, nzttIdentity **);
        !          1719: #else
        !          1720: nzerror nztIdentityAlloc(/*_ nzctx *, nzttIdentity ** _*/);
        !          1721: #endif/* __STDC__ */
        !          1722: 
        !          1723: /*--------------------- nztIPrivateAlloc ---------------------*/
        !          1724: 
        !          1725: /*
        !          1726:  * NAME
        !          1727:  *     nztIPrivateAlloc - Allocate memory for nzttIdentityPrivate
        !          1728:  * 
        !          1729:  * PARAMETERS
        !          1730:  *     Name    {IN/OUT}        Description
        !          1731:  * 
        !          1732:  *     osscntxt {IN}           OSS context.
        !          1733:  *     ipriv   {OUT}           identityPrivate structure
        !          1734:  * NOTES
        !          1735:  *     
        !          1736:  * RETURNS
        !          1737:  *     NZERROR_OK              succeeded
        !          1738:  *     others                  failed
        !          1739:  *     
        !          1740:  */
        !          1741: 
        !          1742: #ifdef __STDC__
        !          1743: nzerror nztIPrivateAlloc( nzctx *, nzttIdentityPrivate **);
        !          1744: #else
        !          1745: nzerror nztIPrivateAlloc( nzctx *, nzttIdentityPrivate **);
        !          1746: #endif /* __STDC__ */
        !          1747: 
        !          1748: 
        !          1749: /*---------------------- nztIDupContent ----------------------*/
        !          1750: 
        !          1751: /*
        !          1752:  * NAME
        !          1753:  *     nztIDupContent - 
        !          1754:  * 
        !          1755:  * PARAMETERS
        !          1756:  *     Name    {IN/OUT}        Description
        !          1757:  *     osscntxt {IN}           OSS context.
        !          1758:  *     targetIdentity{OUT}     target identity
        !          1759:  *     sourceIdentity {IN}     source identity
        !          1760:  * NOTES
        !          1761:  *     
        !          1762:  * RETURNS
        !          1763:  *     NZERROR_OK              succeeded
        !          1764:  *     others                  failed
        !          1765:  *     
        !          1766:  */
        !          1767: 
        !          1768: #ifdef __STDC__
        !          1769: nzerror nztIDupContent( nzctx *, nzttIdentity *, nzttIdentity *);
        !          1770: #else
        !          1771: nzerror nztIDupContent(/*_ nzctx *, nzttIdentity *, nzttIdentity * _*/);
        !          1772: #endif
        !          1773: /*---------------------- nztIPDuplicate ----------------------*/
        !          1774: 
        !          1775: /*
        !          1776:  * NAME
        !          1777:  *     nztIPDuplicate - 
        !          1778:  * 
        !          1779:  * PARAMETERS
        !          1780:  *     Name    {IN/OUT}        Description
        !          1781:  *     osscntxt {IN}           OSS context.
        !          1782:  *     target_ipriv {OUT}      target identityPrivate
        !          1783:  *     source_ipriv {IN}       source identityPrivate
        !          1784:  * 
        !          1785:  * NOTES
        !          1786:  *     
        !          1787:  * RETURNS
        !          1788:  *     NZERROR_OK              succeeded
        !          1789:  *     others                  failed
        !          1790:  *     
        !          1791:  */
        !          1792: #ifdef __STDC__
        !          1793: nzerror nztIPDuplicate( nzctx *, nzttIdentityPrivate **,
        !          1794:                        nzttIdentityPrivate *);
        !          1795: #else
        !          1796: nzerror nztIPDuplicate(/*_ nzctx *, nzttIdentityPrivate **,
        !          1797:                         nzttIdentityPrivate * _*/);
        !          1798: #endif /* __STDC__ */
        !          1799: 
        !          1800: /*--------------------- nztiDupIdentList ---------------------*/
        !          1801: 
        !          1802: /*
        !          1803:  * NAME
        !          1804:  *     nztiDupIdentList - 
        !          1805:  * 
        !          1806:  * PARAMETERS
        !          1807:  *     Name    {IN/OUT}        Description
        !          1808:  *     osscntxt {IN}           OSS context.
        !          1809:  *     source_identities {IN}  source identity list
        !          1810:  *     numIdent {OUT}          number of identity in the list
        !          1811:  *     ppidentity {OUT}        Target of identity      
        !          1812:  *     
        !          1813:  * NOTES
        !          1814:  *     
        !          1815:  * RETURNS
        !          1816:  *     NZERROR_OK              succeeded
        !          1817:  *     others                  failed
        !          1818:  *     
        !          1819:  */
        !          1820: #ifdef __STDC__
        !          1821: nzerror nztiDupIdentList( nzctx *, nzttIdentity  *, ub4 *, nzttIdentity **);
        !          1822: #else
        !          1823: 
        !          1824: nzerror nztiDupIdentList(/*_ nzctx *, nzttIdentity  *, ub4 *, nzttIdentity ** _*/);
        !          1825: #endif
        !          1826: 
        !          1827: /*--------------------- nztFreeIdentList ---------------------*/
        !          1828: 
        !          1829: /*
        !          1830:  * NAME
        !          1831:  *     nztFreeIdentList - Free memory for a list of Identities
        !          1832:  * 
        !          1833:  * PARAMETERS
        !          1834:  *     Name    {IN/OUT}        Description
        !          1835:  *     osscntxt {IN}           OSS context.
        !          1836:  *     identity {IN}           identity context
        !          1837:  *
        !          1838:  * NOTES
        !          1839:  *     
        !          1840:  * RETURNS
        !          1841:  *     NZERROR_OK              succeeded
        !          1842:  *     others                  failed
        !          1843:  *     
        !          1844:  */
        !          1845: #ifdef __STDC__
        !          1846: nzerror nztFreeIdentList( nzctx *, nzttIdentity **);
        !          1847: #else
        !          1848: nzerror nztFreeIdentList(/*_ nzctx *, nzttIdentity ** _*/);
        !          1849: #endif
        !          1850: #endif /* NZ_OLD_TOOLS */
        !          1851: 
        !          1852: /*--------------------- nztCheckVaLidity ---------------------*/
        !          1853: 
        !          1854: /*
        !          1855:  * NAME
        !          1856:  *     nztCheckVaLidity -  Check the validity of certificate
        !          1857:  * 
        !          1858:  * PARAMETERS
        !          1859:  *     Name    {IN/OUT}        Description
        !          1860:  *     osscntxt {IN}           OSS context.
        !          1861:  *     start_time              Start time of the certificate
        !          1862:  *     end_time                End time of the certificate
        !          1863:  * 
        !          1864:  * NOTES
        !          1865:  *     
        !          1866:  * RETURNS
        !          1867:  *     NZERROR_OK              succeeded
        !          1868:  *     others                  failed
        !          1869:  *     
        !          1870:  */
        !          1871: #ifdef __STDC__
        !          1872: nzerror nztCheckValidity( nzctx *, ub4 , ub4 );
        !          1873: #else
        !          1874: nzerror nztCheckValidity(/*_ nzctx *, ub4 , ub4 _*/);
        !          1875: #endif
        !          1876: 
        !          1877: /*--------------------- nztwCreateWallet ---------------------*/
        !          1878: 
        !          1879: /*
        !          1880:  * NAME
        !          1881:  *    nztwCreateWallet - Create a new wallet.
        !          1882:  * 
        !          1883:  * PARAMETERS
        !          1884:  *    osscntxt {IN}     OSS context.
        !          1885:  *    wrllen   {IN}     Length of wallet resource locator.
        !          1886:  *    wrl      {IN}     WRL.
        !          1887:  *    pwdlen   {IN}     Length of password (see notes below).
        !          1888:  *    pwd      {IN}     Password.
        !          1889:  *    wallet   {IN/OUT} Wallet. 
        !          1890:  * 
        !          1891:  * NOTES
        !          1892:  *    It is an error to try to create a wallet that already exists.
        !          1893:  *    The previously existing wallet must be destroyed first.
        !          1894:  *
        !          1895:  *    The wallet itself is not encrypted.  Rather, all the personas in
        !          1896:  *    the wallet are encrypted under the same password.  A hash of the
        !          1897:  *    password is stored in the wallet.
        !          1898:  *
        !          1899:  *    Upon success, an empty open wallet is stored in the wallet
        !          1900:  *    parameter.
        !          1901:  *    
        !          1902:  * RETURNS
        !          1903:  *    NZERROR_OK                 Sucess.
        !          1904:  *    NZERROR_TK_WALLET_EXISTS   Wallet already exists.
        !          1905:  *    NZERROR_RIO_OPEN           RIO could not create wallet (see trace file).
        !          1906:  */
        !          1907: #ifdef __STDC__
        !          1908: nzerror nztwCreateWallet(nzctx *, ub4, text *, ub4, text *, 
        !          1909:                              nzttWallet *);
        !          1910: #else
        !          1911: nzerror nztwCreateWallet(/*_ nzctx *, ub4, text *, ub4, text *, 
        !          1912:                              nzttWallet * _*/);
        !          1913: #endif /* __STDC__ */
        !          1914: 
        !          1915: 
        !          1916: /*--------------------- nztwDestroyWallet ---------------------*/
        !          1917: 
        !          1918: /*
        !          1919:  * NAME
        !          1920:  *    nztwDestroyWallet - Destroy an existing wallet.
        !          1921:  * 
        !          1922:  * PARAMETERS
        !          1923:  *    osscntxt {IN}     OSS context.
        !          1924:  *    wrllen   {IN}     Length of wallet resource locator.
        !          1925:  *    wrl      {IN}     WRL.
        !          1926:  *    pwdlen   {IN}     Length of password.
        !          1927:  *    pwd      {IN}     Password.
        !          1928:  * NOTES
        !          1929:  *    
        !          1930:  * RETURNS
        !          1931:  *    NZERROR_OK           Success.
        !          1932:  *    NZERROR_TK_PASSWORD  Password verification failed.
        !          1933:  *    NZERROR_RIO_OPEN     RIO could not open wallet (see trace file).
        !          1934:  *    NZERROR_RIO_DELETE   Delete failed (see trace file).
        !          1935:  */
        !          1936: #ifdef __STDC__
        !          1937: nzerror nztwDestroyWallet(nzctx *, ub4, text *, ub4, text *);
        !          1938: #else
        !          1939: nzerror nztwDestroyWallet(/*_ nzctx *, ub4, text *, ub4, text * _*/);
        !          1940: #endif /* __STDC __*/
        !          1941: 
        !          1942: /*--------------------- nzteStorePersona ---------------------*/
        !          1943: 
        !          1944: /*
        !          1945:  * NAME
        !          1946:  *    nzteStorePersona - Store an open persona in a wallet.
        !          1947:  * 
        !          1948:  * PARAMETERS
        !          1949:  *    osscntxt {IN}     OSS context. 
        !          1950:  *    persona  {IN/OUT} Persona.
        !          1951:  *    wallet   {IN/OUT} Wallet.
        !          1952:  * 
        !          1953:  * NOTES
        !          1954:  *    If the open persona is not associated with any wallet (it was
        !          1955:  *    created via the nzteClosePersona function), then storing the
        !          1956:  *    persona creates that association.  The wallet will also have an
        !          1957:  *    updated persona list that reflects this association.
        !          1958:  *
        !          1959:  *    If the open persona was associated with wallet 'A' (it was
        !          1960:  *    opened via the nztwOpenWallet function), and is stored back into
        !          1961:  *    wallet 'A', then then the old persona is overwritten by the new
        !          1962:  *    persona if the password can be verified.  Recall that all
        !          1963:  *    personas have a unique identity id.  If that id changes then
        !          1964:  *    storing the persona will put a new persona in the wallet.
        !          1965:  *
        !          1966:  *    If the open persona was associated with wallet 'A' and is stored
        !          1967:  *    into wallet 'B', and if wallet 'B' does not contain a persona
        !          1968:  *    with that unique identity id, then the persona will be copied
        !          1969:  *    into wallet 'B', wallet 'B''s persona list will be updated, and
        !          1970:  *    the persona structure will be updated to be associated with
        !          1971:  *    wallet 'B'.  If wallet 'B' already contained the persona, it
        !          1972:  *    would be overwritten by the new persona.
        !          1973:  *
        !          1974:  *    The persona parameter is doubly indirect so that at the
        !          1975:  *    conclusion of the function call, the pointer can be directed to
        !          1976:  *    the persona in the wallet.
        !          1977:  *
        !          1978:  * RETURNS
        !          1979:  *    NZERROR_OK           Success.
        !          1980:  *    NZERROR_TK_PASSWORD  Password verification failed.
        !          1981:  *    NZERROR_RIO_STORE    Store failed (see network trace file).
        !          1982:  */
        !          1983: #ifdef __STDC__
        !          1984: nzerror nzteStorePersona(nzctx *, nzttPersona **, nzttWallet *);
        !          1985: #else
        !          1986: nzerror nzteStorePersona(/*_ nzctx *, nzttPersona **, nzttWallet * _*/);
        !          1987: #endif /* __STDC __*/
        !          1988: 
        !          1989: /*--------------------- nzteRemovePersona ---------------------*/
        !          1990: 
        !          1991: /*
        !          1992:  * NAME
        !          1993:  *    nzteRemovePersona - Remove a persona from the wallet.
        !          1994:  * 
        !          1995:  * PARAMETERS
        !          1996:  *    osscntxt {IN}     OSS context.
        !          1997:  *    persona  {IN/OUT} Persona.
        !          1998:  * 
        !          1999:  * NOTES
        !          2000:  *    The password is verified before trying to remove the persona.
        !          2001:  *    
        !          2002:  *    If the persona is open, it is closed.  The persona is removed
        !          2003:  *    from the wallet list and the persona pointer is set to NULL.
        !          2004:  *    
        !          2005:  *    A double indirect pointer to the persona is required so that the
        !          2006:  *    persona pointer can be set to NULL upon completion.
        !          2007:  *
        !          2008:  * RETURNS
        !          2009:  *    NZERROR_OK           Success.
        !          2010:  *    NZERROR_TK_PASSWORD  Password verification failed.
        !          2011:  *    NZERROR_RIO_DELETE   Delete failed.
        !          2012:  */
        !          2013: #ifdef __STDC__
        !          2014: nzerror nzteRemovePersona(nzctx *, nzttPersona **);
        !          2015: #else
        !          2016: nzerror nzteRemovePersona(/*_ nzctx *, nzttPersona ** _*/);
        !          2017: #endif /* __STDC __*/
        !          2018: 
        !          2019: /*--------------------- nzteCreatePersona ---------------------*/
        !          2020: 
        !          2021: /*
        !          2022:  * NAME
        !          2023:  *    nzteCreatePersona - Create a persona.
        !          2024:  * 
        !          2025:  * PARAMETERS
        !          2026:  *    osscntxt {IN}     OSS context.
        !          2027:  *    itype    {IN}     Identity type.
        !          2028:  *    ctype    {IN}     Cipher type.
        !          2029:  *    desc     {IN}     Persona description.
        !          2030:  *    persona  {OUT}    Persona.
        !          2031:  * 
        !          2032:  * NOTES
        !          2033:  *    The resulting persona is created in the open state, but it will
        !          2034:  *    not be associated with a wallet.
        !          2035:  *    
        !          2036:  *    The memory for the persona is allocated by the function.
        !          2037:  *
        !          2038:  * RETURNS
        !          2039:  *    NZERROR_OK        Success.
        !          2040:  *    NZERROR_TK_TYPE   Unsupported itype/ctype combination.
        !          2041:  *    NZERROR_TK_PARMS  Error in persona description.
        !          2042:  */
        !          2043: #ifdef __STDC__
        !          2044: nzerror nzteCreatePersona(nzctx *, nzttVersion, nzttCipherType, 
        !          2045:                          nzttPersonaDesc *, nzttPersona **);
        !          2046: #else
        !          2047: nzerror nzteCreatePersona(/*_ nzctx *, nzttVersion, nzttCipherType, 
        !          2048:                               nzttPersonaDesc *, nzttPersona ** _*/);
        !          2049: #endif /* __STDC __*/
        !          2050: 
        !          2051: 
        !          2052: /*----------------- nztiStoreTrustedIdentity -----------------*/
        !          2053: 
        !          2054: /*
        !          2055:  * NAME
        !          2056:  *    nztiStoreTrustedIdentity - Store an identity into a persona.
        !          2057:  * 
        !          2058:  * PARAMETERS
        !          2059:  *    osscntxt {IN}     Success.
        !          2060:  *    identity {IN/OUT} Trusted Identity.
        !          2061:  *    persona  {IN/OUT} Persona.    
        !          2062:  * 
        !          2063:  * NOTES
        !          2064:  *    The identity is not saved with the persona in the wallet until
        !          2065:  *    the persona is stored.
        !          2066:  *    
        !          2067:  *    The identity parameter is double indirect so that it can point
        !          2068:  *    into the persona at the conclusion of the call.
        !          2069:  *
        !          2070:  * RETURNS
        !          2071:  *    NZERROR_OK     Success.
        !          2072:  */
        !          2073: #ifdef __STDC__
        !          2074: nzerror nztiStoreTrustedIdentity(nzctx *, nzttIdentity **,
        !          2075:                                      nzttPersona *);
        !          2076: #else
        !          2077: nzerror nztiStoreTrustedIdentity(/*_ nzctx *, nzttIdentity **,
        !          2078:                                      nzttPersona * _*/);
        !          2079: #endif /* __STDC __*/
        !          2080: 
        !          2081: /*--------------------- nzteSetProtection ---------------------*/
        !          2082: 
        !          2083: /*
        !          2084:  * NAME
        !          2085:  *    nzteSetProtection - Set the protection type for a CE function.
        !          2086:  * 
        !          2087:  * PARAMETERS
        !          2088:  *    osscntxt {IN}     OSS context.
        !          2089:  *    persona  {IN/OUT} Persona.
        !          2090:  *    func     {IN}     CE function.
        !          2091:  *    tdufmt   {IN}     TDU Format.
        !          2092:  *    protinfo {IN}     Protection information specific to this format.
        !          2093:  * 
        !          2094:  * NOTES
        !          2095:  *    
        !          2096:  * RETURNS
        !          2097:  *    NZERROR_OK              Success.
        !          2098:  *    NZERROR_TK_PROTECTION   Unsupported protection.
        !          2099:  *    NZERROR_TK_PARMS        Error in protection info.
        !          2100:  */
        !          2101: #ifdef __STDC__
        !          2102: nzerror nzteSetProtection(nzctx *, nzttPersona *, nzttcef, nztttdufmt,
        !          2103:                               nzttProtInfo *);
        !          2104: #else
        !          2105: nzerror nzteSetProtection(/*_ nzctx *, nzttPersona *, nzttcef, nztttdufmt,
        !          2106:                               nzttProtInfo * _*/);
        !          2107: #endif /* __STDC __*/
        !          2108: 
        !          2109: /*--------------------- nzteGetProtection ---------------------*/
        !          2110: 
        !          2111: /*
        !          2112:  * NAME
        !          2113:  *    nzteGetProtection - Get the protection type for a CE function.
        !          2114:  * 
        !          2115:  * PARAMETERS
        !          2116:  *    osscntxt {IN}     OSS context.
        !          2117:  *    persona  {IN}     Persona.
        !          2118:  *    func     {IN}     CE function.
        !          2119:  *    tdufmt   {OUT}    TDU format.
        !          2120:  *    protinfo {OUT}    Protection information.
        !          2121:  * 
        !          2122:  * NOTES
        !          2123:  *    
        !          2124:  * RETURNS
        !          2125:  *    NZERROR_OK        Success.
        !          2126:  */
        !          2127: #ifdef __STDC__
        !          2128: nzerror nzteGetProtection(nzctx *, nzttPersona *, nzttcef, nztttdufmt *,
        !          2129:                               nzttProtInfo *);
        !          2130: #else
        !          2131: nzerror nzteGetProtection(/*_ nzctx *, nzttPersona *, nzttcef, nztttdufmt *,
        !          2132:                               nzttProtInfo * _*/);
        !          2133: #endif /* __STDC __*/
        !          2134: 
        !          2135: /*-------------------- nztiRemoveIdentity --------------------*/
        !          2136: 
        !          2137: /*
        !          2138:  * NAME
        !          2139:  *    nztiRemoveIdentity - Remove an identity from an open persona.
        !          2140:  * 
        !          2141:  * PARAMETERS
        !          2142:  *    osscntxt {IN}     OSS context. 
        !          2143:  *    identity {IN/OUT}     Identity.
        !          2144:  * 
        !          2145:  * NOTES
        !          2146:  *    If the persona is not stored, this identity will still be in the
        !          2147:  *    persona stored in the wallet.
        !          2148:  *    
        !          2149:  *    The identity parameter is doubly indirect so that at the
        !          2150:  *    conclusion of the function, the pointer can be set to NULL.
        !          2151:  *
        !          2152:  * RETURNS
        !          2153:  *    NZERROR_OK           Success.
        !          2154:  *    NZERROR_TK_NOTFOUND  Identity not found.
        !          2155:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          2156:  */
        !          2157: #ifdef __STDC__
        !          2158: nzerror nztiRemoveIdentity(nzctx *, nzttIdentity **);
        !          2159: #else
        !          2160: nzerror nztiRemoveIdentity(/*_ nzctx *, nzttIdentity ** _*/);
        !          2161: #endif /* __STDC __*/
        !          2162: 
        !          2163: /*----------------- nztifdn -----------------*/
        !          2164: 
        !          2165: /*
        !          2166:  * NAME
        !          2167:  *    nztifdn - create an Identity From a Distinguished Name
        !          2168:  * 
        !          2169:  * PARAMETERS
        !          2170:  *    osscntxt           {IN}  OSS context.
        !          2171:  *    length             {IN}  Length of the distinguished name
        !          2172:  *    distinguished_name {IN}  distinguished name string
        !          2173:  *    ppidentity         {OUT} created identity
        !          2174:  * 
        !          2175:  * NOTES
        !          2176:  *    Given a distinguished name, return the identity that corresponds to it.
        !          2177:  *
        !          2178:  * RETURNS
        !          2179:  *    NZERROR_OK     Success.
        !          2180:  */
        !          2181: #ifdef __STDC__
        !          2182: nzerror nztifdn(nzctx         *ossctx,
        !          2183:                     ub4         length,
        !          2184:                     text          *distinguished_name,
        !          2185:                     nzttIdentity **ppidentity);
        !          2186: #else
        !          2187: nzerror nztifdn(/*_ nzctx         *ossctx,
        !          2188:                     ub4         length,
        !          2189:                     text          *distinguished_name,
        !          2190:                     nzttIdentity **ppidentity _*/);
        !          2191: #endif /* __STDC __*/
        !          2192: 
        !          2193: /*--------------------- nztxSignExpansion ---------------------*/
        !          2194: 
        !          2195: /*
        !          2196:  * NAME
        !          2197:  *    nztxSignExpansion - Determine the size of the attached signature buffer.
        !          2198:  * 
        !          2199:  * PARAMETERS
        !          2200:  *    osscntxt {IN}  OSS context.
        !          2201:  *    persona  {IN}  Persona.
        !          2202:  *    inlen    {IN}  Length of input.
        !          2203:  *    tdulen   {OUT} Buffer needed for signature.
        !          2204:  *
        !          2205:  * NOTES
        !          2206:  *    
        !          2207:  * RETURNS
        !          2208:  *    NZERROR_OK           Success.
        !          2209:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          2210:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          2211:  */
        !          2212: #ifdef __STDC__
        !          2213: nzerror nztxSignExpansion(nzctx *, nzttPersona *, ub4, ub4 *);
        !          2214: #else
        !          2215: nzerror nztxSignExpansion(/*_ nzctx *, nzttPersona *, ub4, ub4 * _*/);
        !          2216: #endif /* __STDC __*/
        !          2217: 
        !          2218: /*--------------- nztxsd_SignDetachedExpansion ---------------*/
        !          2219: 
        !          2220: /*
        !          2221:  * NAME
        !          2222:  *    nztxsd_SignDetachedExpansion - Determine the size of buffer needed.
        !          2223:  * 
        !          2224:  * PARAMETERS
        !          2225:  *    osscntxt {IN}  OSS context.
        !          2226:  *    persona  {IN}  Persona.
        !          2227:  *    inlen    {IN}  Length of input.
        !          2228:  *    tdulen   {OUT} Buffer needed for signature.
        !          2229:  * 
        !          2230:  * NOTES
        !          2231:  *    
        !          2232:  * RETURNS
        !          2233:  *    NZERROR_OK           Success.
        !          2234:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          2235:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          2236:  */
        !          2237: #ifdef __STDC__
        !          2238: nzerror nztxsd_SignDetachedExpansion(nzctx *, nzttPersona *, ub4,
        !          2239:                                          ub4 *);
        !          2240: #else
        !          2241: nzerror nztxsd_SignDetachedExpansion(/*_ nzctx *, nzttPersona *, ub4,
        !          2242:                                          ub4 * _*/);
        !          2243: #endif /* __STDC __*/
        !          2244: 
        !          2245: /*------------------------ nztEncrypt ------------------------*/
        !          2246: 
        !          2247: /*
        !          2248:  * NAME
        !          2249:  *    nztEncrypt - Symmetrically encrypt
        !          2250:  * 
        !          2251:  * PARAMETERS
        !          2252:  *    osscntxt    {IN}     OSS context.
        !          2253:  *    persona     {IN}     Persona.
        !          2254:  *    inlen       {IN}     Length of this input part.
        !          2255:  *    in          {IN}     This input part.
        !          2256:  *    tdubuf      {IN/OUT} TDU buffer.
        !          2257:  * 
        !          2258:  * NOTES
        !          2259:  *    
        !          2260:  * RETURNS
        !          2261:  *    NZERROR_OK           Success.
        !          2262:  *    NZERROR_TK_CANTGROW  Needed to grow TDU buffer but could not.
        !          2263:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          2264:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          2265:  */
        !          2266: #ifdef __STDC__
        !          2267: nzerror nztEncrypt(nzctx *, nzttPersona *, nzttces, ub4, ub1 *,
        !          2268:                        nzttBufferBlock *);
        !          2269: #else
        !          2270: nzerror nztEncrypt(/*_ nzctx *, nzttPersona *, nzttces, ub4, ub1 *,
        !          2271:                        nzttBufferBlock * _*/);
        !          2272: #endif /* __STDC __*/
        !          2273: 
        !          2274: /*------------------- nztxEncryptExpansion -------------------*/
        !          2275: 
        !          2276: /*
        !          2277:  * NAME
        !          2278:  *    nztxEncryptExpansion - Determine the size of the TDU to encrypt.
        !          2279:  * 
        !          2280:  * PARAMETERS
        !          2281:  *    osscntxt    {IN}  OSS context.
        !          2282:  *    persona     {IN}  Persona.
        !          2283:  *    inlen       {IN}  Length of this input part.
        !          2284:  *    tdulen      {OUT} Length of TDU.
        !          2285:  * 
        !          2286:  * NOTES
        !          2287:  *    
        !          2288:  * RETURNS
        !          2289:  *    NZERROR_OK           Success.
        !          2290:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          2291:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          2292:  */
        !          2293: #ifdef __STDC__
        !          2294: nzerror nztxEncryptExpansion(nzctx *, nzttPersona *, ub4, ub4 *);
        !          2295: #else
        !          2296: nzerror nztxEncryptExpansion(/*_ nzctx *, nzttPersona *, ub4, ub4 * _*/);
        !          2297: #endif /* __STDC __*/
        !          2298: 
        !          2299: /*------------------------ nztDecrypt ------------------------*/
        !          2300: 
        !          2301: /*
        !          2302:  * NAME
        !          2303:  *    nztDecrypt - Decrypt an Encrypted message.
        !          2304:  * 
        !          2305:  * PARAMETERS
        !          2306:  *    osscntxt {IN}     OSS context.
        !          2307:  *    persona  {IN}     Persona.
        !          2308:  *    state    {IN}     State of decryption.
        !          2309:  *    inlen    {IN}     Length of this input part.
        !          2310:  *    in       {IN}     This input part.
        !          2311:  *    out      {IN/OUT} Cleartext message.
        !          2312:  * 
        !          2313:  * NOTES
        !          2314:  *    
        !          2315:  * RETURNS
        !          2316:  *    NZERROR_OK           Success.
        !          2317:  *    NZERROR_TK_CANTGROW  Needed to grow TDU buffer but could not.
        !          2318:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          2319:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          2320:  */
        !          2321: #ifdef __STDC__
        !          2322: nzerror nztDecrypt(nzctx *, nzttPersona *, nzttces, ub4, ub1 *,
        !          2323:                        nzttBufferBlock *);
        !          2324: #else
        !          2325: nzerror nztDecrypt(/*_ nzctx *, nzttPersona *, nzttces, ub4, ub1 *,
        !          2326:                        nzttBufferBlock * _*/);
        !          2327: #endif /* __STDC __*/
        !          2328: 
        !          2329: /*------------------------ nztEnvelope ------------------------*/
        !          2330: 
        !          2331: /*
        !          2332:  * NAME
        !          2333:  *    nztEnvelope - Sign and PKEncrypt a message.
        !          2334:  * 
        !          2335:  * PARAMETERS
        !          2336:  *    osscntxt    {IN}     OSS context.
        !          2337:  *    persona     {IN}     Persona.
        !          2338:  *    nrecipients {IN}     Number of recipients for this encryption.
        !          2339:  *    recipients  {IN}     List of recipients.
        !          2340:  *    state       {IN}     State of encryption.
        !          2341:  *    inlen       {IN}     Length of this input part.
        !          2342:  *    in          {IN}     This input part.
        !          2343:  *    tdubuf      {IN/OUT} TDU buffer.
        !          2344:  *
        !          2345:  * NOTES
        !          2346:  *    
        !          2347:  * RETURNS
        !          2348:  *    NZERROR_OK           Success.
        !          2349:  *    NZERROR_TK_CANTGROW  Needed to grow output buffer but could not.
        !          2350:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          2351:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          2352:  */
        !          2353: #ifdef __STDC__
        !          2354: nzerror nztEnvelope(nzctx *, nzttPersona *, ub4, nzttIdentity *,
        !          2355:                         nzttces, ub4, ub1 *, nzttBufferBlock *);
        !          2356: #else
        !          2357: nzerror nztEnvelope(/*_ nzctx *, nzttPersona *, ub4, nzttIdentity *,
        !          2358:                         nzttces, ub4, ub1 *, nzttBufferBlock * _*/);
        !          2359: #endif /* __STDC __*/
        !          2360: 
        !          2361: /*----------------------- nztDeEnvelope -----------------------*/
        !          2362: 
        !          2363: /*
        !          2364:  * NAME
        !          2365:  *    nztDeEnvelope - PKDecrypt and verify a message.
        !          2366:  * 
        !          2367:  * PARAMETERS
        !          2368:  *    osscntxt    {IN}     OSS context.
        !          2369:  *    persona     {IN}     Persona.
        !          2370:  *    state       {IN}     State of encryption.
        !          2371:  *    inlen       {IN}     Length of this input part.
        !          2372:  *    in          {IN}     This input part.
        !          2373:  *    out         {OUT}    Message from TDU.
        !          2374:  *    verified    {OUT}    TRUE if verified.
        !          2375:  *    validated   {OUT}    TRUE if validated.
        !          2376:  *    sender      {OUT}    Identity of sender.
        !          2377:  *
        !          2378:  * NOTES
        !          2379:  *    
        !          2380:  * RETURNS
        !          2381:  *    NZERROR_OK           Success.
        !          2382:  *    NZERROR_TK_CANTGROW  Needed to grow TDU buffer but could not.
        !          2383:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          2384:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          2385:  */
        !          2386: #ifdef __STDC__
        !          2387: nzerror nztDeEnvelope(nzctx *, nzttPersona *, nzttces, ub4, ub1 *,
        !          2388:                           nzttBufferBlock *, boolean *, boolean *,
        !          2389:                           nzttIdentity **);
        !          2390: #else
        !          2391: nzerror nztDeEnvelope(/*_ nzctx *, nzttPersona *, nzttces, ub4, ub1 *,
        !          2392:                           nzttBufferBlock *, boolean *, boolean *,
        !          2393:                           nzttIdentity ** _*/);
        !          2394: #endif /* __STDC __*/
        !          2395: 
        !          2396: /*----------------------- nztKeyedHash -----------------------*/
        !          2397: 
        !          2398: /*
        !          2399:  * NAME
        !          2400:  *    nztKeyedHash - Generate a keyed hash.
        !          2401:  * 
        !          2402:  * PARAMETERS
        !          2403:  *    osscntxt {IN}     OSS context.
        !          2404:  *    persona  {IN}     Persona.
        !          2405:  *    state    {IN}     State of hash.
        !          2406:  *    inlen    {IN}     Length of this input.
        !          2407:  *    in       {IN}     This input.
        !          2408:  *    tdu      {IN/OUT} Output tdu.
        !          2409:  * 
        !          2410:  * NOTES
        !          2411:  *    
        !          2412:  * RETURNS
        !          2413:  *    NZERROR_OK           Success.
        !          2414:  *    NZERROR_TK_CANTGROW  Needed to grow TDU buffer but could not.
        !          2415:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          2416:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          2417:  */
        !          2418: #ifdef __STDC__
        !          2419: nzerror nztKeyedHash(nzctx *, nzttPersona *, nzttces, ub4, ub1 *,
        !          2420:                          nzttBufferBlock *);
        !          2421: #else
        !          2422: nzerror nztKeyedHash(/*_ nzctx *, nzttPersona *, nzttces, ub4, ub1 *,
        !          2423:                          nzttBufferBlock * _*/);
        !          2424: #endif /* __STDC __*/
        !          2425: 
        !          2426: /*------------------ nztxKeyedHashExpansion ------------------*/
        !          2427: 
        !          2428: /*
        !          2429:  * NAME
        !          2430:  *    nztxKeyedHashExpansion - Determine the space needed for a keyed hash.
        !          2431:  * 
        !          2432:  * PARAMETERS
        !          2433:  *    osscntxt {IN}  OSS context.
        !          2434:  *    persona  {IN}  Persona.
        !          2435:  *    inlen    {IN}  Length of this input.
        !          2436:  *    tdulen   {OUT} TDU length.
        !          2437:  * 
        !          2438:  * NOTES
        !          2439:  *    
        !          2440:  * RETURNS
        !          2441:  *    NZERROR_OK           Success.
        !          2442:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          2443:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          2444:  */
        !          2445: #ifdef __STDC__
        !          2446: nzerror nztxKeyedHashExpansion(nzctx *, nzttPersona *, ub4, 
        !          2447:                                    ub4 *);
        !          2448: #else
        !          2449: nzerror nztxKeyedHashExpansion(/*_ nzctx *, nzttPersona *, ub4, 
        !          2450:                                    ub4 * _*/);
        !          2451: #endif /* __STDC __*/
        !          2452: 
        !          2453: /*--------------------- nztxHashExpansion ---------------------*/
        !          2454: 
        !          2455: /*
        !          2456:  * NAME
        !          2457:  *    nztxHashExpansion - Determine the size of the TDU for a hash.
        !          2458:  * 
        !          2459:  * PARAMETERS
        !          2460:  *    osscntxt {IN}  OSS context.
        !          2461:  *    persona  {IN}  Persona.
        !          2462:  *    inlen    {IN}  Length of this input.
        !          2463:  *    tdulen   {OUT} TDU length.
        !          2464:  * 
        !          2465:  * NOTES
        !          2466:  *    
        !          2467:  * RETURNS
        !          2468:  *    NZERROR_OK           Success.
        !          2469:  *    NZERROR_TK_NOTOPEN   Persona is not open.
        !          2470:  *    NZERROR_TK_NOTSUPP   Function not supported with persona.
        !          2471:  */
        !          2472: #ifdef __STDC__
        !          2473: nzerror nztxHashExpansion(nzctx *, nzttPersona *, ub4, ub4 *);
        !          2474: #else
        !          2475: nzerror nztxHashExpansion(/*_ nzctx *, nzttPersona *, ub4, ub4 * _*/);
        !          2476: #endif /* __STDC __*/
        !          2477: 
        !          2478: /*---------------- nztiae_IsAuthEnabled ----------------*/
        !          2479: 
        !          2480: /*
        !          2481:  * NAME
        !          2482:  *     nztiae_IsAuthEnabled -  Checks to see if Authentication is Enabled
        !          2483:  *                               in the current Cipher Spec.
        !          2484:  * 
        !          2485:  * PARAMETERS
        !          2486:  *     ctx     {IN}    Oracle SSL Context
        !          2487:  *      ncipher {IN}    CipherSuite
        !          2488:  *      authEnabled {OUT} Boolean for is Auth Enabled?
        !          2489:  * 
        !          2490:  * NOTES
        !          2491:  *     
        !          2492:  * RETURNS
        !          2493:  *      NZERROR_OK on success.
        !          2494:  *      NZERROR_TK_INV_CIPHR_TYPE if Cipher Spec is not Recognized.
        !          2495:  */
        !          2496: 
        !          2497: #ifdef __STDC__
        !          2498: nzerror nztiae_IsAuthEnabled( nzctx *, ub2, boolean *);
        !          2499: #else
        !          2500: nzerror nztiae_IsAuthEnabled(/*_ nzctx *ctx, 
        !          2501:                                   ub2 ncipher, 
        !          2502:                                   boolean *authEnabled _*/);
        !          2503: #endif
        !          2504: 
        !          2505: /*---------------- nztiee_IsEncrEnabled ----------------*/
        !          2506: /*
        !          2507:  * NAME
        !          2508:  *     nztiee_IsEncrEnabled -  Checks to see if Encryption is Enabled
        !          2509:  *                               in the current Cipher Spec.
        !          2510:  * 
        !          2511:  * PARAMETERS
        !          2512:  *     ctx     {IN}    Oracle SSL Context
        !          2513:  *      ncipher {IN}    CipherSuite
        !          2514:  *      EncrEnabled {OUT} Boolean for is Auth Enabled?
        !          2515:  * 
        !          2516:  * NOTES
        !          2517:  *     
        !          2518:  * RETURNS
        !          2519:  *      NZERROR_OK on success.
        !          2520:  *      NZERROR_TK_INV_CIPHR_TYPE if Cipher Spec is not Recognized.
        !          2521:  */
        !          2522: 
        !          2523: #ifdef __STDC__
        !          2524: nzerror nztiee_IsEncrEnabled( nzctx *, ub2, boolean *);
        !          2525: #else
        !          2526: nzerror nztiee_IsEncrEnabled(/*_ nzctx *ctx, 
        !          2527:                                   ub2 ncipher, 
        !          2528:                                   boolean *EncrEnabled _*/);
        !          2529: #endif
        !          2530: /*---------------- nztihe_IsHashEnabled ----------------*/
        !          2531: /*
        !          2532:  * NAME
        !          2533:  *     nztihe_IsHashEnabled -  Checks to see if HAshing is Enabled
        !          2534:  *                               in the current Cipher Spec.
        !          2535:  * 
        !          2536:  * PARAMETERS
        !          2537:  *     ctx     {IN}    Oracle SSL Context
        !          2538:  *      ncipher {IN}    CipherSuite
        !          2539:  *      hashEnabled {OUT} Boolean for is Auth Enabled?
        !          2540:  * 
        !          2541:  * NOTES
        !          2542:  *     
        !          2543:  * RETURNS
        !          2544:  *      NZERROR_OK on success.
        !          2545:  *      NZERROR_TK_INV_CIPHR_TYPE if Cipher Spec is not Recognized.
        !          2546:  */
        !          2547: 
        !          2548: #ifdef __STDC__
        !          2549: nzerror nztihe_IsHashEnabled( nzctx *, ub2, boolean *);
        !          2550: #else
        !          2551: nzerror nztihe_IsHashEnabled(/*_ nzctx *ctx, 
        !          2552:                                   ub2 ncipher, 
        !          2553:                                   boolean *hashEnabled _*/);
        !          2554: #endif
        !          2555: #endif /* NZT_ORACLE */
        !          2556: 

E-mail: