OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2004 The WebRTC Project Authors. All rights reserved. | 2 * Copyright 2004 The WebRTC Project Authors. All rights reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
(...skipping 28 matching lines...) Expand all Loading... |
39 PORTALLOCATOR_ENABLE_SHAKER = 0x10, | 39 PORTALLOCATOR_ENABLE_SHAKER = 0x10, |
40 PORTALLOCATOR_ENABLE_IPV6 = 0x40, | 40 PORTALLOCATOR_ENABLE_IPV6 = 0x40, |
41 // TODO(pthatcher): Remove this once it's no longer used in: | 41 // TODO(pthatcher): Remove this once it's no longer used in: |
42 // remoting/client/plugin/pepper_port_allocator.cc | 42 // remoting/client/plugin/pepper_port_allocator.cc |
43 // remoting/protocol/chromium_port_allocator.cc | 43 // remoting/protocol/chromium_port_allocator.cc |
44 // remoting/test/fake_port_allocator.cc | 44 // remoting/test/fake_port_allocator.cc |
45 // It's a no-op and is no longer needed. | 45 // It's a no-op and is no longer needed. |
46 PORTALLOCATOR_ENABLE_SHARED_UFRAG = 0x80, | 46 PORTALLOCATOR_ENABLE_SHARED_UFRAG = 0x80, |
47 PORTALLOCATOR_ENABLE_SHARED_SOCKET = 0x100, | 47 PORTALLOCATOR_ENABLE_SHARED_SOCKET = 0x100, |
48 PORTALLOCATOR_ENABLE_STUN_RETRANSMIT_ATTRIBUTE = 0x200, | 48 PORTALLOCATOR_ENABLE_STUN_RETRANSMIT_ATTRIBUTE = 0x200, |
| 49 // When specified, we'll only allocate the STUN candidate for the public |
| 50 // interface as seen by regular http traffic and the HOST candidate associated |
| 51 // with the default local interface. |
49 PORTALLOCATOR_DISABLE_ADAPTER_ENUMERATION = 0x400, | 52 PORTALLOCATOR_DISABLE_ADAPTER_ENUMERATION = 0x400, |
50 // When specified, a loopback candidate will be generated if | 53 // When specified along with PORTALLOCATOR_DISABLE_ADAPTER_ENUMERATION, the |
51 // PORTALLOCATOR_DISABLE_ADAPTER_ENUMERATION is specified. | 54 // default local candidate mentioned above will not be allocated. Only the |
52 PORTALLOCATOR_ENABLE_LOCALHOST_CANDIDATE = 0x800, | 55 // STUN candidate will be. |
| 56 PORTALLOCATOR_DISABLE_DEFAULT_LOCAL_CANDIDATE = 0x800, |
53 // Disallow use of UDP when connecting to a relay server. Since proxy servers | 57 // Disallow use of UDP when connecting to a relay server. Since proxy servers |
54 // usually don't handle UDP, using UDP will leak the IP address. | 58 // usually don't handle UDP, using UDP will leak the IP address. |
55 PORTALLOCATOR_DISABLE_UDP_RELAY = 0x1000, | 59 PORTALLOCATOR_DISABLE_UDP_RELAY = 0x1000, |
56 }; | 60 }; |
57 | 61 |
58 const uint32_t kDefaultPortAllocatorFlags = 0; | 62 const uint32_t kDefaultPortAllocatorFlags = 0; |
59 | 63 |
60 const uint32_t kDefaultStepDelay = 1000; // 1 sec step delay. | 64 const uint32_t kDefaultStepDelay = 1000; // 1 sec step delay. |
61 // As per RFC 5245 Appendix B.1, STUN transactions need to be paced at certain | 65 // As per RFC 5245 Appendix B.1, STUN transactions need to be paced at certain |
62 // internal. Less than 20ms is not acceptable. We choose 50ms as our default. | 66 // internal. Less than 20ms is not acceptable. We choose 50ms as our default. |
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
200 int max_port_; | 204 int max_port_; |
201 uint32_t step_delay_; | 205 uint32_t step_delay_; |
202 bool allow_tcp_listen_; | 206 bool allow_tcp_listen_; |
203 uint32_t candidate_filter_; | 207 uint32_t candidate_filter_; |
204 std::string origin_; | 208 std::string origin_; |
205 }; | 209 }; |
206 | 210 |
207 } // namespace cricket | 211 } // namespace cricket |
208 | 212 |
209 #endif // WEBRTC_P2P_BASE_PORTALLOCATOR_H_ | 213 #endif // WEBRTC_P2P_BASE_PORTALLOCATOR_H_ |
OLD | NEW |