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

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? pem.h

?? openssl加密例子
?? H
?? 第 1 頁 / 共 2 頁
字號:
/* crypto/pem/pem.h */
/* Copyright (C) 1995-1997 Eric Young (eay@cryptsoft.com)
 * All rights reserved.
 *
 * This package is an SSL implementation written
 * by Eric Young (eay@cryptsoft.com).
 * The implementation was written so as to conform with Netscapes SSL.
 * 
 * This library is free for commercial and non-commercial use as long as
 * the following conditions are aheared to.  The following conditions
 * apply to all code found in this distribution, be it the RC4, RSA,
 * lhash, DES, etc., code; not just the SSL code.  The SSL documentation
 * included with this distribution is covered by the same copyright terms
 * except that the holder is Tim Hudson (tjh@cryptsoft.com).
 * 
 * Copyright remains Eric Young's, and as such any Copyright notices in
 * the code are not to be removed.
 * If this package is used in a product, Eric Young should be given attribution
 * as the author of the parts of the library used.
 * This can be in the form of a textual message at program startup or
 * in documentation (online or textual) provided with the package.
 * 
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions
 * are met:
 * 1. Redistributions of source code must retain the copyright
 *    notice, this list of conditions and the following disclaimer.
 * 2. Redistributions in binary form must reproduce the above copyright
 *    notice, this list of conditions and the following disclaimer in the
 *    documentation and/or other materials provided with the distribution.
 * 3. All advertising materials mentioning features or use of this software
 *    must display the following acknowledgement:
 *    "This product includes cryptographic software written by
 *     Eric Young (eay@cryptsoft.com)"
 *    The word 'cryptographic' can be left out if the rouines from the library
 *    being used are not cryptographic related :-).
 * 4. If you include any Windows specific code (or a derivative thereof) from 
 *    the apps directory (application code) you must include an acknowledgement:
 *    "This product includes software written by Tim Hudson (tjh@cryptsoft.com)"
 * 
 * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND
 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 * SUCH DAMAGE.
 * 
 * The licence and distribution terms for any publically available version or
 * derivative of this code cannot be changed.  i.e. this code cannot simply be
 * copied and put under another distribution licence
 * [including the GNU Public Licence.]
 */

#ifndef HEADER_PEM_H
#define HEADER_PEM_H

#ifndef OPENSSL_NO_BIO
#include <openssl/bio.h>
#endif
#ifndef OPENSSL_NO_STACK
#include <openssl/stack.h>
#endif
#include <openssl/evp.h>
#include <openssl/x509.h>
#include <openssl/pem2.h>
#include <openssl/e_os2.h>

#ifdef  __cplusplus
extern "C" {
#endif

#define PEM_BUFSIZE		1024

#define PEM_OBJ_UNDEF		0
#define PEM_OBJ_X509		1
#define PEM_OBJ_X509_REQ	2
#define PEM_OBJ_CRL		3
#define PEM_OBJ_SSL_SESSION	4
#define PEM_OBJ_PRIV_KEY	10
#define PEM_OBJ_PRIV_RSA	11
#define PEM_OBJ_PRIV_DSA	12
#define PEM_OBJ_PRIV_DH		13
#define PEM_OBJ_PUB_RSA		14
#define PEM_OBJ_PUB_DSA		15
#define PEM_OBJ_PUB_DH		16
#define PEM_OBJ_DHPARAMS	17
#define PEM_OBJ_DSAPARAMS	18
#define PEM_OBJ_PRIV_RSA_PUBLIC	19

#define PEM_ERROR		30
#define PEM_DEK_DES_CBC         40
#define PEM_DEK_IDEA_CBC        45
#define PEM_DEK_DES_EDE         50
#define PEM_DEK_DES_ECB         60
#define PEM_DEK_RSA             70
#define PEM_DEK_RSA_MD2         80
#define PEM_DEK_RSA_MD5         90

#define PEM_MD_MD2		NID_md2
#define PEM_MD_MD5		NID_md5
#define PEM_MD_SHA		NID_sha
#define PEM_MD_MD2_RSA		NID_md2WithRSAEncryption
#define PEM_MD_MD5_RSA		NID_md5WithRSAEncryption
#define PEM_MD_SHA_RSA		NID_sha1WithRSAEncryption

#define PEM_STRING_X509_OLD	"X509 CERTIFICATE"
#define PEM_STRING_X509		"CERTIFICATE"
#define PEM_STRING_X509_TRUSTED	"TRUSTED CERTIFICATE"
#define PEM_STRING_X509_REQ_OLD	"NEW CERTIFICATE REQUEST"
#define PEM_STRING_X509_REQ	"CERTIFICATE REQUEST"
#define PEM_STRING_X509_CRL	"X509 CRL"
#define PEM_STRING_EVP_PKEY	"ANY PRIVATE KEY"
#define PEM_STRING_PUBLIC	"PUBLIC KEY"
#define PEM_STRING_RSA		"RSA PRIVATE KEY"
#define PEM_STRING_RSA_PUBLIC	"RSA PUBLIC KEY"
#define PEM_STRING_DSA		"DSA PRIVATE KEY"
#define PEM_STRING_DSA_PUBLIC	"DSA PUBLIC KEY"
#define PEM_STRING_PKCS7	"PKCS7"
#define PEM_STRING_PKCS8	"ENCRYPTED PRIVATE KEY"
#define PEM_STRING_PKCS8INF	"PRIVATE KEY"
#define PEM_STRING_DHPARAMS	"DH PARAMETERS"
#define PEM_STRING_SSL_SESSION	"SSL SESSION PARAMETERS"
#define PEM_STRING_DSAPARAMS	"DSA PARAMETERS"

  /* Note that this structure is initialised by PEM_SealInit and cleaned up
     by PEM_SealFinal (at least for now) */
typedef struct PEM_Encode_Seal_st
	{
	EVP_ENCODE_CTX encode;
	EVP_MD_CTX md;
	EVP_CIPHER_CTX cipher;
	} PEM_ENCODE_SEAL_CTX;

/* enc_type is one off */
#define PEM_TYPE_ENCRYPTED      10
#define PEM_TYPE_MIC_ONLY       20
#define PEM_TYPE_MIC_CLEAR      30
#define PEM_TYPE_CLEAR		40

typedef struct pem_recip_st
	{
	char *name;
	X509_NAME *dn;

	int cipher;
	int key_enc;
	/*	char iv[8]; unused and wrong size */
	} PEM_USER;

typedef struct pem_ctx_st
	{
	int type;		/* what type of object */

	struct	{
		int version;	
		int mode;		
		} proc_type;

	char *domain;

	struct	{
		int cipher;
	/* unused, and wrong size
	   unsigned char iv[8]; */
		} DEK_info;
		
	PEM_USER *originator;

	int num_recipient;
	PEM_USER **recipient;

#ifndef OPENSSL_NO_STACK
	STACK *x509_chain;	/* certificate chain */
#else
	char *x509_chain;	/* certificate chain */
#endif
	EVP_MD *md;		/* signature type */

	int md_enc;		/* is the md encrypted or not? */
	int md_len;		/* length of md_data */
	char *md_data;		/* message digest, could be pkey encrypted */

	EVP_CIPHER *dec;	/* date encryption cipher */
	int key_len;		/* key length */
	unsigned char *key;	/* key */
	/* unused, and wrong size
	   unsigned char iv[8]; */

	
	int  data_enc;		/* is the data encrypted */
	int data_len;
	unsigned char *data;
	} PEM_CTX;

/* These macros make the PEM_read/PEM_write functions easier to maintain and
 * write. Now they are all implemented with either:
 * IMPLEMENT_PEM_rw(...) or IMPLEMENT_PEM_rw_cb(...)
 */

#ifdef OPENSSL_NO_FP_API

#define IMPLEMENT_PEM_read_fp(name, type, str, asn1) /**/
#define IMPLEMENT_PEM_write_fp(name, type, str, asn1) /**/
#define IMPLEMENT_PEM_write_cb_fp(name, type, str, asn1) /**/

#else

#define IMPLEMENT_PEM_read_fp(name, type, str, asn1) \
type *PEM_read_##name(FILE *fp, type **x, pem_password_cb *cb, void *u)\
{ \
return((type *)PEM_ASN1_read((char *(*)())d2i_##asn1, str,fp,(char **)x,\
	cb,u)); \
} \

#define IMPLEMENT_PEM_write_fp(name, type, str, asn1) \
int PEM_write_##name(FILE *fp, type *x) \
{ \
return(PEM_ASN1_write((int (*)())i2d_##asn1,str,fp, (char *)x, \
							 NULL,NULL,0,NULL,NULL)); \
} 

#define IMPLEMENT_PEM_write_cb_fp(name, type, str, asn1) \
int PEM_write_##name(FILE *fp, type *x, const EVP_CIPHER *enc, \
	     unsigned char *kstr, int klen, pem_password_cb *cb, \
		  void *u) \
	{ \
	return(PEM_ASN1_write((int (*)())i2d_##asn1,str,fp, \
		(char *)x,enc,kstr,klen,cb,u)); \
	}

#endif

#define IMPLEMENT_PEM_read_bio(name, type, str, asn1) \
type *PEM_read_bio_##name(BIO *bp, type **x, pem_password_cb *cb, void *u)\
{ \
return((type *)PEM_ASN1_read_bio((char *(*)())d2i_##asn1, str,bp,\
							(char **)x,cb,u)); \
}

#define IMPLEMENT_PEM_write_bio(name, type, str, asn1) \
int PEM_write_bio_##name(BIO *bp, type *x) \
{ \
return(PEM_ASN1_write_bio((int (*)())i2d_##asn1,str,bp, (char *)x, \
							 NULL,NULL,0,NULL,NULL)); \
}

#define IMPLEMENT_PEM_write_cb_bio(name, type, str, asn1) \
int PEM_write_bio_##name(BIO *bp, type *x, const EVP_CIPHER *enc, \
	     unsigned char *kstr, int klen, pem_password_cb *cb, void *u) \
	{ \
	return(PEM_ASN1_write_bio((int (*)())i2d_##asn1,str,bp, \
		(char *)x,enc,kstr,klen,cb,u)); \
	}

#define IMPLEMENT_PEM_write(name, type, str, asn1) \
	IMPLEMENT_PEM_write_bio(name, type, str, asn1) \
	IMPLEMENT_PEM_write_fp(name, type, str, asn1) 

#define IMPLEMENT_PEM_write_cb(name, type, str, asn1) \
	IMPLEMENT_PEM_write_cb_bio(name, type, str, asn1) \
	IMPLEMENT_PEM_write_cb_fp(name, type, str, asn1) 

#define IMPLEMENT_PEM_read(name, type, str, asn1) \
	IMPLEMENT_PEM_read_bio(name, type, str, asn1) \
	IMPLEMENT_PEM_read_fp(name, type, str, asn1) 

#define IMPLEMENT_PEM_rw(name, type, str, asn1) \
	IMPLEMENT_PEM_read(name, type, str, asn1) \
	IMPLEMENT_PEM_write(name, type, str, asn1)

#define IMPLEMENT_PEM_rw_cb(name, type, str, asn1) \
	IMPLEMENT_PEM_read(name, type, str, asn1) \
	IMPLEMENT_PEM_write_cb(name, type, str, asn1)

/* These are the same except they are for the declarations */

#if defined(OPENSSL_SYS_WIN16) || defined(OPENSSL_NO_FP_API)

#define DECLARE_PEM_read_fp(name, type) /**/
#define DECLARE_PEM_write_fp(name, type) /**/
#define DECLARE_PEM_write_cb_fp(name, type) /**/

#else

#define DECLARE_PEM_read_fp(name, type) \
	type *PEM_read_##name(FILE *fp, type **x, pem_password_cb *cb, void *u);

#define DECLARE_PEM_write_fp(name, type) \
	int PEM_write_##name(FILE *fp, type *x);

#define DECLARE_PEM_write_cb_fp(name, type) \
	int PEM_write_##name(FILE *fp, type *x, const EVP_CIPHER *enc, \
	     unsigned char *kstr, int klen, pem_password_cb *cb, void *u);

#endif

#ifndef OPENSSL_NO_BIO
#define DECLARE_PEM_read_bio(name, type) \
	type *PEM_read_bio_##name(BIO *bp, type **x, pem_password_cb *cb, void *u);

#define DECLARE_PEM_write_bio(name, type) \
	int PEM_write_bio_##name(BIO *bp, type *x);

#define DECLARE_PEM_write_cb_bio(name, type) \
	int PEM_write_bio_##name(BIO *bp, type *x, const EVP_CIPHER *enc, \
	     unsigned char *kstr, int klen, pem_password_cb *cb, void *u);

#else

#define DECLARE_PEM_read_bio(name, type) /**/
#define DECLARE_PEM_write_bio(name, type) /**/
#define DECLARE_PEM_write_cb_bio(name, type) /**/

#endif

#define DECLARE_PEM_write(name, type) \
	DECLARE_PEM_write_bio(name, type) \
	DECLARE_PEM_write_fp(name, type) 

#define DECLARE_PEM_write_cb(name, type) \
	DECLARE_PEM_write_cb_bio(name, type) \
	DECLARE_PEM_write_cb_fp(name, type) 

#define DECLARE_PEM_read(name, type) \
	DECLARE_PEM_read_bio(name, type) \
	DECLARE_PEM_read_fp(name, type)

#define DECLARE_PEM_rw(name, type) \
	DECLARE_PEM_read(name, type) \
	DECLARE_PEM_write(name, type)

#define DECLARE_PEM_rw_cb(name, type) \

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
久久夜色精品国产噜噜av| 91论坛在线播放| 国产成人免费在线视频| 欧美一区二区久久久| 一二三四社区欧美黄| 欧美大片在线观看| 日本不卡在线视频| 国产自产视频一区二区三区| 欧美一卡2卡三卡4卡5免费| 国产精品成人在线观看| 99精品欧美一区| 国产精品人人做人人爽人人添| 精品一区二区三区视频在线观看 | 2017欧美狠狠色| 日韩美女久久久| 丁香婷婷深情五月亚洲| 国产视频视频一区| 国产乱理伦片在线观看夜一区| 欧美一二三四在线| 国产一区91精品张津瑜| 欧美成人女星排行榜| 日韩av一级片| 在线成人高清不卡| 亚洲摸摸操操av| 久久先锋资源网| 激情综合色综合久久| 91精品国产色综合久久| 久久成人久久鬼色| 国产精品每日更新在线播放网址| 欧美在线观看视频一区二区三区| 亚洲欧美日韩在线| 欧美大片一区二区| 成人高清免费观看| 亚洲成人av一区二区| 欧美丝袜丝交足nylons图片| 亚洲国产日韩综合久久精品| 欧美不卡在线视频| 久久99国产精品成人| 国产亚洲欧美在线| 91在线视频免费观看| 国产精品护士白丝一区av| 日本乱码高清不卡字幕| 天堂成人国产精品一区| 日韩美女一区二区三区四区| 91久久精品网| 一级中文字幕一区二区| 欧美一区二区在线播放| 99国产精品一区| 91精品国产综合久久精品| 不卡的av在线播放| 亚洲视频在线观看三级| 欧美三级乱人伦电影| 成人综合激情网| 亚洲国产精品一区二区久久恐怖片| 欧美日韩成人一区| 精品日韩在线观看| 91精品国产入口在线| 菠萝蜜视频在线观看一区| 美女精品自拍一二三四| 午夜精品久久久久久不卡8050| 欧美日精品一区视频| 日韩高清不卡一区二区| 亚洲乱码中文字幕| 国产精品久久久久久久久快鸭| 欧美性欧美巨大黑白大战| 成人黄动漫网站免费app| 欧美日韩久久久久久| 亚洲成人av在线电影| 久久久五月婷婷| 精品久久久久一区| 欧美一级夜夜爽| 欧美在线观看18| 国产二区国产一区在线观看| 日韩国产在线观看| 精品少妇一区二区三区在线播放| 成人天堂资源www在线| 久久国产精品一区二区| 另类中文字幕网| 成人中文字幕在线| 欧美亚洲高清一区二区三区不卡| 极品瑜伽女神91| 精品国产一区二区三区四区四 | 国产精品嫩草99a| 亚洲免费观看高清| 亚洲欧美日韩国产另类专区| 无吗不卡中文字幕| 91精品国产综合久久久久久| 欧美激情综合五月色丁香| 2020国产精品久久精品美国| 国产精品婷婷午夜在线观看| 亚洲婷婷综合久久一本伊一区| 亚洲欧美日韩国产另类专区 | 欧美不卡一二三| 欧美国产精品一区二区| 亚洲乱码国产乱码精品精的特点| 一色桃子久久精品亚洲| 天天亚洲美女在线视频| 国产一区二区三区日韩| 777xxx欧美| 91精品国产91久久综合桃花| 色伊人久久综合中文字幕| 欧美日韩一级二级| 欧美绝品在线观看成人午夜影视| 91精品啪在线观看国产60岁| 亚洲女同ⅹxx女同tv| 久久精品久久99精品久久| 国产99久久久久| 欧美综合视频在线观看| 国产亚洲精久久久久久| 亚洲一二三四区| 成人性生交大片免费| 欧美色综合网站| 欧美va亚洲va香蕉在线| 亚洲黄网站在线观看| 另类成人小视频在线| av电影一区二区| 精品国产成人在线影院| 精品中文字幕一区二区| 99久久免费精品高清特色大片| 日韩欧美中文字幕精品| 首页欧美精品中文字幕| 成人免费看的视频| wwww国产精品欧美| 蓝色福利精品导航| 欧美一级生活片| 欧美老肥妇做.爰bbww| 中文字幕不卡在线播放| 麻豆视频观看网址久久| 蜜臀va亚洲va欧美va天堂| 色妞www精品视频| 亚洲欧美偷拍卡通变态| 欧美日韩午夜精品| 亚洲老妇xxxxxx| 色一区在线观看| 精品乱人伦一区二区三区| 不卡一区在线观看| 亚洲欧美日韩国产综合在线| 国产伦精品一区二区三区在线观看| 精品乱码亚洲一区二区不卡| 国产真实乱子伦精品视频| 亚洲欧美日韩在线| 欧美刺激午夜性久久久久久久 | 日本视频一区二区| 欧美日韩国产高清一区二区| 一区二区三区中文字幕精品精品| 99这里只有精品| 亚洲精选视频在线| www国产成人免费观看视频 深夜成人网| 久久99国产精品久久99| 国产欧美精品一区aⅴ影院 | 亚洲桃色在线一区| 欧洲在线/亚洲| 亚洲国产综合色| 久久久久国产精品厨房| 91香蕉视频黄| 午夜电影久久久| 国产日产欧美一区二区视频| 波多野结衣中文字幕一区| 亚洲影院在线观看| 精品999在线播放| 色噜噜久久综合| 日韩福利电影在线| 国产偷国产偷亚洲高清人白洁| 色美美综合视频| 亚洲不卡在线观看| 2017欧美狠狠色| 欧美日韩你懂得| 色天使久久综合网天天| 美国av一区二区| 日韩中文字幕不卡| 久久蜜桃av一区二区天堂| 欧美区一区二区三区| 国产91精品在线观看| 精品精品国产高清a毛片牛牛| av成人老司机| 99久久精品久久久久久清纯| 精品久久久久久无| 91精品国产入口在线| 91精品黄色片免费大全| 欧美日韩一区久久| 色88888久久久久久影院按摩 | 青青草精品视频| 亚洲国产精品久久一线不卡| 亚洲精品乱码久久久久久久久| 国产网站一区二区三区| 一色屋精品亚洲香蕉网站| 中文字幕制服丝袜一区二区三区| 2020国产精品自拍| 国产精品久久久久久久久免费桃花 | 欧美一区日韩一区| 欧美一区二区播放| 欧美在线观看视频一区二区三区| 成人午夜大片免费观看| 99久久久无码国产精品| 国产宾馆实践打屁股91| 99re6这里只有精品视频在线观看| 色88888久久久久久影院按摩| 在线日韩一区二区| 欧美系列日韩一区| 欧美绝品在线观看成人午夜影视|