github.com/v2fly/v2ray-core/v5@v5.16.2-0.20240507031116-8191faa6e095/app/policy/config.proto (about) 1 syntax = "proto3"; 2 3 package v2ray.core.app.policy; 4 option csharp_namespace = "V2Ray.Core.App.Policy"; 5 option go_package = "github.com/v2fly/v2ray-core/v5/app/policy"; 6 option java_package = "com.v2ray.core.app.policy"; 7 option java_multiple_files = true; 8 9 import "common/protoext/extensions.proto"; 10 11 message Second { 12 uint32 value = 1; 13 } 14 15 message Policy { 16 // Timeout is a message for timeout settings in various stages, in seconds. 17 message Timeout { 18 Second handshake = 1; 19 Second connection_idle = 2; 20 Second uplink_only = 3; 21 Second downlink_only = 4; 22 } 23 24 message Stats { 25 bool user_uplink = 1; 26 bool user_downlink = 2; 27 } 28 29 message Buffer { 30 // Buffer size per connection, in bytes. -1 for unlimited buffer. 31 int32 connection = 1; 32 } 33 34 Timeout timeout = 1; 35 Stats stats = 2; 36 Buffer buffer = 3; 37 } 38 39 message SystemPolicy { 40 message Stats { 41 bool inbound_uplink = 1; 42 bool inbound_downlink = 2; 43 bool outbound_uplink = 3; 44 bool outbound_downlink = 4; 45 } 46 47 Stats stats = 1; 48 bool override_access_log_dest = 2; 49 } 50 51 message Config { 52 option (v2ray.core.common.protoext.message_opt).type = "service"; 53 option (v2ray.core.common.protoext.message_opt).short_name = "policy"; 54 55 map<uint32, Policy> level = 1; 56 SystemPolicy system = 2; 57 }