| 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 281 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 292 unsigned int enabled : 1; | 292 unsigned int enabled : 1; |
| 293 unsigned int isPresent : 1; | 293 unsigned int isPresent : 1; |
| 294 #else | 294 #else |
| 295 ssl3CipherSuite cipher_suite; | 295 ssl3CipherSuite cipher_suite; |
| 296 PRUint8 policy; | 296 PRUint8 policy; |
| 297 unsigned char enabled : 1; | 297 unsigned char enabled : 1; |
| 298 unsigned char isPresent : 1; | 298 unsigned char isPresent : 1; |
| 299 #endif | 299 #endif |
| 300 } ssl3CipherSuiteCfg; | 300 } ssl3CipherSuiteCfg; |
| 301 | 301 |
| 302 #ifdef NSS_ENABLE_ECC | 302 #ifndef NSS_DISABLE_ECC |
| 303 #define ssl_V3_SUITES_IMPLEMENTED 63 | 303 #define ssl_V3_SUITES_IMPLEMENTED 63 |
| 304 #else | 304 #else |
| 305 #define ssl_V3_SUITES_IMPLEMENTED 37 | 305 #define ssl_V3_SUITES_IMPLEMENTED 37 |
| 306 #endif /* NSS_ENABLE_ECC */ | 306 #endif /* NSS_DISABLE_ECC */ |
| 307 | 307 |
| 308 #define MAX_DTLS_SRTP_CIPHER_SUITES 4 | 308 #define MAX_DTLS_SRTP_CIPHER_SUITES 4 |
| 309 | 309 |
| 310 typedef struct sslOptionsStr { | 310 typedef struct sslOptionsStr { |
| 311 /* If SSL_SetNextProtoNego has been called, then this contains the | 311 /* If SSL_SetNextProtoNego has been called, then this contains the |
| 312 * list of supported protocols. */ | 312 * list of supported protocols. */ |
| 313 SECItem nextProtoNego; | 313 SECItem nextProtoNego; |
| 314 | 314 |
| 315 unsigned int useSecurity : 1; /* 1 */ | 315 unsigned int useSecurity : 1; /* 1 */ |
| 316 unsigned int useSocks : 1; /* 2 */ | 316 unsigned int useSocks : 1; /* 2 */ |
| (...skipping 13 matching lines...) Expand all Loading... |
| 330 unsigned int noLocks : 1; /* 17 */ | 330 unsigned int noLocks : 1; /* 17 */ |
| 331 unsigned int enableSessionTickets : 1; /* 18 */ | 331 unsigned int enableSessionTickets : 1; /* 18 */ |
| 332 unsigned int enableDeflate : 1; /* 19 */ | 332 unsigned int enableDeflate : 1; /* 19 */ |
| 333 unsigned int enableRenegotiation : 2; /* 20-21 */ | 333 unsigned int enableRenegotiation : 2; /* 20-21 */ |
| 334 unsigned int requireSafeNegotiation : 1; /* 22 */ | 334 unsigned int requireSafeNegotiation : 1; /* 22 */ |
| 335 unsigned int enableFalseStart : 1; /* 23 */ | 335 unsigned int enableFalseStart : 1; /* 23 */ |
| 336 unsigned int cbcRandomIV : 1; /* 24 */ | 336 unsigned int cbcRandomIV : 1; /* 24 */ |
| 337 unsigned int enableOCSPStapling : 1; /* 25 */ | 337 unsigned int enableOCSPStapling : 1; /* 25 */ |
| 338 unsigned int enableNPN : 1; /* 26 */ | 338 unsigned int enableNPN : 1; /* 26 */ |
| 339 unsigned int enableALPN : 1; /* 27 */ | 339 unsigned int enableALPN : 1; /* 27 */ |
| 340 unsigned int enableSignedCertTimestamps : 1; /* 28 */ | 340 unsigned int reuseServerECDHEKey : 1; /* 28 */ |
| 341 unsigned int enableFallbackSCSV : 1; /* 29 */ | 341 unsigned int enableFallbackSCSV : 1; /* 29 */ |
| 342 unsigned int enableSignedCertTimestamps : 1; /* 30 */ |
| 342 } sslOptions; | 343 } sslOptions; |
| 343 | 344 |
| 344 typedef enum { sslHandshakingUndetermined = 0, | 345 typedef enum { sslHandshakingUndetermined = 0, |
| 345 sslHandshakingAsClient, | 346 sslHandshakingAsClient, |
| 346 sslHandshakingAsServer | 347 sslHandshakingAsServer |
| 347 } sslHandshakingType; | 348 } sslHandshakingType; |
| 348 | 349 |
| 349 typedef struct sslServerCertsStr { | 350 typedef struct sslServerCertsStr { |
| 350 /* Configuration state for server sockets */ | 351 /* Configuration state for server sockets */ |
| 351 CERTCertificate * serverCert; | 352 CERTCertificate * serverCert; |
| (...skipping 319 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 671 | 672 |
| 672 ssl3CipherSuite cipherSuite; | 673 ssl3CipherSuite cipherSuite; |
| 673 SSLCompressionMethod compression; | 674 SSLCompressionMethod compression; |
| 674 int policy; | 675 int policy; |
| 675 ssl3SidKeys keys; | 676 ssl3SidKeys keys; |
| 676 CK_MECHANISM_TYPE masterWrapMech; | 677 CK_MECHANISM_TYPE masterWrapMech; |
| 677 /* mechanism used to wrap master secret */ | 678 /* mechanism used to wrap master secret */ |
| 678 SSL3KEAType exchKeyType; | 679 SSL3KEAType exchKeyType; |
| 679 /* key type used in exchange algorithm, | 680 /* key type used in exchange algorithm, |
| 680 * and to wrap the sym wrapping key. */ | 681 * and to wrap the sym wrapping key. */ |
| 681 #ifdef NSS_ENABLE_ECC | 682 #ifndef NSS_DISABLE_ECC |
| 682 PRUint32 negotiatedECCurves; | 683 PRUint32 negotiatedECCurves; |
| 683 #endif /* NSS_ENABLE_ECC */ | 684 #endif /* NSS_DISABLE_ECC */ |
| 684 | 685 |
| 685 /* The following values are NOT restored from the server's on-disk | 686 /* The following values are NOT restored from the server's on-disk |
| 686 * session cache, but are restored from the client's cache. | 687 * session cache, but are restored from the client's cache. |
| 687 */ | 688 */ |
| 688 PK11SymKey * clientWriteKey; | 689 PK11SymKey * clientWriteKey; |
| 689 PK11SymKey * serverWriteKey; | 690 PK11SymKey * serverWriteKey; |
| 690 | 691 |
| 691 /* The following values pertain to the slot that wrapped the | 692 /* The following values pertain to the slot that wrapped the |
| 692 ** master secret. (used only in client) | 693 ** master secret. (used only in client) |
| 693 */ | 694 */ |
| (...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 928 */ | 929 */ |
| 929 PRBool receivedNewSessionTicket; | 930 PRBool receivedNewSessionTicket; |
| 930 NewSessionTicket newSessionTicket; | 931 NewSessionTicket newSessionTicket; |
| 931 | 932 |
| 932 PRUint16 finishedBytes; /* size of single finished below */ | 933 PRUint16 finishedBytes; /* size of single finished below */ |
| 933 union { | 934 union { |
| 934 TLSFinished tFinished[2]; /* client, then server */ | 935 TLSFinished tFinished[2]; /* client, then server */ |
| 935 SSL3Finished sFinished[2]; | 936 SSL3Finished sFinished[2]; |
| 936 SSL3Opaque data[72]; | 937 SSL3Opaque data[72]; |
| 937 } finishedMsgs; | 938 } finishedMsgs; |
| 938 #ifdef NSS_ENABLE_ECC | 939 #ifndef NSS_DISABLE_ECC |
| 939 PRUint32 negotiatedECCurves; /* bit mask */ | 940 PRUint32 negotiatedECCurves; /* bit mask */ |
| 940 #endif /* NSS_ENABLE_ECC */ | 941 #endif /* NSS_DISABLE_ECC */ |
| 941 | 942 |
| 942 PRBool authCertificatePending; | 943 PRBool authCertificatePending; |
| 943 /* Which function should SSL_RestartHandshake* call if we're blocked? | 944 /* Which function should SSL_RestartHandshake* call if we're blocked? |
| 944 * One of NULL, ssl3_SendClientSecondRound, ssl3_FinishHandshake, | 945 * One of NULL, ssl3_SendClientSecondRound, ssl3_FinishHandshake, |
| 945 * or ssl3_AlwaysFail */ | 946 * or ssl3_AlwaysFail */ |
| 946 sslRestartTarget restartTarget; | 947 sslRestartTarget restartTarget; |
| 947 /* Shared state between ssl3_HandleFinished and ssl3_FinishHandshake */ | 948 /* Shared state between ssl3_HandleFinished and ssl3_FinishHandshake */ |
| 948 PRBool cacheSID; | 949 PRBool cacheSID; |
| 949 | 950 |
| 950 PRBool canFalseStart; /* Can/did we False Start */ | 951 PRBool canFalseStart; /* Can/did we False Start */ |
| (...skipping 498 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1449 /* Gather funcs. */ | 1450 /* Gather funcs. */ |
| 1450 extern sslGather * ssl_NewGather(void); | 1451 extern sslGather * ssl_NewGather(void); |
| 1451 extern SECStatus ssl_InitGather(sslGather *gs); | 1452 extern SECStatus ssl_InitGather(sslGather *gs); |
| 1452 extern void ssl_DestroyGather(sslGather *gs); | 1453 extern void ssl_DestroyGather(sslGather *gs); |
| 1453 extern int ssl2_GatherData(sslSocket *ss, sslGather *gs, int flags); | 1454 extern int ssl2_GatherData(sslSocket *ss, sslGather *gs, int flags); |
| 1454 extern int ssl2_GatherRecord(sslSocket *ss, int flags); | 1455 extern int ssl2_GatherRecord(sslSocket *ss, int flags); |
| 1455 extern SECStatus ssl_GatherRecord1stHandshake(sslSocket *ss); | 1456 extern SECStatus ssl_GatherRecord1stHandshake(sslSocket *ss); |
| 1456 | 1457 |
| 1457 extern SECStatus ssl2_HandleClientHelloMessage(sslSocket *ss); | 1458 extern SECStatus ssl2_HandleClientHelloMessage(sslSocket *ss); |
| 1458 extern SECStatus ssl2_HandleServerHelloMessage(sslSocket *ss); | 1459 extern SECStatus ssl2_HandleServerHelloMessage(sslSocket *ss); |
| 1459 extern int ssl2_StartGatherBytes(sslSocket *ss, sslGather *gs, | |
| 1460 unsigned int count); | |
| 1461 | 1460 |
| 1462 extern SECStatus ssl_CreateSecurityInfo(sslSocket *ss); | 1461 extern SECStatus ssl_CreateSecurityInfo(sslSocket *ss); |
| 1463 extern SECStatus ssl_CopySecurityInfo(sslSocket *ss, sslSocket *os); | 1462 extern SECStatus ssl_CopySecurityInfo(sslSocket *ss, sslSocket *os); |
| 1464 extern void ssl_ResetSecurityInfo(sslSecurityInfo *sec, PRBool doMemset); | 1463 extern void ssl_ResetSecurityInfo(sslSecurityInfo *sec, PRBool doMemset); |
| 1465 extern void ssl_DestroySecurityInfo(sslSecurityInfo *sec); | 1464 extern void ssl_DestroySecurityInfo(sslSecurityInfo *sec); |
| 1466 | 1465 |
| 1467 extern void ssl_PrintBuf(sslSocket *ss, const char *msg, const void *cp,
int len); | 1466 extern void ssl_PrintBuf(sslSocket *ss, const char *msg, const void *cp,
int len); |
| 1468 extern void ssl_DumpMsg(sslSocket *ss, unsigned char *bp, unsigned len); | 1467 extern void ssl_DumpMsg(sslSocket *ss, unsigned char *bp, unsigned len); |
| 1469 | 1468 |
| 1470 extern int ssl_SendSavedWriteData(sslSocket *ss); | 1469 extern int ssl_SendSavedWriteData(sslSocket *ss); |
| (...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1605 /* Placeholder value used in version ranges when SSL 3.0 and all | 1604 /* Placeholder value used in version ranges when SSL 3.0 and all |
| 1606 * versions of TLS are disabled. | 1605 * versions of TLS are disabled. |
| 1607 */ | 1606 */ |
| 1608 #define SSL_LIBRARY_VERSION_NONE 0 | 1607 #define SSL_LIBRARY_VERSION_NONE 0 |
| 1609 | 1608 |
| 1610 /* SSL_LIBRARY_VERSION_MAX_SUPPORTED is the maximum version that this version | 1609 /* SSL_LIBRARY_VERSION_MAX_SUPPORTED is the maximum version that this version |
| 1611 * of libssl supports. Applications should use SSL_VersionRangeGetSupported at | 1610 * of libssl supports. Applications should use SSL_VersionRangeGetSupported at |
| 1612 * runtime to determine which versions are supported by the version of libssl | 1611 * runtime to determine which versions are supported by the version of libssl |
| 1613 * in use. | 1612 * in use. |
| 1614 */ | 1613 */ |
| 1614 #ifdef NSS_ENABLE_TLS_1_3 |
| 1615 #define SSL_LIBRARY_VERSION_MAX_SUPPORTED SSL_LIBRARY_VERSION_TLS_1_3 |
| 1616 #else |
| 1615 #define SSL_LIBRARY_VERSION_MAX_SUPPORTED SSL_LIBRARY_VERSION_TLS_1_2 | 1617 #define SSL_LIBRARY_VERSION_MAX_SUPPORTED SSL_LIBRARY_VERSION_TLS_1_2 |
| 1618 #endif |
| 1616 | 1619 |
| 1617 /* Rename this macro SSL_ALL_VERSIONS_DISABLED when SSL 2.0 is removed. */ | 1620 /* Rename this macro SSL_ALL_VERSIONS_DISABLED when SSL 2.0 is removed. */ |
| 1618 #define SSL3_ALL_VERSIONS_DISABLED(vrange) \ | 1621 #define SSL3_ALL_VERSIONS_DISABLED(vrange) \ |
| 1619 ((vrange)->min == SSL_LIBRARY_VERSION_NONE) | 1622 ((vrange)->min == SSL_LIBRARY_VERSION_NONE) |
| 1620 | 1623 |
| 1621 extern PRBool ssl3_VersionIsSupported(SSLProtocolVariant protocolVariant, | 1624 extern PRBool ssl3_VersionIsSupported(SSLProtocolVariant protocolVariant, |
| 1622 SSL3ProtocolVersion version); | 1625 SSL3ProtocolVersion version); |
| 1623 | 1626 |
| 1624 extern SECStatus ssl3_KeyAndMacDeriveBypass(ssl3CipherSpec * pwSpec, | 1627 extern SECStatus ssl3_KeyAndMacDeriveBypass(ssl3CipherSpec * pwSpec, |
| 1625 const unsigned char * cr, const unsigned char * sr, | 1628 const unsigned char * cr, const unsigned char * sr, |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1671 int ssl3_GatherAppDataRecord(sslSocket *ss, int flags); | 1674 int ssl3_GatherAppDataRecord(sslSocket *ss, int flags); |
| 1672 int ssl3_GatherCompleteHandshake(sslSocket *ss, int flags); | 1675 int ssl3_GatherCompleteHandshake(sslSocket *ss, int flags); |
| 1673 /* | 1676 /* |
| 1674 * When talking to export clients or using export cipher suites, servers | 1677 * When talking to export clients or using export cipher suites, servers |
| 1675 * with public RSA keys larger than 512 bits need to use a 512-bit public | 1678 * with public RSA keys larger than 512 bits need to use a 512-bit public |
| 1676 * key, signed by the larger key. The smaller key is a "step down" key. | 1679 * key, signed by the larger key. The smaller key is a "step down" key. |
| 1677 * Generate that key pair and keep it around. | 1680 * Generate that key pair and keep it around. |
| 1678 */ | 1681 */ |
| 1679 extern SECStatus ssl3_CreateRSAStepDownKeys(sslSocket *ss); | 1682 extern SECStatus ssl3_CreateRSAStepDownKeys(sslSocket *ss); |
| 1680 | 1683 |
| 1681 #ifdef NSS_ENABLE_ECC | 1684 #ifndef NSS_DISABLE_ECC |
| 1682 extern void ssl3_FilterECCipherSuitesByServerCerts(sslSocket *ss); | 1685 extern void ssl3_FilterECCipherSuitesByServerCerts(sslSocket *ss); |
| 1683 extern PRBool ssl3_IsECCEnabled(sslSocket *ss); | 1686 extern PRBool ssl3_IsECCEnabled(sslSocket *ss); |
| 1684 extern SECStatus ssl3_DisableECCSuites(sslSocket * ss, | 1687 extern SECStatus ssl3_DisableECCSuites(sslSocket * ss, |
| 1685 const ssl3CipherSuite * suite); | 1688 const ssl3CipherSuite * suite); |
| 1686 extern PRUint32 ssl3_GetSupportedECCurveMask(sslSocket *ss); | 1689 extern PRUint32 ssl3_GetSupportedECCurveMask(sslSocket *ss); |
| 1687 | 1690 |
| 1688 | 1691 |
| 1689 /* Macro for finding a curve equivalent in strength to RSA key's */ | 1692 /* Macro for finding a curve equivalent in strength to RSA key's */ |
| 1690 #define SSL_RSASTRENGTH_TO_ECSTRENGTH(s) \ | 1693 #define SSL_RSASTRENGTH_TO_ECSTRENGTH(s) \ |
| 1691 ((s <= 1024) ? 160 \ | 1694 ((s <= 1024) ? 160 \ |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1726 ec_secp384r1 = 24, | 1729 ec_secp384r1 = 24, |
| 1727 ec_secp521r1 = 25, | 1730 ec_secp521r1 = 25, |
| 1728 ec_pastLastName | 1731 ec_pastLastName |
| 1729 } ECName; | 1732 } ECName; |
| 1730 | 1733 |
| 1731 extern SECStatus ssl3_ECName2Params(PLArenaPool *arena, ECName curve, | 1734 extern SECStatus ssl3_ECName2Params(PLArenaPool *arena, ECName curve, |
| 1732 SECKEYECParams *params); | 1735 SECKEYECParams *params); |
| 1733 ECName ssl3_GetCurveWithECKeyStrength(PRUint32 curvemsk, int requiredECCbits); | 1736 ECName ssl3_GetCurveWithECKeyStrength(PRUint32 curvemsk, int requiredECCbits); |
| 1734 | 1737 |
| 1735 | 1738 |
| 1736 #endif /* NSS_ENABLE_ECC */ | 1739 #endif /* NSS_DISABLE_ECC */ |
| 1737 | 1740 |
| 1738 extern SECStatus ssl3_CipherPrefSetDefault(ssl3CipherSuite which, PRBool on); | 1741 extern SECStatus ssl3_CipherPrefSetDefault(ssl3CipherSuite which, PRBool on); |
| 1739 extern SECStatus ssl3_CipherPrefGetDefault(ssl3CipherSuite which, PRBool *on); | 1742 extern SECStatus ssl3_CipherPrefGetDefault(ssl3CipherSuite which, PRBool *on); |
| 1740 extern SECStatus ssl2_CipherPrefSetDefault(PRInt32 which, PRBool enabled); | 1743 extern SECStatus ssl2_CipherPrefSetDefault(PRInt32 which, PRBool enabled); |
| 1741 extern SECStatus ssl2_CipherPrefGetDefault(PRInt32 which, PRBool *enabled); | 1744 extern SECStatus ssl2_CipherPrefGetDefault(PRInt32 which, PRBool *enabled); |
| 1742 | 1745 |
| 1743 extern SECStatus ssl3_CipherPrefSet(sslSocket *ss, ssl3CipherSuite which, PRBool
on); | 1746 extern SECStatus ssl3_CipherPrefSet(sslSocket *ss, ssl3CipherSuite which, PRBool
on); |
| 1744 extern SECStatus ssl3_CipherPrefGet(sslSocket *ss, ssl3CipherSuite which, PRBool
*on); | 1747 extern SECStatus ssl3_CipherPrefGet(sslSocket *ss, ssl3CipherSuite which, PRBool
*on); |
| 1745 extern SECStatus ssl2_CipherPrefSet(sslSocket *ss, PRInt32 which, PRBool enabled
); | 1748 extern SECStatus ssl2_CipherPrefSet(sslSocket *ss, PRInt32 which, PRBool enabled
); |
| 1746 extern SECStatus ssl2_CipherPrefGet(sslSocket *ss, PRInt32 which, PRBool *enable
d); | 1749 extern SECStatus ssl2_CipherPrefGet(sslSocket *ss, PRInt32 which, PRBool *enable
d); |
| (...skipping 16 matching lines...) Expand all Loading... |
| 1763 PRUint32 length); | 1766 PRUint32 length); |
| 1764 | 1767 |
| 1765 extern void ssl3_DestroySSL3Info(sslSocket *ss); | 1768 extern void ssl3_DestroySSL3Info(sslSocket *ss); |
| 1766 | 1769 |
| 1767 extern SECStatus ssl3_NegotiateVersion(sslSocket *ss, | 1770 extern SECStatus ssl3_NegotiateVersion(sslSocket *ss, |
| 1768 SSL3ProtocolVersion peerVersion, | 1771 SSL3ProtocolVersion peerVersion, |
| 1769 PRBool allowLargerPeerVersion); | 1772 PRBool allowLargerPeerVersion); |
| 1770 | 1773 |
| 1771 extern SECStatus ssl_GetPeerInfo(sslSocket *ss); | 1774 extern SECStatus ssl_GetPeerInfo(sslSocket *ss); |
| 1772 | 1775 |
| 1773 #ifdef NSS_ENABLE_ECC | 1776 #ifndef NSS_DISABLE_ECC |
| 1774 /* ECDH functions */ | 1777 /* ECDH functions */ |
| 1775 extern SECStatus ssl3_SendECDHClientKeyExchange(sslSocket * ss, | 1778 extern SECStatus ssl3_SendECDHClientKeyExchange(sslSocket * ss, |
| 1776 SECKEYPublicKey * svrPubKey); | 1779 SECKEYPublicKey * svrPubKey); |
| 1777 extern SECStatus ssl3_HandleECDHServerKeyExchange(sslSocket *ss, | 1780 extern SECStatus ssl3_HandleECDHServerKeyExchange(sslSocket *ss, |
| 1778 SSL3Opaque *b, PRUint32 length); | 1781 SSL3Opaque *b, PRUint32 length); |
| 1779 extern SECStatus ssl3_HandleECDHClientKeyExchange(sslSocket *ss, | 1782 extern SECStatus ssl3_HandleECDHClientKeyExchange(sslSocket *ss, |
| 1780 SSL3Opaque *b, PRUint32 length, | 1783 SSL3Opaque *b, PRUint32 length, |
| 1781 SECKEYPublicKey *srvrPubKey, | 1784 SECKEYPublicKey *srvrPubKey, |
| 1782 SECKEYPrivateKey *srvrPrivKey); | 1785 SECKEYPrivateKey *srvrPrivKey); |
| 1783 extern SECStatus ssl3_SendECDHServerKeyExchange(sslSocket *ss, | 1786 extern SECStatus ssl3_SendECDHServerKeyExchange(sslSocket *ss, |
| (...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1848 PRUint32 maxBytes); | 1851 PRUint32 maxBytes); |
| 1849 | 1852 |
| 1850 /* Assigns new cert, cert chain and keys to ss->serverCerts | 1853 /* Assigns new cert, cert chain and keys to ss->serverCerts |
| 1851 * struct. If certChain is NULL, tries to find one. Aborts if | 1854 * struct. If certChain is NULL, tries to find one. Aborts if |
| 1852 * fails to do so. If cert and keyPair are NULL - unconfigures | 1855 * fails to do so. If cert and keyPair are NULL - unconfigures |
| 1853 * sslSocket of kea type.*/ | 1856 * sslSocket of kea type.*/ |
| 1854 extern SECStatus ssl_ConfigSecureServer(sslSocket *ss, CERTCertificate *cert, | 1857 extern SECStatus ssl_ConfigSecureServer(sslSocket *ss, CERTCertificate *cert, |
| 1855 const CERTCertificateList *certChain, | 1858 const CERTCertificateList *certChain, |
| 1856 ssl3KeyPair *keyPair, SSLKEAType kea); | 1859 ssl3KeyPair *keyPair, SSLKEAType kea); |
| 1857 | 1860 |
| 1858 #ifdef NSS_ENABLE_ECC | 1861 #ifndef NSS_DISABLE_ECC |
| 1859 extern PRInt32 ssl3_SendSupportedCurvesXtn(sslSocket *ss, | 1862 extern PRInt32 ssl3_SendSupportedCurvesXtn(sslSocket *ss, |
| 1860 PRBool append, PRUint32 maxBytes); | 1863 PRBool append, PRUint32 maxBytes); |
| 1861 extern PRInt32 ssl3_SendSupportedPointFormatsXtn(sslSocket *ss, | 1864 extern PRInt32 ssl3_SendSupportedPointFormatsXtn(sslSocket *ss, |
| 1862 PRBool append, PRUint32 maxBytes); | 1865 PRBool append, PRUint32 maxBytes); |
| 1863 #endif | 1866 #endif |
| 1864 | 1867 |
| 1865 /* call the registered extension handlers. */ | 1868 /* call the registered extension handlers. */ |
| 1866 extern SECStatus ssl3_HandleHelloExtensions(sslSocket *ss, | 1869 extern SECStatus ssl3_HandleHelloExtensions(sslSocket *ss, |
| 1867 SSL3Opaque **b, PRUint32 *length); | 1870 SSL3Opaque **b, PRUint32 *length); |
| 1868 | 1871 |
| (...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2028 #if defined(XP_UNIX) || defined(XP_OS2) || defined(XP_BEOS) | 2031 #if defined(XP_UNIX) || defined(XP_OS2) || defined(XP_BEOS) |
| 2029 #define SSL_GETPID getpid | 2032 #define SSL_GETPID getpid |
| 2030 #elif defined(WIN32) | 2033 #elif defined(WIN32) |
| 2031 extern int __cdecl _getpid(void); | 2034 extern int __cdecl _getpid(void); |
| 2032 #define SSL_GETPID _getpid | 2035 #define SSL_GETPID _getpid |
| 2033 #else | 2036 #else |
| 2034 #define SSL_GETPID() 0 | 2037 #define SSL_GETPID() 0 |
| 2035 #endif | 2038 #endif |
| 2036 | 2039 |
| 2037 #endif /* __sslimpl_h_ */ | 2040 #endif /* __sslimpl_h_ */ |
| OLD | NEW |