mirror of
https://github.com/v2fly/v2ray-core.git
synced 2024-12-22 01:57:12 -05:00
22 lines
482 B
Go
22 lines
482 B
Go
package freedom
|
|
|
|
import (
|
|
"github.com/v2ray/v2ray-core"
|
|
v2net "github.com/v2ray/v2ray-core/common/net"
|
|
)
|
|
|
|
type FreedomFactory struct {
|
|
}
|
|
|
|
func (factory FreedomFactory) Initialize(config []byte) error {
|
|
return nil
|
|
}
|
|
|
|
func (factory FreedomFactory) Create(vp *core.Point, firstPacket v2net.Packet) (core.OutboundConnectionHandler, error) {
|
|
return NewFreedomConnection(firstPacket), nil
|
|
}
|
|
|
|
func init() {
|
|
core.RegisterOutboundConnectionHandlerFactory("freedom", FreedomFactory{})
|
|
}
|