4cef7e43b4b1a55bffcf60ccccf47fe3bd5cc053
[citadel.git] / citadel / modules / crypto / serv_crypto.h
1
2 /*
3  * Number of days for which self-signed certs are valid.
4  */
5 #define SIGN_DAYS       1100    // Just over three years
6
7 // Which ciphers will be offered; see https://www.openssl.org/docs/manmaster/man1/ciphers.html
8 //#define CIT_CIPHERS   "ALL:RC4+RSA:+SSLv2:+TLSv1:!MD5:@STRENGTH"
9 #define CIT_CIPHERS     "DEFAULT"
10
11 #ifdef HAVE_OPENSSL
12 #define OPENSSL_NO_KRB5         /* work around redhat b0rken ssl headers */
13 void init_ssl(void);
14 void client_write_ssl (const char *buf, int nbytes);
15 int client_read_sslbuffer(StrBuf *buf, int timeout);
16 int client_readline_sslbuffer(StrBuf *Target, StrBuf *Buffer, const char **Pos, int timeout);
17 int client_read_sslblob(StrBuf *Target, long want_len, int timeout);
18 void cmd_stls(char *params);
19 void cmd_gtls(char *params);
20 void endtls(void);
21 void CtdlStartTLS(char *ok_response, char *nosup_response, char *error_response);
22 extern SSL_CTX *ssl_ctx;  
23
24 #endif