| 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 1512 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1523 make_scoped_refptr(new SSLErrorParams(net_error, 0))); | 1523 make_scoped_refptr(new SSLErrorParams(net_error, 0))); |
| 1524 } | 1524 } |
| 1525 } else { | 1525 } else { |
| 1526 PRErrorCode prerr = PR_GetError(); | 1526 PRErrorCode prerr = PR_GetError(); |
| 1527 net_error = HandleNSSError(prerr, true); | 1527 net_error = HandleNSSError(prerr, true); |
| 1528 | 1528 |
| 1529 // If not done, stay in this state | 1529 // If not done, stay in this state |
| 1530 if (net_error == ERR_IO_PENDING) { | 1530 if (net_error == ERR_IO_PENDING) { |
| 1531 GotoState(STATE_HANDSHAKE); | 1531 GotoState(STATE_HANDSHAKE); |
| 1532 } else { | 1532 } else { |
| 1533 LOG(ERROR) << "handshake with server " << host_and_port_.ToString() | |
| 1534 << " failed; NSS error code " << prerr | |
| 1535 << ", net_error " << net_error; | |
| 1536 net_log_.AddEvent( | 1533 net_log_.AddEvent( |
| 1537 NetLog::TYPE_SSL_HANDSHAKE_ERROR, | 1534 NetLog::TYPE_SSL_HANDSHAKE_ERROR, |
| 1538 make_scoped_refptr(new SSLErrorParams(net_error, prerr))); | 1535 make_scoped_refptr(new SSLErrorParams(net_error, prerr))); |
| 1539 } | 1536 } |
| 1540 } | 1537 } |
| 1541 | 1538 |
| 1542 LeaveFunction(""); | 1539 LeaveFunction(""); |
| 1543 return net_error; | 1540 return net_error; |
| 1544 } | 1541 } |
| 1545 | 1542 |
| (...skipping 1070 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2616 EnsureThreadIdAssigned(); | 2613 EnsureThreadIdAssigned(); |
| 2617 base::AutoLock auto_lock(lock_); | 2614 base::AutoLock auto_lock(lock_); |
| 2618 return valid_thread_id_ == base::PlatformThread::CurrentId(); | 2615 return valid_thread_id_ == base::PlatformThread::CurrentId(); |
| 2619 } | 2616 } |
| 2620 | 2617 |
| 2621 ServerBoundCertService* SSLClientSocketNSS::GetServerBoundCertService() const { | 2618 ServerBoundCertService* SSLClientSocketNSS::GetServerBoundCertService() const { |
| 2622 return server_bound_cert_service_; | 2619 return server_bound_cert_service_; |
| 2623 } | 2620 } |
| 2624 | 2621 |
| 2625 } // namespace net | 2622 } // namespace net |
| OLD | NEW |