Hunter0x7c7
2022-08-11 a82f9cb69f63aaeba40c024960deda7d75b9fece
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
syntax = "proto3";
 
package v2ray.core.proxy.socks;
option csharp_namespace = "V2Ray.Core.Proxy.Socks";
option go_package = "github.com/v2fly/v2ray-core/v5/proxy/socks";
option java_package = "com.v2ray.core.proxy.socks";
option java_multiple_files = true;
 
import "common/net/address.proto";
import "common/net/packetaddr/config.proto";
import "common/protocol/server_spec.proto";
 
// Account represents a Socks account.
message Account {
  string username = 1;
  string password = 2;
}
 
// AuthType is the authentication type of Socks proxy.
enum AuthType {
  // NO_AUTH is for anonymous authentication.
  NO_AUTH = 0;
  // PASSWORD is for username/password authentication.
  PASSWORD = 1;
}
 
enum Version {
  SOCKS5 = 0;
  SOCKS4 = 1;
  SOCKS4A = 2;
}
 
 
// ServerConfig is the protobuf config for Socks server.
message ServerConfig {
  AuthType auth_type = 1;
  map<string, string> accounts = 2;
  v2ray.core.common.net.IPOrDomain address = 3;
  bool udp_enabled = 4;
  uint32 timeout = 5 [deprecated = true];
  uint32 user_level = 6;
 
  v2ray.core.net.packetaddr.PacketAddrType packet_encoding = 7;
}
 
// ClientConfig is the protobuf config for Socks client.
message ClientConfig {
  // Sever is a list of Socks server addresses.
  repeated v2ray.core.common.protocol.ServerEndpoint server = 1;
  Version version = 2;
}