| OLD | NEW |
| 1 /* | 1 /* |
| 2 * vtables (and methods that call through them) for the 4 types of | 2 * vtables (and methods that call through them) for the 4 types of |
| 3 * SSLSockets supported. Only one type is still supported. | 3 * SSLSockets supported. Only one type is still supported. |
| 4 * Various other functions. | 4 * Various other functions. |
| 5 * | 5 * |
| 6 * ***** BEGIN LICENSE BLOCK ***** | 6 * ***** BEGIN LICENSE BLOCK ***** |
| 7 * Version: MPL 1.1/GPL 2.0/LGPL 2.1 | 7 * Version: MPL 1.1/GPL 2.0/LGPL 2.1 |
| 8 * | 8 * |
| 9 * The contents of this file are subject to the Mozilla Public License Version | 9 * The contents of this file are subject to the Mozilla Public License Version |
| 10 * 1.1 (the "License"); you may not use this file except in compliance with | 10 * 1.1 (the "License"); you may not use this file except in compliance with |
| (...skipping 356 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 367 ss->getPlatformClientAuthData = os->getPlatformClientAuthData; | 367 ss->getPlatformClientAuthData = os->getPlatformClientAuthData; |
| 368 ss->getPlatformClientAuthDataArg = os->getPlatformClientAuthDataArg; | 368 ss->getPlatformClientAuthDataArg = os->getPlatformClientAuthDataArg; |
| 369 #endif | 369 #endif |
| 370 ss->sniSocketConfig = os->sniSocketConfig; | 370 ss->sniSocketConfig = os->sniSocketConfig; |
| 371 ss->sniSocketConfigArg = os->sniSocketConfigArg; | 371 ss->sniSocketConfigArg = os->sniSocketConfigArg; |
| 372 ss->handleBadCert = os->handleBadCert; | 372 ss->handleBadCert = os->handleBadCert; |
| 373 ss->badCertArg = os->badCertArg; | 373 ss->badCertArg = os->badCertArg; |
| 374 ss->handshakeCallback = os->handshakeCallback; | 374 ss->handshakeCallback = os->handshakeCallback; |
| 375 ss->handshakeCallbackData = os->handshakeCallbackData; | 375 ss->handshakeCallbackData = os->handshakeCallbackData; |
| 376 ss->pkcs11PinArg = os->pkcs11PinArg; | 376 ss->pkcs11PinArg = os->pkcs11PinArg; |
| 377 ss->getChannelID = os->getChannelID; |
| 378 ss->getChannelIDArg = os->getChannelIDArg; |
| 377 | 379 |
| 378 /* Create security data */ | 380 /* Create security data */ |
| 379 rv = ssl_CopySecurityInfo(ss, os); | 381 rv = ssl_CopySecurityInfo(ss, os); |
| 380 if (rv != SECSuccess) { | 382 if (rv != SECSuccess) { |
| 381 goto loser; | 383 goto loser; |
| 382 } | 384 } |
| 383 } | 385 } |
| 384 } | 386 } |
| 385 return ss; | 387 return ss; |
| 386 | 388 |
| (...skipping 1294 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1681 if (sm->handleBadCert) | 1683 if (sm->handleBadCert) |
| 1682 ss->handleBadCert = sm->handleBadCert; | 1684 ss->handleBadCert = sm->handleBadCert; |
| 1683 if (sm->badCertArg) | 1685 if (sm->badCertArg) |
| 1684 ss->badCertArg = sm->badCertArg; | 1686 ss->badCertArg = sm->badCertArg; |
| 1685 if (sm->handshakeCallback) | 1687 if (sm->handshakeCallback) |
| 1686 ss->handshakeCallback = sm->handshakeCallback; | 1688 ss->handshakeCallback = sm->handshakeCallback; |
| 1687 if (sm->handshakeCallbackData) | 1689 if (sm->handshakeCallbackData) |
| 1688 ss->handshakeCallbackData = sm->handshakeCallbackData; | 1690 ss->handshakeCallbackData = sm->handshakeCallbackData; |
| 1689 if (sm->pkcs11PinArg) | 1691 if (sm->pkcs11PinArg) |
| 1690 ss->pkcs11PinArg = sm->pkcs11PinArg; | 1692 ss->pkcs11PinArg = sm->pkcs11PinArg; |
| 1693 if (sm->getChannelID) |
| 1694 ss->getChannelID = sm->getChannelID; |
| 1695 if (sm->getChannelIDArg) |
| 1696 ss->getChannelIDArg = sm->getChannelIDArg; |
| 1691 return fd; | 1697 return fd; |
| 1692 loser: | 1698 loser: |
| 1693 return NULL; | 1699 return NULL; |
| 1694 #endif | 1700 #endif |
| 1695 } | 1701 } |
| 1696 | 1702 |
| 1697 PRBool | 1703 PRBool |
| 1698 ssl3_VersionIsSupported(SSLProtocolVariant protocolVariant, | 1704 ssl3_VersionIsSupported(SSLProtocolVariant protocolVariant, |
| 1699 SSL3ProtocolVersion version) | 1705 SSL3ProtocolVersion version) |
| 1700 { | 1706 { |
| (...skipping 1230 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2931 ss->sniSocketConfig = NULL; | 2937 ss->sniSocketConfig = NULL; |
| 2932 ss->sniSocketConfigArg = NULL; | 2938 ss->sniSocketConfigArg = NULL; |
| 2933 ss->getClientAuthData = NULL; | 2939 ss->getClientAuthData = NULL; |
| 2934 #ifdef NSS_PLATFORM_CLIENT_AUTH | 2940 #ifdef NSS_PLATFORM_CLIENT_AUTH |
| 2935 ss->getPlatformClientAuthData = NULL; | 2941 ss->getPlatformClientAuthData = NULL; |
| 2936 ss->getPlatformClientAuthDataArg = NULL; | 2942 ss->getPlatformClientAuthDataArg = NULL; |
| 2937 #endif /* NSS_PLATFORM_CLIENT_AUTH */ | 2943 #endif /* NSS_PLATFORM_CLIENT_AUTH */ |
| 2938 ss->handleBadCert = NULL; | 2944 ss->handleBadCert = NULL; |
| 2939 ss->badCertArg = NULL; | 2945 ss->badCertArg = NULL; |
| 2940 ss->pkcs11PinArg = NULL; | 2946 ss->pkcs11PinArg = NULL; |
| 2947 ss->getChannelID = NULL; |
| 2948 ss->getChannelIDArg = NULL; |
| 2941 | 2949 |
| 2942 ssl_ChooseOps(ss); | 2950 ssl_ChooseOps(ss); |
| 2943 ssl2_InitSocketPolicy(ss); | 2951 ssl2_InitSocketPolicy(ss); |
| 2944 ssl3_InitSocketPolicy(ss); | 2952 ssl3_InitSocketPolicy(ss); |
| 2945 | 2953 |
| 2946 if (makeLocks) { | 2954 if (makeLocks) { |
| 2947 status = ssl_MakeLocks(ss); | 2955 status = ssl_MakeLocks(ss); |
| 2948 if (status != SECSuccess) | 2956 if (status != SECSuccess) |
| 2949 goto loser; | 2957 goto loser; |
| 2950 } | 2958 } |
| 2951 status = ssl_CreateSecurityInfo(ss); | 2959 status = ssl_CreateSecurityInfo(ss); |
| 2952 if (status != SECSuccess) | 2960 if (status != SECSuccess) |
| 2953 goto loser; | 2961 goto loser; |
| 2954 status = ssl_InitGather(&ss->gs); | 2962 status = ssl_InitGather(&ss->gs); |
| 2955 if (status != SECSuccess) { | 2963 if (status != SECSuccess) { |
| 2956 loser: | 2964 loser: |
| 2957 ssl_DestroySocketContents(ss); | 2965 ssl_DestroySocketContents(ss); |
| 2958 ssl_DestroyLocks(ss); | 2966 ssl_DestroyLocks(ss); |
| 2959 PORT_Free(ss); | 2967 PORT_Free(ss); |
| 2960 ss = NULL; | 2968 ss = NULL; |
| 2961 } | 2969 } |
| 2962 ss->protocolVariant = protocolVariant; | 2970 ss->protocolVariant = protocolVariant; |
| 2963 } | 2971 } |
| 2964 return ss; | 2972 return ss; |
| 2965 } | 2973 } |
| 2966 | 2974 |
| OLD | NEW |