pgpp11key.h

来自「可以实现对邮件的加密解密以及签名」· C头文件 代码 · 共 66 行

H
66
字号
/*
 * $Id: pgpP11Key.h,v 1.25 2001/09/25 23:25:23 hal Exp $
 */

#ifndef Included_pgpP11Key_h
#define Included_pgpP11Key_h


#include "pgpSDKBuildFlags.h"

#include "pgpPubTypes.h"	/* For PGPBoolean and PGPByte */
#include "pgpOpaqueStructs.h"
#include "pgpThreads.h"

PGP_BEGIN_C_DECLARATIONS

PGPPubKey *p11PubFromBuf(PGPContextRef	context,
				PGPByte const *buf, PGPSize len, PGPError *error);
				
PGPSecKey *p11SecFromBuf( PGPContextRef	context,
				PGPByte const *buf, PGPSize len, PGPBoolean v3,
				void *tok, PGPError *error);
				
int p11PubKeyPrefixSize(PGPByte const *buf, PGPSize size);

PGPSecKey *p11SecGenerate( PGPContextRef context, PGPByte pkalg, unsigned bits,
				PGPBoolean fastgen, PGPBoolean v3,
				int progress(void *arg, int c), void *arg,
				void *tok, PGPByte const *passphrase, PGPSize phraseLength,
				PGPBoolean genMaster, PGPError *error);


PGPToken *pgpTokenFromKeyID( const PGPByte *keyid );
PGPToken *pgpTokenGetIndexed( PGPUInt32 tokenID );
PGPUInt32 pgpTokenGetCount( void );
PGPError pgpSetKeyTokenNum( PGPKeyDBObj *key, PGPToken *token );
PGPError pgpGetTokenInfo( PGPUInt32 toknumber, PGPTokenInfo *tokenInfo );
PGPError pgpTokenWipe( PGPContextRef context, PGPUInt32 tokenID, PGPByte const *passphrase,
					   PGPSize passphraseLength );
PGPError pgpTokenFormat(PGPContextRef	context, 
						PGPUInt32		toknumber,
						PGPByte const *	adminPin,	PGPSize	adminPinLen, 
						PGPByte const *	newUserPin,	PGPSize	newUserPinLen );
PGPError pgpTokenCheckPassphrase( PGPUInt32 tokenID, PGPByte const *passphrase,
					   PGPSize passphraseLength );
PGPError pgpSyncTokenToKeyDB( PGPContextRef context, PGPKeyDBRef fixedkdb,
							  PGPBoolean doNotify );
PGPError pgpPollTokens( PGPContextRef context );
PGPError pgpTokenCopyPrivKeyToToken( PGPContextRef context, PGPKeyDBObjRef key,
			PGPBoolean	isMaster,
			PGPByte const *passphrase,
			PGPSize passphraseLength, PGPBoolean hashed,
			PGPByte const *PIN, PGPSize PINlength,
			PGPUInt32 toknumber);
PGPError pgpTokenCopyPubKeyToToken( PGPContextRef context, PGPKeyDBObjRef key,
			PGPUInt32 toknumber, PGPToken *tok );
PGPError pgpDeleteKeyOnToken( PGPContextRef context, 
			const PGPKeyID *keyID, PGPUInt32 toknumber );

PGPError pgpUnloadTCL();
PGPError pgpTokenFreeTCLMem( void *p );

PGP_END_C_DECLARATIONS

#endif /* Included_pgpP11Key_h */

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?