sing

package
v0.0.0-...-af9fb20 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 27, 2023 License: MPL-2.0 Imports: 46 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(c *conf.CoreConfig) (vCore.Core, error)

Types

type Box

type Box struct {
	// contains filtered or unexported fields
}

func (*Box) AddNode

func (b *Box) AddNode(tag string, info *panel.NodeInfo, config *conf.Options) error

func (*Box) AddUsers

func (b *Box) AddUsers(p *core.AddUsersParams) (added int, err error)

func (*Box) Close

func (b *Box) Close() error

func (*Box) DelNode

func (b *Box) DelNode(tag string) error

func (*Box) DelUsers

func (b *Box) DelUsers(users []panel.UserInfo, tag string) error

func (*Box) GetUserTraffic

func (b *Box) GetUserTraffic(tag, uuid string, reset bool) (up int64, down int64)

func (*Box) PreStart

func (b *Box) PreStart() error

func (*Box) Protocols

func (b *Box) Protocols() []string

func (*Box) Router

func (b *Box) Router() adapter.Router

func (*Box) Start

func (b *Box) Start() error

func (*Box) Type

func (b *Box) Type() string

type DNSConfig

type DNSConfig struct {
	Servers []map[string]interface{} `json:"servers"`
	Rules   []map[string]interface{} `json:"rules"`
}

type HookServer

type HookServer struct {
	// contains filtered or unexported fields
}

func NewHookServer

func NewHookServer(logger log.Logger) *HookServer

func (*HookServer) CacheFile

func (h *HookServer) CacheFile() adapter.ClashCacheFile

func (*HookServer) Close

func (h *HookServer) Close() error

func (*HookServer) HistoryStorage

func (h *HookServer) HistoryStorage() *urltest.HistoryStorage

func (*HookServer) Mode

func (h *HookServer) Mode() string

func (*HookServer) ModeList

func (h *HookServer) ModeList() []string

func (*HookServer) PreStart

func (h *HookServer) PreStart() error

func (*HookServer) RoutedConnection

func (h *HookServer) RoutedConnection(_ context.Context, conn net.Conn, m adapter.InboundContext, _ adapter.Rule) (net.Conn, adapter.Tracker)

func (*HookServer) RoutedPacketConnection

func (h *HookServer) RoutedPacketConnection(_ context.Context, conn N.PacketConn, m adapter.InboundContext, _ adapter.Rule) (N.PacketConn, adapter.Tracker)

func (*HookServer) Start

func (h *HookServer) Start() error

func (*HookServer) StoreFakeIP

func (h *HookServer) StoreFakeIP() bool

func (*HookServer) StoreSelected

func (h *HookServer) StoreSelected() bool

type Tracker

type Tracker struct {
	// contains filtered or unexported fields
}

func (*Tracker) Leave

func (t *Tracker) Leave()

type UserDeleter

type UserDeleter interface {
	DelUsers(uuid []string) error
}

type WsNetworkConfig

type WsNetworkConfig struct {
	Path    string            `json:"path"`
	Headers map[string]string `json:"headers"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL