Implement client side ACL for SOCKS5 TCP

This commit is contained in:
Toby
2020-04-26 14:58:50 -07:00
parent ee8558f2fb
commit 127e9e1b6c
8 changed files with 232 additions and 77 deletions

View File

@@ -1,11 +1,13 @@
package acl
import (
lru "github.com/hashicorp/golang-lru"
"net"
"testing"
)
func TestEngine_Lookup(t *testing.T) {
cache, _ := lru.NewARC(4)
e := &Engine{
DefaultAction: ActionDirect,
Entries: []Entry{
@@ -45,6 +47,7 @@ func TestEngine_Lookup(t *testing.T) {
ActionArg: "",
},
},
Cache: cache,
}
type args struct {
domain string