Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // This file includes code SSLClientSocketNSS::DoVerifyCertComplete() derived | 5 // This file includes code SSLClientSocketNSS::DoVerifyCertComplete() derived |
| 6 // from AuthCertificateCallback() in | 6 // from AuthCertificateCallback() in |
| 7 // mozilla/security/manager/ssl/src/nsNSSCallbacks.cpp. | 7 // mozilla/security/manager/ssl/src/nsNSSCallbacks.cpp. |
| 8 | 8 |
| 9 /* ***** BEGIN LICENSE BLOCK ***** | 9 /* ***** BEGIN LICENSE BLOCK ***** |
| 10 * Version: MPL 1.1/GPL 2.0/LGPL 2.1 | 10 * Version: MPL 1.1/GPL 2.0/LGPL 2.1 |
| (...skipping 2480 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 2491 unsigned buf_len; | 2491 unsigned buf_len; |
| 2492 | 2492 |
| 2493 SECStatus rv = SSL_GetNextProto(nss_fd_, &state, buf, &buf_len, sizeof(buf)); | 2493 SECStatus rv = SSL_GetNextProto(nss_fd_, &state, buf, &buf_len, sizeof(buf)); |
| 2494 if (rv != SECSuccess) | 2494 if (rv != SECSuccess) |
| 2495 return; | 2495 return; |
| 2496 | 2496 |
| 2497 nss_handshake_state_.next_proto = | 2497 nss_handshake_state_.next_proto = |
| 2498 std::string(reinterpret_cast<char*>(buf), buf_len); | 2498 std::string(reinterpret_cast<char*>(buf), buf_len); |
| 2499 switch (state) { | 2499 switch (state) { |
| 2500 case SSL_NEXT_PROTO_NEGOTIATED: | 2500 case SSL_NEXT_PROTO_NEGOTIATED: |
| 2501 case SSL_NEXT_PROTO_SELECTED: | |
|
Ryan Sleevi
2013/07/02 19:13:10
This will affect the histograms for NPN, as well a
| |
| 2501 nss_handshake_state_.next_proto_status = kNextProtoNegotiated; | 2502 nss_handshake_state_.next_proto_status = kNextProtoNegotiated; |
| 2502 break; | 2503 break; |
| 2503 case SSL_NEXT_PROTO_NO_OVERLAP: | 2504 case SSL_NEXT_PROTO_NO_OVERLAP: |
| 2504 nss_handshake_state_.next_proto_status = kNextProtoNoOverlap; | 2505 nss_handshake_state_.next_proto_status = kNextProtoNoOverlap; |
| 2505 break; | 2506 break; |
| 2506 case SSL_NEXT_PROTO_NO_SUPPORT: | 2507 case SSL_NEXT_PROTO_NO_SUPPORT: |
| 2507 nss_handshake_state_.next_proto_status = kNextProtoUnsupported; | 2508 nss_handshake_state_.next_proto_status = kNextProtoUnsupported; |
| 2508 break; | 2509 break; |
| 2509 default: | 2510 default: |
| 2510 NOTREACHED(); | 2511 NOTREACHED(); |
| (...skipping 1009 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 3520 EnsureThreadIdAssigned(); | 3521 EnsureThreadIdAssigned(); |
| 3521 base::AutoLock auto_lock(lock_); | 3522 base::AutoLock auto_lock(lock_); |
| 3522 return valid_thread_id_ == base::PlatformThread::CurrentId(); | 3523 return valid_thread_id_ == base::PlatformThread::CurrentId(); |
| 3523 } | 3524 } |
| 3524 | 3525 |
| 3525 ServerBoundCertService* SSLClientSocketNSS::GetServerBoundCertService() const { | 3526 ServerBoundCertService* SSLClientSocketNSS::GetServerBoundCertService() const { |
| 3526 return server_bound_cert_service_; | 3527 return server_bound_cert_service_; |
| 3527 } | 3528 } |
| 3528 | 3529 |
| 3529 } // namespace net | 3530 } // namespace net |
| OLD | NEW |