#define APPLINK_STDIN 1
#define APPLINK_STDOUT 2
#define APPLINK_STDERR 3
#define APPLINK_FPRINTF 4
#define APPLINK_FGETS 5
#define APPLINK_FREAD 6
#define APPLINK_FWRITE 7
#define APPLINK_FSETMOD 8
#define APPLINK_FEOF 9
#define APPLINK_FCLOSE 10 /* should not be used */
#define APPLINK_FOPEN 11 /* solely for completeness */
#define APPLINK_FSEEK 12
#define APPLINK_FTELL 13
#define APPLINK_FFLUSH 14
#define APPLINK_FERROR 15
#define APPLINK_CLEARERR 16
#define APPLINK_FILENO 17 /* to be used with below */
#define APPLINK_OPEN 18 /* formally can't be used, as flags can vary */
#define APPLINK_READ 19
#define APPLINK_WRITE 20
#define APPLINK_LSEEK 21
#define APPLINK_CLOSE 22
#define APPLINK_MAX 22 /* always same as last macro */
#ifndef APPMACROS_ONLY
#include <stdio.h>
#include <io.h>
#include <fcntl.h>
static void *app_stdin(void) { return stdin; }
static void *app_stdout(void) { return stdout; }
static void *app_stderr(void) { return stderr; }
static int app_feof(FILE *fp) { return feof(fp); }
static int app_ferror(FILE *fp) { return ferror(fp); }
static void app_clearerr(FILE *fp) { clearerr(fp); }
static int app_fileno(FILE *fp) { return _fileno(fp); }
static int app_fsetmod(FILE *fp,char mod)
{ return _setmode (_fileno(fp),mod=='b'?_O_BINARY:_O_TEXT); }
#ifdef __cplusplus
extern "C" {
#endif
__declspec(dllexport)
void **
#if defined(__BORLANDC__)
__stdcall /* __stdcall appears to be the only way to get the name
* decoration right with Borland C. Otherwise it works
* purely incidentally, as we pass no parameters. */
#else
__cdecl
#endif
OPENSSL_Applink(void)
{ static int once=1;
static void *OPENSSL_ApplinkTable[APPLINK_MAX+1]={(void *)APPLINK_MAX};
if (once)
{ OPENSSL_ApplinkTable[APPLINK_STDIN] = app_stdin;
OPENSSL_ApplinkTable[APPLINK_STDOUT] = app_stdout;
OPENSSL_ApplinkTable[APPLINK_STDERR] = app_stderr;
OPENSSL_ApplinkTable[APPLINK_FPRINTF] = fprintf;
OPENSSL_ApplinkTable[APPLINK_FGETS] = fgets;
OPENSSL_ApplinkTable[APPLINK_FREAD] = fread;
OPENSSL_ApplinkTable[APPLINK_FWRITE] = fwrite;
OPENSSL_ApplinkTable[APPLINK_FSETMOD] = app_fsetmod;
OPENSSL_ApplinkTable[APPLINK_FEOF] = app_feof;
OPENSSL_ApplinkTable[APPLINK_FCLOSE] = fclose;
OPENSSL_ApplinkTable[APPLINK_FOPEN] = fopen;
OPENSSL_ApplinkTable[APPLINK_FSEEK] = fseek;
OPENSSL_ApplinkTable[APPLINK_FTELL] = ftell;
OPENSSL_ApplinkTable[APPLINK_FFLUSH] = fflush;
OPENSSL_ApplinkTable[APPLINK_FERROR] = app_ferror;
OPENSSL_ApplinkTable[APPLINK_CLEARERR] = app_clearerr;
OPENSSL_ApplinkTable[APPLINK_FILENO] = app_fileno;
OPENSSL_ApplinkTable[APPLINK_OPEN] = _open;
OPENSSL_ApplinkTable[APPLINK_READ] = _read;
OPENSSL_ApplinkTable[APPLINK_WRITE] = _write;
OPENSSL_ApplinkTable[APPLINK_LSEEK] = _lseek;
OPENSSL_ApplinkTable[APPLINK_CLOSE] = _close;
once = 0;
}
return OPENSSL_ApplinkTable;
}
#ifdef __cplusplus
}
#endif
#endif
没有合适的资源?快使用搜索试试~ 我知道了~
资源推荐
资源详情
资源评论
收起资源包目录
WIN32环境下的openssl开发库.rar (104个子文件)
applink.c 3KB
libeay32.dll 1.02MB
ssleay32.dll 208KB
openssl.exe 320KB
ectest.exe 68KB
bntest.exe 32KB
ssltest.exe 32KB
destest.exe 24KB
evp_test.exe 20KB
casttest.exe 16KB
exptest.exe 16KB
md5test.exe 16KB
rc4test.exe 16KB
ecdhtest.exe 16KB
dhtest.exe 16KB
ideatest.exe 16KB
hmactest.exe 16KB
bftest.exe 16KB
sha512t.exe 16KB
sha1test.exe 16KB
dsatest.exe 16KB
md2test.exe 16KB
shatest.exe 16KB
sha256t.exe 16KB
rsa_test.exe 16KB
md4test.exe 16KB
rc2test.exe 16KB
ecdsatest.exe 16KB
rmdtest.exe 16KB
enginetest.exe 16KB
randtest.exe 16KB
libeay32.exp 448KB
ssleay32.exp 35KB
safestack.h 137KB
obj_mac.h 125KB
ssl.h 82KB
asn1.h 48KB
x509.h 47KB
evp.h 38KB
engine.h 38KB
bn.h 33KB
objects.h 33KB
bio.h 30KB
x509v3.h 29KB
pem.h 28KB
asn1t.h 27KB
store.h 26KB
crypto.h 24KB
ocsp.h 24KB
ssl3.h 22KB
ec.h 21KB
x509_vfy.h 20KB
symhacks.h 20KB
rsa.h 19KB
tls1.h 19KB
asn1_mac.h 19KB
des_old.h 18KB
ui.h 16KB
pkcs7.h 16KB
dso.h 16KB
err.h 13KB
pkcs12.h 12KB
dsa.h 11KB
des.h 10KB
ssl2.h 10KB
ecdsa.h 10KB
e_os2.h 9KB
conf.h 9KB
dh.h 8KB
krb5_asn.h 7KB
lhash.h 7KB
sha.h 7KB
opensslconf.h 7KB
ossl_typ.h 7KB
dtls1.h 6KB
rand.h 6KB
pq_compat.h 6KB
kssl.h 6KB
aes.h 6KB
blowfish.h 5KB
md4.h 5KB
md5.h 5KB
ecdh.h 5KB
buffer.h 4KB
idea.h 4KB
cast.h 4KB
hmac.h 4KB
stack.h 4KB
rc2.h 4KB
ripemd.h 4KB
txt_db.h 4KB
tmdiff.h 4KB
conf_api.h 4KB
md2.h 4KB
rc4.h 4KB
opensslv.h 4KB
ssl23.h 4KB
pqueue.h 3KB
ui_compat.h 3KB
pem2.h 3KB
共 104 条
- 1
- 2
资源评论
- 绅士X2013-08-28VC6运行没问题
- shgejun2014-07-11在vc6下可以使用,十分感谢!
- qp_goal2011-10-17感觉还有些东西欠缺,加上引用也不能直接运行啊,还得修改一些东西。楼主在改改吧
- qiancdong2013-10-10还可以,对我学习openssl有 参考意义
- charle_chen2012-08-27在Vs2005上是可以使用的,注意不要与其他库包含文件相冲突,否则会提示重定义等!
yxyhack
- 粉丝: 295
- 资源: 10
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功