Inbound rule support

This commit is contained in:
世界
2022-07-02 14:07:50 +08:00
parent 9f4c0ff624
commit 7c57eb70e8
34 changed files with 622 additions and 247 deletions

View File

@@ -6,9 +6,9 @@ import (
"net"
"github.com/sagernet/sing-box/adapter"
"github.com/sagernet/sing-box/config"
C "github.com/sagernet/sing-box/constant"
"github.com/sagernet/sing-box/log"
"github.com/sagernet/sing-box/option"
"github.com/sagernet/sing/common/auth"
"github.com/sagernet/sing/common/buf"
"github.com/sagernet/sing/common/bufio"
@@ -27,7 +27,7 @@ type Mixed struct {
authenticator auth.Authenticator
}
func NewMixed(ctx context.Context, router adapter.Router, logger log.Logger, tag string, options *config.SimpleInboundOptions) *Mixed {
func NewMixed(ctx context.Context, router adapter.Router, logger log.Logger, tag string, options *option.SimpleInboundOptions) *Mixed {
inbound := &Mixed{
myInboundAdapter{
protocol: C.TypeMixed,