github.com/inazumav/sing-box@v0.0.0-20230926072359-ab51429a14f1/docs/configuration/inbound/trojan.md (about)

     1  ### Structure
     2  
     3  ```json
     4  {
     5    "type": "trojan",
     6    "tag": "trojan-in",
     7  
     8    ... // Listen Fields
     9  
    10    "users": [
    11      {
    12        "name": "sekai",
    13        "password": "8JCsPssfgS8tiRwiMlhARg=="
    14      }
    15    ],
    16    "tls": {},
    17    "fallback": {
    18      "server": "127.0.0.1",
    19      "server_port": 8080
    20    },
    21    "fallback_for_alpn": {
    22      "http/1.1": {
    23        "server": "127.0.0.1",
    24        "server_port": 8081
    25      }
    26    },
    27    "transport": {}
    28  }
    29  ```
    30  
    31  ### Listen Fields
    32  
    33  See [Listen Fields](/configuration/shared/listen) for details.
    34  
    35  ### Fields
    36  
    37  #### users
    38  
    39  ==Required==
    40  
    41  Trojan users.
    42  
    43  #### tls
    44  
    45  TLS configuration, see [TLS](/configuration/shared/tls/#inbound).
    46  
    47  #### fallback
    48  
    49  !!! error ""
    50  
    51      There is no evidence that GFW detects and blocks Trojan servers based on HTTP responses, and opening the standard http/s port on the server is a much bigger signature.
    52  
    53  Fallback server configuration. Disabled if `fallback` and `fallback_for_alpn` are empty.
    54  
    55  #### fallback_for_alpn
    56  
    57  Fallback server configuration for specified ALPN.
    58  
    59  If not empty, TLS fallback requests with ALPN not in this table will be rejected.
    60  
    61  #### transport
    62  
    63  V2Ray Transport configuration, see [V2Ray Transport](/configuration/shared/v2ray-transport).