| 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 #include "net/spdy/spdy_session.h" | 5 #include "net/spdy/spdy_session.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <map> | 8 #include <map> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 580 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 591 ChannelIDService::GetDomainForHost(new_hostname) != | 591 ChannelIDService::GetDomainForHost(new_hostname) != |
| 592 ChannelIDService::GetDomainForHost(old_hostname)) { | 592 ChannelIDService::GetDomainForHost(old_hostname)) { |
| 593 return false; | 593 return false; |
| 594 } | 594 } |
| 595 | 595 |
| 596 bool unused = false; | 596 bool unused = false; |
| 597 if (!ssl_info.cert->VerifyNameMatch(new_hostname, &unused)) | 597 if (!ssl_info.cert->VerifyNameMatch(new_hostname, &unused)) |
| 598 return false; | 598 return false; |
| 599 | 599 |
| 600 std::string pinning_failure_log; | 600 std::string pinning_failure_log; |
| 601 // TODO(estark): replace 0 below with the port of the connection |
| 602 // (though it won't actually be used since reports aren't getting |
| 603 // sent). |
| 601 if (!transport_security_state->CheckPublicKeyPins( | 604 if (!transport_security_state->CheckPublicKeyPins( |
| 602 new_hostname, | 605 new_hostname, ssl_info.is_issued_by_known_root, |
| 603 ssl_info.is_issued_by_known_root, | 606 ssl_info.public_key_hashes, 0, ssl_info.unverified_cert, |
| 604 ssl_info.public_key_hashes, | 607 ssl_info.cert, |
| 608 TransportSecurityState::DO_NOT_SEND_PUBLIC_KEY_PIN_REPORT, |
| 605 &pinning_failure_log)) { | 609 &pinning_failure_log)) { |
| 606 return false; | 610 return false; |
| 607 } | 611 } |
| 608 | 612 |
| 609 return true; | 613 return true; |
| 610 } | 614 } |
| 611 | 615 |
| 612 SpdySession::SpdySession( | 616 SpdySession::SpdySession( |
| 613 const SpdySessionKey& spdy_session_key, | 617 const SpdySessionKey& spdy_session_key, |
| 614 const base::WeakPtr<HttpServerProperties>& http_server_properties, | 618 const base::WeakPtr<HttpServerProperties>& http_server_properties, |
| (...skipping 2643 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3258 if (!queue->empty()) { | 3262 if (!queue->empty()) { |
| 3259 SpdyStreamId stream_id = queue->front(); | 3263 SpdyStreamId stream_id = queue->front(); |
| 3260 queue->pop_front(); | 3264 queue->pop_front(); |
| 3261 return stream_id; | 3265 return stream_id; |
| 3262 } | 3266 } |
| 3263 } | 3267 } |
| 3264 return 0; | 3268 return 0; |
| 3265 } | 3269 } |
| 3266 | 3270 |
| 3267 } // namespace net | 3271 } // namespace net |
| OLD | NEW |