亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來(lái)到蟲(chóng)蟲(chóng)下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲(chóng)蟲(chóng)下載站

?? rsa.h

?? IBE是一種非對(duì)稱密碼技術(shù)
?? H
字號(hào):
/* Copyright 2005-2006, Voltage Security, all rights reserved.
 */

#include "vibecrypto.h"
#include "environment.h"
#include "base.h"
#include "libctx.h"
#include "paramobj.h"
#include "algobj.h"
#include "keyobj.h"
#include "mpint.h"
#include "surrender.h"

#ifndef _RSA_H
#define _RSA_H

#ifdef __cplusplus
extern "C" {
#endif

typedef struct
{
  unsigned int modLenBits;
  unsigned int usageFlag;
  VtItem pubExpo;
} VoltRSAKeyPairGenInfo;

typedef struct
{
  VtMpIntCtx     mpCtx;
  unsigned int   modBits;
  unsigned int   usageFlag;
  unsigned int   prime1Bits;
  unsigned int   prime2Bits;
  VtItem         prime1;
  VtItem         prime2;
  VtItem         expo1;
  VtItem         expo2;
  VtItem         coeff;
  VtItem         modulus;
  VtItem         priExpo;
  VtItem         pubExpo;
} VoltRsaKeyGenCtx;

/* This is called by VtKeyParamRSAPublicVerify or
 * VtKeyParamRSAPublicEncrypt. It's just like a KeyParam except it has
 * the usageFlag arg.
 * <p>The usageFlag arg must be either
 * <pre>
 * <code>
 *    VT_RSA_KEY_USAGE_SIGN_VERIFY
 *    VT_RSA_KEY_USAGE_ENCRYPT_DECRYPT
 * </code>
 * </pre>
 */
int VOLT_CALLING_CONV VoltKeyParamRSAPublic VOLT_PROTO_LIST ((
   VtKeyObject object,
   Pointer info,
   unsigned int flag,
   unsigned int usageFlag
));

/* This is called by VtKeyParamRSAPrivateSign or
 * VtKeyParamRSAPrivateDecrypt. It's just like a KeyParam except it has
 * the usageFlag arg.
 * <p>The usageFlag arg must be either
 * <pre>
 * <code>
 *    VT_RSA_KEY_USAGE_SIGN_VERIFY
 *    VT_RSA_KEY_USAGE_ENCRYPT_DECRYPT
 * </code>
 * </pre>
 */
int VOLT_CALLING_CONV VoltKeyParamRSAPrivate VOLT_PROTO_LIST ((
   VtKeyObject object,
   Pointer info,
   unsigned int flag,
   unsigned int usageFlag
));

/* Implements VGenerateKey.
 */
int VOLT_CALLING_CONV RSAGenerateKeyPair VOLT_PROTO_LIST ((
   VtKeyObject priKey,
   VtKeyObject pubKey,
   VtRandomObject random
));

/* This is how RSA keys are stored internally.
 * Each of the types, public, private and key pair, must begin with the
 * keyType field, a flag so we can know what the struct is. It will be
 * set to one of the following values.
 *
 *    VOLT_KEY_TYPE_PUBLIC
 *    VOLT_KEY_TYPE_PRIVATE
 *    VOLT_KEY_TYPE_PAIR
 *
 * The public and private key types must look alike from the top down
 * to where the private key adds the private exponent and CRT info.
 * They can both be dereferenced as a public key and the keyItems will
 * be in the same place.
 */
typedef struct
{
  UInt32 type;
  VtRSAPriKeyInfo *keyItems;
  VoltMpInt *modulus;
  VoltMpInt *pubExpo;
  VoltMpInt *priExpo;
  VoltMpInt *prime1;
  VoltMpInt *prime2;
  VoltMpInt *expo1;
  VoltMpInt *expo2;
  VoltMpInt *coeff;
} VoltRsaPrivateKey;

typedef struct
{
  UInt32 type;
  VtRSAPubKeyInfo *keyItems;
  VoltMpInt *modulus;
  VoltMpInt *pubExpo;
} VoltRsaPublicKey;

typedef struct
{
  unsigned int type;
  VtKeyObject pubKey;
  VtKeyObject priKey;
} VoltRsaKeyPair;

/* The tempKey is for when the actual key object passed in is not a
 * regular toolkit RSA private key, but one in which the data is
 * available. We'll build a temp key object to build the required key
 * data.
 * <p>The digester is created by the DER decoder. An RSA signing algID
 * will be for "RSA with SHA-1" or "RSA with SHA256" or so on. When we
 * create the algorithm object, we'll create the digester as well. This
 * is so VtAlgorithmParamSigDigestAlgObj will be able to return an
 * object.
 */
typedef struct
{
  VoltRsaPrivateKey  *priKeyData;
  VoltRsaPublicKey   *pubKeyData;
  VtKeyObject         tempKey;
  VtAlgorithmObject   digester;
} VoltRsaSignCtx;

/* Encrypt and decrypt using RSA. This determines if a pub and pri key
 * are indeed RSA partners. The data to encrypt and the encrypted data
 * are "thrown away", this function only determines if the keys are
 * indeed partners.
 * <p>If the two are partners, this function will return 0. If the keys
 * are not, the function will return an error code.
 * <p>This routine assumes that the random object is valid.
 *
 * @param libCtx The libCtx to use.
 * @param surrCtx If not NULL, pass it on to signing and verifying
 * objects.
 * @param usageFlag SIGN_VERIFY or ENCRYPT_DECRYPT.
 * @param pubKey The alleged public key.
 * @param priKey The alleged private key.
 * @param random A random object to use as a source of any random bytes
 * if needed.
 * @return an int, 0 if the function completed successfully or a
 * non-zero error code.
 */
int VOLT_CALLING_CONV VoltTestRsaKeyPair VOLT_PROTO_LIST ((
   VoltLibCtx *libCtx,
   VoltSurrenderCtx *surrCtx,
   unsigned int usageFlag,
   VtKeyObject pubKey,
   VtKeyObject priKey,
   VtRandomObject random
));

/* Implements VCloneObject.
 */
int VOLT_CALLING_CONV VoltCloneRsaPubKey VOLT_PROTO_LIST ((
   Pointer sourceObject,
   Pointer *destObject
));

/* Implements VCloneObject.
 */
int VOLT_CALLING_CONV VoltCloneRsaPriKey VOLT_PROTO_LIST ((
   Pointer sourceObject,
   Pointer *destObject
));

/* Implements VCtxDestroy.
 */
void VOLT_CALLING_CONV RSAKeyPairDataDestroy VOLT_PROTO_LIST ((
   Pointer obj,
   Pointer ctx
));

/* Implements VCtxDestroy.
 */
void VOLT_CALLING_CONV RSAKeyDataDestroy VOLT_PROTO_LIST ((
   Pointer obj,
   Pointer ctx
));

/* Implements VGetOutputSize.
 */
int VOLT_CALLING_CONV RSAEncryptGetOutputSize VOLT_PROTO_LIST ((
   VoltAlgorithmObject *obj,
   unsigned int callFlag,
   unsigned char *input,
   unsigned int inputLen,
   unsigned int *outputSize,
   unsigned int *leftovers,
   VtRandomObject random
));

/* Implements VEncryptInit.
 */
int VOLT_CALLING_CONV RSAEncryptInit VOLT_PROTO_LIST ((
   VoltAlgorithmObject *algObj,
   VoltKeyObject *keyObj
));

/* Implements VEncryptUpdate.
 */
int VOLT_CALLING_CONV RSAEncryptUpdate VOLT_PROTO_LIST ((
   VoltAlgorithmObject *algObj,
   VtRandomObject random,
   unsigned char *dataToEncrypt,
   unsigned int dataToEncryptLen,
   unsigned char *encryptedData
));

/* Implements VWrapKey.
 */
int VOLT_CALLING_CONV RSAWrapKey VOLT_PROTO_LIST ((
   VoltAlgorithmObject *algObj,
   VtRandomObject random,
   VoltKeyObject *keyToWrap,
   unsigned char *encryptedKey,
   unsigned int bufferSize,
   unsigned int *encryptedKeyLen
));

/* Implements VDecryptInit.
 */
int VOLT_CALLING_CONV RSADecryptInit VOLT_PROTO_LIST ((
   VoltAlgorithmObject *algObj,
   VoltKeyObject *keyObj
));

/* Implements VDecryptUpdate.
 */
int VOLT_CALLING_CONV RSADecryptUpdate VOLT_PROTO_LIST ((
   VoltAlgorithmObject *algObj,
   VtRandomObject random,
   unsigned char *dataToDecrypt,
   unsigned int dataToDecryptLen,
   unsigned char *decryptedData
));

/* Implements VUnwrapKey.
 */
int VOLT_CALLING_CONV RSAUnwrapKey VOLT_PROTO_LIST ((
   VoltAlgorithmObject *algObj,
   VtRandomObject random,
   unsigned char *encryptedKey,
   unsigned int encryptedKeyLen,
   VtKeyParam KeyParam,
   VtKeyObject unwrappedKey
));

/* Implements VCtxDestroy.
 */
void VOLT_CALLING_CONV RSACipherClassCtxDestroy VOLT_PROTO_LIST ((
   Pointer obj,
   Pointer ctx
));

/* Implements VCheckSignatureInput.
 */
int VOLT_CALLING_CONV RSACheckSignatureInput VOLT_PROTO_LIST ((
   VoltAlgorithmObject *obj,
   VoltKeyObject *key,
   VtRandomObject random,
   unsigned char *dataToSign,
   unsigned int dataToSignLen,
   unsigned int *signatureSize
));

/* Implements VSignData.
 */
int VOLT_CALLING_CONV RSASignData VOLT_PROTO_LIST ((
   VoltAlgorithmObject *obj,
   VoltKeyObject *key,
   VtRandomObject random,
   unsigned char *dataToSign,
   unsigned int dataToSignLen,
   unsigned char *signature,
   unsigned int *sigLen
));

/* Implements VVerifyData.
 */
int VOLT_CALLING_CONV RSAVerifyData VOLT_PROTO_LIST ((
   VoltAlgorithmObject *obj,
   VoltKeyObject *key,
   VtRandomObject random,
   unsigned char *dataToVerify,
   unsigned int dataToVerifyLen,
   unsigned char *signature,
   unsigned int sigLen,
   unsigned int *verifyResult
));

/* Implements VCtxDestroy.
 */
void VOLT_CALLING_CONV RSASignCtxDestroy VOLT_PROTO_LIST ((
   Pointer obj,
   Pointer ctx
));

/* Implements VGetDigestObject.
 */
int VOLT_CALLING_CONV RSAGetDigestObject VOLT_PROTO_LIST ((
   VoltAlgorithmObject *obj,
   VtAlgorithmObject *digestObj
));

/* How long is the digest length for the given digestAlg?
 * <p>If the digestAlg is a flag for an unknown digest, return an error.
 * <p>This function also returns the X9.31 identifier byte, just in
 * case the caller needs it. The caller can pass a NULL pointer for the
 * X9.31 byte if that info is not needed.
 */
int VOLT_CALLING_CONV VoltGetDigestLenFromAlg VOLT_PROTO_LIST ((
   VoltLibCtx *libCtx,
   unsigned int digestAlg,
   unsigned int *digestLen,
   unsigned int *x931Byte
));

#ifdef __cplusplus
}
#endif

#endif /* _RSA_H */

?? 快捷鍵說(shuō)明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日韩小视频在线观看专区| 国产成人精品亚洲日本在线桃色| 蜜臀久久99精品久久久久久9| 久草中文综合在线| 99久久夜色精品国产网站| 精品婷婷伊人一区三区三| 欧美精品一区二区三区在线播放| 中文字幕va一区二区三区| 亚洲gay无套男同| 国产精一区二区三区| 在线视频你懂得一区二区三区| 欧美大度的电影原声| 亚洲人精品午夜| 麻豆精品一区二区综合av| 91视频www| 日韩欧美久久一区| 一区二区三区四区在线| 精品一区二区三区在线观看| 99久久99久久免费精品蜜臀| 欧美一区二区三区喷汁尤物| 国产精品久久毛片a| 日本人妖一区二区| 色域天天综合网| 国产婷婷色一区二区三区| 亚洲成av人片在线| 99免费精品在线观看| 精品国产一区二区亚洲人成毛片| 一区二区三区免费看视频| 极品少妇xxxx偷拍精品少妇| 欧洲一区在线电影| 中文字幕在线观看不卡| 激情都市一区二区| 欧美日韩和欧美的一区二区| 亚洲日本一区二区三区| 国产福利不卡视频| 欧美v国产在线一区二区三区| 亚洲在线免费播放| 成人丝袜18视频在线观看| 日韩久久久久久| 日韩中文字幕区一区有砖一区| 99久久99久久精品国产片果冻| 国产性天天综合网| 蜜桃视频在线观看一区| 欧美日韩国产综合草草| 亚洲黄网站在线观看| 粉嫩13p一区二区三区| 欧美成人bangbros| 天堂成人国产精品一区| 91网址在线看| 国产精品激情偷乱一区二区∴| 激情偷乱视频一区二区三区| 日韩午夜中文字幕| 免费久久精品视频| 欧美精品久久久久久久久老牛影院| 一区二区三区.www| 色国产精品一区在线观看| 《视频一区视频二区| thepron国产精品| 国产欧美1区2区3区| 国产精品影视网| 337p粉嫩大胆噜噜噜噜噜91av| 久久精品国产**网站演员| 日韩一区二区三区视频在线观看| 天堂在线一区二区| 欧美日韩一区精品| 亚洲丰满少妇videoshd| 欧美性受xxxx| 亚洲成人在线网站| 欧美妇女性影城| 日韩精品一二三区| 日韩精品一区二区三区swag| 久久精品国产亚洲一区二区三区| 日韩欧美在线一区二区三区| 另类综合日韩欧美亚洲| 久久伊人中文字幕| 夫妻av一区二区| 中文字幕一区二区三区在线不卡| 国产不卡视频在线播放| 国产精品久久久久aaaa| 99在线热播精品免费| 玉足女爽爽91| 欧美日韩高清在线| 青青草97国产精品免费观看无弹窗版 | 一本大道久久a久久精二百| 一区二区在线免费| 欧美日韩国产片| 久久精品国产亚洲a| 精品国产三级电影在线观看| 粉嫩一区二区三区性色av| 中文字幕亚洲精品在线观看 | 亚洲综合清纯丝袜自拍| 欧美日韩精品一区二区在线播放 | 久久婷婷国产综合国色天香| 成人爱爱电影网址| 亚洲色图欧洲色图| 欧美日韩免费一区二区三区视频| 免费成人在线视频观看| 久久久99久久| 91老师国产黑色丝袜在线| 亚洲第一综合色| 精品免费一区二区三区| 北条麻妃国产九九精品视频| 亚洲男女一区二区三区| 91精品国产欧美一区二区| 国产精品91一区二区| 亚洲青青青在线视频| 91精品啪在线观看国产60岁| 国产精品综合一区二区三区| 自拍偷在线精品自拍偷无码专区| 8x8x8国产精品| 成人高清免费观看| 午夜视频在线观看一区二区三区| 精品国产91久久久久久久妲己| 91在线视频免费观看| 奇米一区二区三区| 国产精品二三区| 制服丝袜日韩国产| 成人app下载| 日本免费在线视频不卡一不卡二| 欧美国产乱子伦| 欧美区在线观看| 成人深夜在线观看| 免费观看一级欧美片| 日韩伦理av电影| 精品日韩一区二区三区免费视频| 色婷婷久久久久swag精品| 久久成人久久鬼色| 一二三区精品福利视频| 久久久综合九色合综国产精品| 欧美最猛性xxxxx直播| 国产一区二区三区在线观看免费| 一个色综合网站| 国产日韩欧美一区二区三区综合| 欧美三级视频在线播放| 国产不卡在线播放| 蜜臀av性久久久久av蜜臀妖精 | 欧美日韩黄色影视| 国产成人自拍高清视频在线免费播放| 亚洲亚洲精品在线观看| 中文字幕不卡的av| xnxx国产精品| 欧美一区二区精美| 欧美中文字幕久久| av影院午夜一区| 国产成人在线视频网站| 奇米精品一区二区三区在线观看一 | 久久精品国内一区二区三区| 亚洲国产日日夜夜| 国产精品国产三级国产aⅴ原创 | 成人一区二区在线观看| 久久国产精品一区二区| 丝袜亚洲精品中文字幕一区| 椎名由奈av一区二区三区| 国产欧美日韩精品一区| 精品卡一卡二卡三卡四在线| 欧美日韩极品在线观看一区| 在线欧美日韩精品| 色综合天天在线| 9人人澡人人爽人人精品| 国产成人午夜高潮毛片| 精品一区免费av| 男女性色大片免费观看一区二区 | 91精品国产麻豆国产自产在线 | 自拍偷自拍亚洲精品播放| 国产三级精品在线| 久久视频一区二区| 精品国产区一区| 欧美r级电影在线观看| 欧美一区二区三区免费| 欧美疯狂性受xxxxx喷水图片| 欧美日韩一二三区| 欧美日韩不卡一区二区| 欧美日韩国产影片| 欧美日韩1区2区| 欧美日韩精品久久久| 欧美日韩亚洲综合| 欧美日韩视频在线第一区 | 日韩成人午夜电影| 婷婷综合另类小说色区| 五月天亚洲婷婷| 午夜久久福利影院| 日本免费新一区视频| 免费成人小视频| 看片网站欧美日韩| 国产精品伊人色| 风间由美性色一区二区三区| 成人久久视频在线观看| 99久久国产综合精品色伊| 色哟哟一区二区在线观看| 欧美三级视频在线| 91精品婷婷国产综合久久竹菊| 日韩一区二区三区在线观看| 久久综合久久综合久久综合| 国产午夜亚洲精品午夜鲁丝片| 中文字幕精品一区二区精品绿巨人| 中文字幕一区二区三中文字幕| 亚洲色图丝袜美腿| 性久久久久久久久| 激情综合色综合久久综合| 粗大黑人巨茎大战欧美成人|