1234567891011121314151617181920212223242526272829303132333435363738394041424344454647 |
- package proxy
- import (
- "reflect"
- "github.com/fatedier/frp/pkg/config"
- )
- func init() {
- pxyConfs := []config.ProxyConf{
- &config.TCPProxyConf{},
- &config.HTTPProxyConf{},
- &config.HTTPSProxyConf{},
- &config.STCPProxyConf{},
- &config.TCPMuxProxyConf{},
- }
- for _, cfg := range pxyConfs {
- RegisterProxyFactory(reflect.TypeOf(cfg), NewGeneralTCPProxy)
- }
- }
- type GeneralTCPProxy struct {
- *BaseProxy
- }
- func NewGeneralTCPProxy(baseProxy *BaseProxy, cfg config.ProxyConf) Proxy {
- return &GeneralTCPProxy{
- BaseProxy: baseProxy,
- }
- }
|