📄 testssl.h
字号:
/* *********************************************************************
File: testssl.h
SSLRef 3.0 Final -- 11/19/96
Copyright (c)1996 by Netscape Communications Corp.
By retrieving this software you are bound by the licensing terms
disclosed in the file "LICENSE.txt". Please read it, and if you don't
accept the terms, delete this software.
SSLRef 3.0 was developed by Netscape Communications Corp. of Mountain
View, California <http://home.netscape.com/> and Consensus Development
Corporation of Berkeley, California <http://www.consensus.com/>.
*********************************************************************
File: testssl.h Prototypes for sample client
****************************************************************** */
#ifndef _SSLTEST_H_
#define _SSLTEST_H_ 1
#ifndef _SSL_H_
#include "ssl.h"
#endif
#define DEFAULTSERVER 1
#define DEFAULTHOST "localhost"
#define DEFAULTPORT 443
#define DEFAULTVERSION SSL_Version_Undetermined
#define DEFAULTAUTH 0
#define DEFAULTCACHE 1
#define KEY_PASSWORD "password"
typedef struct
{ uint32 ipAddr;
int port;
} PeerSpec;
SSLErr ConfigureGenericSSLSession(SSLContext *ctx);
SSLErr ReadPrivateKey(SSLRSAPrivateKey *key, SSLContext *ctx);
SSLErr AddCertificates(SSLContext *ctx);
SSLErr AddDistinguishedNames(SSLContext *ctx);
SSLErr AddDHParams(SSLContext *ctx);
SSLErr InitDatabase(const char *filename, void **dbRef);
SSLErr DisposeDatabase(void);
SSLErr SSLAddSession (SSLBuffer sessionKey, SSLBuffer sessionData, void *sessionRef);
SSLErr SSLGetSession (SSLBuffer sessionKey, SSLBuffer *sessionData, void *sessionRef);
SSLErr SSLDeleteSession (SSLBuffer sessionKey, void *sessionRef);
SSLErr SSLAlloc (SSLBuffer *buf, void *allocRef);
SSLErr SSLFree (SSLBuffer *buf, void *allocRef);
SSLErr SSLRealloc (SSLBuffer *buf, uint32 newSize, void *allocRef);
SSLErr SSLRandom(SSLBuffer data, void *randomRef);
SSLErr SeedRandom(void **randomRef);
SSLErr SSLTime(uint32 *time, void *timeRef);
SSLErr SSLConvertTime(uint32 *time, void *timeRef);
SSLErr SocketRead(SSLBuffer buffer, uint32 *processed, void *state);
SSLErr SocketWrite(SSLBuffer buffer, uint32 *processed, void *state);
SSLErr SSLDecodePrivateKey(SSLBuffer privateKey, SSLBuffer password, SSLRSAPrivateKey *rsakey, SSLContext *ctx);
#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -