Xray-docs-next/docs/en/config/outbounds/blackhole.md

35 lines
828 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

# Blackhole
Blackhole黑洞是一个出站数据协议它会阻碍所有数据的出站配合 [路由配置](../routing.md) 一起使用,可以达到禁止访问某些网站的效果。
## OutboundConfigurationObject
```json
{
"response": {
"type": "none"
}
}
```
> `response`: [ResponseObject](#responseobject)
配置黑洞的响应数据。
Blackhole 会在收到待转发数据之后,发送指定的响应数据,然后关闭连接,待转发的数据将被丢弃。
如不指定此项Blackhole 将直接关闭连接。
### ResponseObject
```json
{
"type": "none"
}
```
> `type`: "http" | "none"
`type``"none"`默认值Blackhole 将直接关闭连接。
`type``"http"`Blackhole 会发回一个简单的 HTTP 403 数据包,然后关闭连接。