mirror of
https://github.com/XTLS/Xray-docs-next.git
synced 2026-10-04 04:48:17 +03:00
Dinalmask: Add exp to noise (#902)
* Finalmask: Add "tag" to noise items * Finalmask: Rename noise "tag" to "exp" * Finalmask: Move noise "exp" into "type"
This commit is contained in:
@@ -314,10 +314,22 @@ FinalMask 在核心处理完包括 TLS/REALITY 在内的传输层加密后,对
|
||||
|
||||
`randRange`: 随机字节范围,默认 0-255。
|
||||
|
||||
`type`: `packet` 类型,`array | str | hex | base64`,默认为 array。
|
||||
`type`: `packet` 类型,`array | str | hex | base64 | exp`,默认为 array。
|
||||
|
||||
`packet`: 添加固定数据,与 `rand` 冲突
|
||||
|
||||
`type` 为 `exp` 时,`packet` 是一个表达式字符串,由它拼成一个噪声包,每次发送时重新生成,因此可以携带时间戳等变化的内容。表达式的各部分按顺序拼接成一个包:
|
||||
|
||||
- `<b hex>`:固定字节,以十六进制书写,可省略的 `0x` 前缀会被忽略
|
||||
- `<r N>` 或 `<r A-B>`:`N` 个随机字节,或 `A` 到 `B` 之间随机个数
|
||||
- `<rc N>` 或 `<rc A-B>`:同上,随机字母(`a-zA-Z`)
|
||||
- `<rd N>` 或 `<rd A-B>`:同上,随机数字(`0-9`)
|
||||
- `<t>`:当前 Unix 时间(秒),4 字节大端
|
||||
- `<c>`:计数器,4 字节大端,每次加一
|
||||
- `<n>`:8 个随机字节
|
||||
|
||||
例如 `{"type": "exp", "packet": "<b 0d0a0d0a><t><r 24>"}` 会把 `\r\n\r\n`、时间戳和 24 个随机字节作为一个包发送。
|
||||
|
||||
`delay`: 单位毫秒,发送噪声后延迟指定时间后再发下一个。
|
||||
|
||||
### salamander
|
||||
|
||||
Reference in New Issue
Block a user