Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(92)

Side by Side Diff: net/third_party/nss/ssl/sslsock.c

Issue 91913002: net: boost AES-GCM ciphers if the machine has AES-NI. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add new symbol to .def Created 7 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 * This Source Code Form is subject to the terms of the Mozilla Public 6 * This Source Code Form is subject to the terms of the Mozilla Public
7 * License, v. 2.0. If a copy of the MPL was not distributed with this 7 * License, v. 2.0. If a copy of the MPL was not distributed with this
8 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 8 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
9 #include "seccomon.h" 9 #include "seccomon.h"
10 #include "cert.h" 10 #include "cert.h"
(...skipping 1326 matching lines...) Expand 10 before | Expand all | Expand 10 after
1337 return SECFailure; 1337 return SECFailure;
1338 } 1338 }
1339 if (SSL_IS_SSL2_CIPHER(which)) { 1339 if (SSL_IS_SSL2_CIPHER(which)) {
1340 rv = ssl2_CipherPrefSet(ss, which, enabled); 1340 rv = ssl2_CipherPrefSet(ss, which, enabled);
1341 } else { 1341 } else {
1342 rv = ssl3_CipherPrefSet(ss, (ssl3CipherSuite)which, enabled); 1342 rv = ssl3_CipherPrefSet(ss, (ssl3CipherSuite)which, enabled);
1343 } 1343 }
1344 return rv; 1344 return rv;
1345 } 1345 }
1346 1346
1347 SECStatus
1348 SSL_CipherOrderSet(PRFileDesc *fd, const PRUint16 *ciphers, unsigned int len)
1349 {
1350 sslSocket *ss = ssl_FindSocket(fd);
1351
1352 if (!ss) {
1353 SSL_DBG(("%d: SSL[%d]: bad socket in CipherOrderSet", SSL_GETPID(),
1354 fd));
1355 return SECFailure;
1356 }
1357 return ssl3_CipherOrderSet(ss, ciphers, len);
1358 }
1359
1347 SECStatus 1360 SECStatus
1348 SSL_CipherPrefGet(PRFileDesc *fd, PRInt32 which, PRBool *enabled) 1361 SSL_CipherPrefGet(PRFileDesc *fd, PRInt32 which, PRBool *enabled)
1349 { 1362 {
1350 SECStatus rv; 1363 SECStatus rv;
1351 sslSocket *ss = ssl_FindSocket(fd); 1364 sslSocket *ss = ssl_FindSocket(fd);
1352 1365
1353 if (!enabled) { 1366 if (!enabled) {
1354 PORT_SetError(SEC_ERROR_INVALID_ARGS); 1367 PORT_SetError(SEC_ERROR_INVALID_ARGS);
1355 return SECFailure; 1368 return SECFailure;
1356 } 1369 }
(...skipping 1807 matching lines...) Expand 10 before | Expand all | Expand 10 after
3164 if (status != SECSuccess) { 3177 if (status != SECSuccess) {
3165 loser: 3178 loser:
3166 ssl_DestroySocketContents(ss); 3179 ssl_DestroySocketContents(ss);
3167 ssl_DestroyLocks(ss); 3180 ssl_DestroyLocks(ss);
3168 PORT_Free(ss); 3181 PORT_Free(ss);
3169 ss = NULL; 3182 ss = NULL;
3170 } 3183 }
3171 } 3184 }
3172 return ss; 3185 return ss;
3173 } 3186 }
OLDNEW
« net/socket/nss_ssl_util.cc ('K') | « net/third_party/nss/ssl/sslimpl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698