Add tor outbound
This commit is contained in:
@@ -17,7 +17,8 @@ type _Outbound struct {
|
||||
VMessOptions VMessOutboundOptions `json:"-"`
|
||||
TrojanOptions TrojanOutboundOptions `json:"-"`
|
||||
WireGuardOptions WireGuardOutboundOptions `json:"-"`
|
||||
HysteriaOutbound HysteriaOutboundOptions `json:"-"`
|
||||
HysteriaOptions HysteriaOutboundOptions `json:"-"`
|
||||
TorOptions TorOutboundOptions `json:"-"`
|
||||
SelectorOptions SelectorOutboundOptions `json:"-"`
|
||||
}
|
||||
|
||||
@@ -43,7 +44,9 @@ func (h Outbound) MarshalJSON() ([]byte, error) {
|
||||
case C.TypeWireGuard:
|
||||
v = h.WireGuardOptions
|
||||
case C.TypeHysteria:
|
||||
v = h.HysteriaOutbound
|
||||
v = h.HysteriaOptions
|
||||
case C.TypeTor:
|
||||
v = h.TorOptions
|
||||
case C.TypeSelector:
|
||||
v = h.SelectorOptions
|
||||
default:
|
||||
@@ -76,7 +79,9 @@ func (h *Outbound) UnmarshalJSON(bytes []byte) error {
|
||||
case C.TypeWireGuard:
|
||||
v = &h.WireGuardOptions
|
||||
case C.TypeHysteria:
|
||||
v = &h.HysteriaOutbound
|
||||
v = &h.HysteriaOptions
|
||||
case C.TypeTor:
|
||||
v = &h.TorOptions
|
||||
case C.TypeSelector:
|
||||
v = &h.SelectorOptions
|
||||
default:
|
||||
|
||||
Reference in New Issue
Block a user