可以配置是否在反向代理中添加X-Real-IP和X-Forwarded-*

This commit is contained in:
刘祥超
2021-01-26 20:29:41 +08:00
parent 6164cebc62
commit 7a3783a09f
3 changed files with 74 additions and 9 deletions

View File

@@ -15,6 +15,7 @@ type ReverseProxy struct {
RequestHost string `field:"requestHost"` // 请求Host
RequestURI string `field:"requestURI"` // 请求URI
AutoFlush uint8 `field:"autoFlush"` // 是否自动刷新缓冲区
AddHeaders string `field:"addHeaders"` // 自动添加的Header列表
State uint8 `field:"state"` // 状态
CreatedAt uint64 `field:"createdAt"` // 创建时间
}
@@ -33,6 +34,7 @@ type ReverseProxyOperator struct {
RequestHost interface{} // 请求Host
RequestURI interface{} // 请求URI
AutoFlush interface{} // 是否自动刷新缓冲区
AddHeaders interface{} // 自动添加的Header列表
State interface{} // 状态
CreatedAt interface{} // 创建时间
}