| 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 #ifndef NET_QUIC_QUIC_PROTOCOL_H_ | 5 #ifndef NET_QUIC_QUIC_PROTOCOL_H_ |
| 6 #define NET_QUIC_QUIC_PROTOCOL_H_ | 6 #define NET_QUIC_QUIC_PROTOCOL_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 637 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 648 // An invalid channel id signature was supplied. | 648 // An invalid channel id signature was supplied. |
| 649 QUIC_INVALID_CHANNEL_ID_SIGNATURE = 52, | 649 QUIC_INVALID_CHANNEL_ID_SIGNATURE = 52, |
| 650 // A crypto message was received with a mandatory parameter missing. | 650 // A crypto message was received with a mandatory parameter missing. |
| 651 QUIC_CRYPTO_MESSAGE_PARAMETER_NOT_FOUND = 35, | 651 QUIC_CRYPTO_MESSAGE_PARAMETER_NOT_FOUND = 35, |
| 652 // A crypto message was received with a parameter that has no overlap | 652 // A crypto message was received with a parameter that has no overlap |
| 653 // with the local parameter. | 653 // with the local parameter. |
| 654 QUIC_CRYPTO_MESSAGE_PARAMETER_NO_OVERLAP = 36, | 654 QUIC_CRYPTO_MESSAGE_PARAMETER_NO_OVERLAP = 36, |
| 655 // A crypto message was received that contained a parameter with too few | 655 // A crypto message was received that contained a parameter with too few |
| 656 // values. | 656 // values. |
| 657 QUIC_CRYPTO_MESSAGE_INDEX_NOT_FOUND = 37, | 657 QUIC_CRYPTO_MESSAGE_INDEX_NOT_FOUND = 37, |
| 658 // A demand for an unsupport proof type was received. |
| 659 QUIC_UNSUPPORTED_PROOF_DEMAND = 94, |
| 658 // An internal error occured in crypto processing. | 660 // An internal error occured in crypto processing. |
| 659 QUIC_CRYPTO_INTERNAL_ERROR = 38, | 661 QUIC_CRYPTO_INTERNAL_ERROR = 38, |
| 660 // A crypto handshake message specified an unsupported version. | 662 // A crypto handshake message specified an unsupported version. |
| 661 QUIC_CRYPTO_VERSION_NOT_SUPPORTED = 39, | 663 QUIC_CRYPTO_VERSION_NOT_SUPPORTED = 39, |
| 662 // A crypto handshake message resulted in a stateless reject. | 664 // A crypto handshake message resulted in a stateless reject. |
| 663 QUIC_CRYPTO_HANDSHAKE_STATELESS_REJECT = 72, | 665 QUIC_CRYPTO_HANDSHAKE_STATELESS_REJECT = 72, |
| 664 // There was no intersection between the crypto primitives supported by the | 666 // There was no intersection between the crypto primitives supported by the |
| 665 // peer and ourselves. | 667 // peer and ourselves. |
| 666 QUIC_CRYPTO_NO_SUPPORT = 40, | 668 QUIC_CRYPTO_NO_SUPPORT = 40, |
| 667 // The server rejected our client hello messages too many times. | 669 // The server rejected our client hello messages too many times. |
| (...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 708 // migrate to. | 710 // migrate to. |
| 709 QUIC_CONNECTION_MIGRATION_NO_NEW_NETWORK = 83, | 711 QUIC_CONNECTION_MIGRATION_NO_NEW_NETWORK = 83, |
| 710 // Network changed, but connection had one or more non-migratable streams. | 712 // Network changed, but connection had one or more non-migratable streams. |
| 711 QUIC_CONNECTION_MIGRATION_NON_MIGRATABLE_STREAM = 84, | 713 QUIC_CONNECTION_MIGRATION_NON_MIGRATABLE_STREAM = 84, |
| 712 | 714 |
| 713 // Stream frames arrived too discontiguously so that stream sequencer buffer | 715 // Stream frames arrived too discontiguously so that stream sequencer buffer |
| 714 // maintains too many gaps. | 716 // maintains too many gaps. |
| 715 QUIC_TOO_MANY_FRAME_GAPS = 93, | 717 QUIC_TOO_MANY_FRAME_GAPS = 93, |
| 716 | 718 |
| 717 // No error. Used as bound while iterating. | 719 // No error. Used as bound while iterating. |
| 718 QUIC_LAST_ERROR = 94, | 720 QUIC_LAST_ERROR = 95, |
| 719 }; | 721 }; |
| 720 | 722 |
| 721 typedef char DiversificationNonce[32]; | 723 typedef char DiversificationNonce[32]; |
| 722 | 724 |
| 723 struct NET_EXPORT_PRIVATE QuicPacketPublicHeader { | 725 struct NET_EXPORT_PRIVATE QuicPacketPublicHeader { |
| 724 QuicPacketPublicHeader(); | 726 QuicPacketPublicHeader(); |
| 725 explicit QuicPacketPublicHeader(const QuicPacketPublicHeader& other); | 727 explicit QuicPacketPublicHeader(const QuicPacketPublicHeader& other); |
| 726 ~QuicPacketPublicHeader(); | 728 ~QuicPacketPublicHeader(); |
| 727 | 729 |
| 728 // Universal header. All QuicPacket headers will have a connection_id and | 730 // Universal header. All QuicPacket headers will have a connection_id and |
| (...skipping 683 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1412 // Used to generate filtered supported versions based on flags. | 1414 // Used to generate filtered supported versions based on flags. |
| 1413 class NET_EXPORT_PRIVATE QuicVersionManager { | 1415 class NET_EXPORT_PRIVATE QuicVersionManager { |
| 1414 public: | 1416 public: |
| 1415 explicit QuicVersionManager(QuicVersionVector supported_versions); | 1417 explicit QuicVersionManager(QuicVersionVector supported_versions); |
| 1416 ~QuicVersionManager(); | 1418 ~QuicVersionManager(); |
| 1417 | 1419 |
| 1418 // Returns supported versions based on flags. | 1420 // Returns supported versions based on flags. |
| 1419 const QuicVersionVector& GetSupportedVersions(); | 1421 const QuicVersionVector& GetSupportedVersions(); |
| 1420 | 1422 |
| 1421 private: | 1423 private: |
| 1424 // FLAGS_quic_disable_pre_32 |
| 1425 bool disable_pre_32_; |
| 1422 // FLAGS_quic_enable_version_35 | 1426 // FLAGS_quic_enable_version_35 |
| 1423 bool enable_quic_version_35_; | 1427 bool enable_version_35_; |
| 1424 // FLAGS_quic_enable_version_36_v2 | 1428 // FLAGS_quic_enable_version_36_v2 |
| 1425 bool enable_quic_version_36_; | 1429 bool enable_version_36_; |
| 1426 // The list of versions that may be supported. | 1430 // The list of versions that may be supported. |
| 1427 QuicVersionVector allowed_supported_versions_; | 1431 QuicVersionVector allowed_supported_versions_; |
| 1428 // This vector contains QUIC versions which are currently supported based | 1432 // This vector contains QUIC versions which are currently supported based |
| 1429 // on flags. | 1433 // on flags. |
| 1430 QuicVersionVector filtered_supported_versions_; | 1434 QuicVersionVector filtered_supported_versions_; |
| 1431 }; | 1435 }; |
| 1432 | 1436 |
| 1433 struct NET_EXPORT_PRIVATE AckListenerWrapper { | 1437 struct NET_EXPORT_PRIVATE AckListenerWrapper { |
| 1434 AckListenerWrapper(QuicAckListenerInterface* listener, | 1438 AckListenerWrapper(QuicAckListenerInterface* listener, |
| 1435 QuicPacketLength data_length); | 1439 QuicPacketLength data_length); |
| (...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1554 : iov(iov), iov_count(iov_count), total_length(total_length) {} | 1558 : iov(iov), iov_count(iov_count), total_length(total_length) {} |
| 1555 | 1559 |
| 1556 const struct iovec* iov; | 1560 const struct iovec* iov; |
| 1557 const int iov_count; | 1561 const int iov_count; |
| 1558 const size_t total_length; | 1562 const size_t total_length; |
| 1559 }; | 1563 }; |
| 1560 | 1564 |
| 1561 } // namespace net | 1565 } // namespace net |
| 1562 | 1566 |
| 1563 #endif // NET_QUIC_QUIC_PROTOCOL_H_ | 1567 #endif // NET_QUIC_QUIC_PROTOCOL_H_ |
| OLD | NEW |