OLD | NEW |
---|---|
1 /* | 1 /* |
2 * This file is PRIVATE to SSL and should be the first thing included by | 2 * This file is PRIVATE to SSL and should be the first thing included by |
3 * any SSL implementation file. | 3 * any SSL implementation file. |
4 * | 4 * |
5 * This Source Code Form is subject to the terms of the Mozilla Public | 5 * This Source Code Form is subject to the terms of the Mozilla Public |
6 * License, v. 2.0. If a copy of the MPL was not distributed with this | 6 * License, v. 2.0. If a copy of the MPL was not distributed with this |
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ | 7 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ |
8 | 8 |
9 #ifndef __sslimpl_h_ | 9 #ifndef __sslimpl_h_ |
10 #define __sslimpl_h_ | 10 #define __sslimpl_h_ |
(...skipping 887 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
898 PRInt32 recvdHighWater; /* The high water mark for fragments | 898 PRInt32 recvdHighWater; /* The high water mark for fragments |
899 * received. -1 means no reassembly | 899 * received. -1 means no reassembly |
900 * in progress. */ | 900 * in progress. */ |
901 unsigned char cookie[32]; /* The cookie */ | 901 unsigned char cookie[32]; /* The cookie */ |
902 unsigned char cookieLen; /* The length of the cookie */ | 902 unsigned char cookieLen; /* The length of the cookie */ |
903 PRIntervalTime rtTimerStarted; /* When the timer was started */ | 903 PRIntervalTime rtTimerStarted; /* When the timer was started */ |
904 DTLSTimerCb rtTimerCb; /* The function to call on expiry */ | 904 DTLSTimerCb rtTimerCb; /* The function to call on expiry */ |
905 PRUint32 rtTimeoutMs; /* The length of the current timeout | 905 PRUint32 rtTimeoutMs; /* The length of the current timeout |
906 * used for backoff (in ms) */ | 906 * used for backoff (in ms) */ |
907 PRUint32 rtRetries; /* The retry counter */ | 907 PRUint32 rtRetries; /* The retry counter */ |
908 PRBool canFalseStart; /* Can/did we False Start */ | |
wtc
2013/09/18 22:57:23
I moved this new member elsewhere because this sec
| |
909 | |
908 } SSL3HandshakeState; | 910 } SSL3HandshakeState; |
909 | 911 |
910 | 912 |
911 | 913 |
912 /* | 914 /* |
913 ** This is the "ssl3" struct, as in "ss->ssl3". | 915 ** This is the "ssl3" struct, as in "ss->ssl3". |
914 ** note: | 916 ** note: |
915 ** usually, crSpec == cwSpec and prSpec == pwSpec. | 917 ** usually, crSpec == cwSpec and prSpec == pwSpec. |
916 ** Sometimes, crSpec == pwSpec and prSpec == cwSpec. | 918 ** Sometimes, crSpec == pwSpec and prSpec == cwSpec. |
917 ** But there are never more than 2 actual specs. | 919 ** But there are never more than 2 actual specs. |
(...skipping 235 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1153 | 1155 |
1154 /* SSL socket options */ | 1156 /* SSL socket options */ |
1155 sslOptions opt; | 1157 sslOptions opt; |
1156 /* Enabled version range */ | 1158 /* Enabled version range */ |
1157 SSLVersionRange vrange; | 1159 SSLVersionRange vrange; |
1158 | 1160 |
1159 /* State flags */ | 1161 /* State flags */ |
1160 unsigned long clientAuthRequested; | 1162 unsigned long clientAuthRequested; |
1161 unsigned long delayDisabled; /* Nagle delay disabled */ | 1163 unsigned long delayDisabled; /* Nagle delay disabled */ |
1162 unsigned long firstHsDone; /* first handshake is complete. */ | 1164 unsigned long firstHsDone; /* first handshake is complete. */ |
1165 unsigned long enoughFirstHsDone; /* enough of the handshake is done | |
1166 * for callbacks to be able to | |
1167 * retrieve channel security | |
1168 * parameters from callback functions. */ | |
1163 unsigned long handshakeBegun; | 1169 unsigned long handshakeBegun; |
1164 unsigned long lastWriteBlocked; | 1170 unsigned long lastWriteBlocked; |
1165 unsigned long recvdCloseNotify; /* received SSL EOF. */ | 1171 unsigned long recvdCloseNotify; /* received SSL EOF. */ |
1166 unsigned long TCPconnected; | 1172 unsigned long TCPconnected; |
1167 unsigned long appDataBuffered; | 1173 unsigned long appDataBuffered; |
1168 unsigned long peerRequestedProtection; /* from old renegotiation */ | 1174 unsigned long peerRequestedProtection; /* from old renegotiation */ |
1169 | 1175 |
1170 /* version of the protocol to use */ | 1176 /* version of the protocol to use */ |
1171 SSL3ProtocolVersion version; | 1177 SSL3ProtocolVersion version; |
1172 SSL3ProtocolVersion clientHelloVersion; /* version sent in client hello. */ | 1178 SSL3ProtocolVersion clientHelloVersion; /* version sent in client hello. */ |
(...skipping 28 matching lines...) Expand all Loading... | |
1201 #ifdef NSS_PLATFORM_CLIENT_AUTH | 1207 #ifdef NSS_PLATFORM_CLIENT_AUTH |
1202 SSLGetPlatformClientAuthData getPlatformClientAuthData; | 1208 SSLGetPlatformClientAuthData getPlatformClientAuthData; |
1203 void *getPlatformClientAuthDataArg; | 1209 void *getPlatformClientAuthDataArg; |
1204 #endif /* NSS_PLATFORM_CLIENT_AUTH */ | 1210 #endif /* NSS_PLATFORM_CLIENT_AUTH */ |
1205 SSLSNISocketConfig sniSocketConfig; | 1211 SSLSNISocketConfig sniSocketConfig; |
1206 void *sniSocketConfigArg; | 1212 void *sniSocketConfigArg; |
1207 SSLBadCertHandler handleBadCert; | 1213 SSLBadCertHandler handleBadCert; |
1208 void *badCertArg; | 1214 void *badCertArg; |
1209 SSLHandshakeCallback handshakeCallback; | 1215 SSLHandshakeCallback handshakeCallback; |
1210 void *handshakeCallbackData; | 1216 void *handshakeCallbackData; |
1217 SSLCanFalseStartCallback canFalseStartCallback; | |
1218 void *canFalseStartCallbackData; | |
1211 void *pkcs11PinArg; | 1219 void *pkcs11PinArg; |
1212 SSLNextProtoCallback nextProtoCallback; | 1220 SSLNextProtoCallback nextProtoCallback; |
1213 void *nextProtoArg; | 1221 void *nextProtoArg; |
1214 SSLClientChannelIDCallback getChannelID; | 1222 SSLClientChannelIDCallback getChannelID; |
1215 void *getChannelIDArg; | 1223 void *getChannelIDArg; |
1216 | 1224 |
1217 PRIntervalTime rTimeout; /* timeout for NSPR I/O */ | 1225 PRIntervalTime rTimeout; /* timeout for NSPR I/O */ |
1218 PRIntervalTime wTimeout; /* timeout for NSPR I/O */ | 1226 PRIntervalTime wTimeout; /* timeout for NSPR I/O */ |
1219 PRIntervalTime cTimeout; /* timeout for NSPR I/O */ | 1227 PRIntervalTime cTimeout; /* timeout for NSPR I/O */ |
1220 | 1228 |
(...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1414 int len, int flags); | 1422 int len, int flags); |
1415 | 1423 |
1416 extern PRBool ssl_FdIsBlocking(PRFileDesc *fd); | 1424 extern PRBool ssl_FdIsBlocking(PRFileDesc *fd); |
1417 | 1425 |
1418 extern PRBool ssl_SocketIsBlocking(sslSocket *ss); | 1426 extern PRBool ssl_SocketIsBlocking(sslSocket *ss); |
1419 | 1427 |
1420 extern void ssl3_SetAlwaysBlock(sslSocket *ss); | 1428 extern void ssl3_SetAlwaysBlock(sslSocket *ss); |
1421 | 1429 |
1422 extern SECStatus ssl_EnableNagleDelay(sslSocket *ss, PRBool enabled); | 1430 extern SECStatus ssl_EnableNagleDelay(sslSocket *ss, PRBool enabled); |
1423 | 1431 |
1424 extern PRBool ssl3_CanFalseStart(sslSocket *ss); | |
1425 extern SECStatus | 1432 extern SECStatus |
1426 ssl3_CompressMACEncryptRecord(ssl3CipherSpec * cwSpec, | 1433 ssl3_CompressMACEncryptRecord(ssl3CipherSpec * cwSpec, |
1427 PRBool isServer, | 1434 PRBool isServer, |
1428 PRBool isDTLS, | 1435 PRBool isDTLS, |
1429 PRBool capRecordVersion, | 1436 PRBool capRecordVersion, |
1430 SSL3ContentType type, | 1437 SSL3ContentType type, |
1431 const SSL3Opaque * pIn, | 1438 const SSL3Opaque * pIn, |
1432 PRUint32 contentLen, | 1439 PRUint32 contentLen, |
1433 sslBuffer * wrBuf); | 1440 sslBuffer * wrBuf); |
1434 extern PRInt32 ssl3_SendRecord(sslSocket *ss, DTLSEpoch epoch, | 1441 extern PRInt32 ssl3_SendRecord(sslSocket *ss, DTLSEpoch epoch, |
(...skipping 500 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1935 #if defined(XP_UNIX) || defined(XP_OS2) || defined(XP_BEOS) | 1942 #if defined(XP_UNIX) || defined(XP_OS2) || defined(XP_BEOS) |
1936 #define SSL_GETPID getpid | 1943 #define SSL_GETPID getpid |
1937 #elif defined(WIN32) | 1944 #elif defined(WIN32) |
1938 extern int __cdecl _getpid(void); | 1945 extern int __cdecl _getpid(void); |
1939 #define SSL_GETPID _getpid | 1946 #define SSL_GETPID _getpid |
1940 #else | 1947 #else |
1941 #define SSL_GETPID() 0 | 1948 #define SSL_GETPID() 0 |
1942 #endif | 1949 #endif |
1943 | 1950 |
1944 #endif /* __sslimpl_h_ */ | 1951 #endif /* __sslimpl_h_ */ |
OLD | NEW |