chore: the uuid-map is transferred to the protocol

This commit is contained in:
Skyxim
2022-05-06 13:28:09 +08:00
parent a08e39faec
commit a95d439852
7 changed files with 111 additions and 33 deletions

View File

@ -2,6 +2,7 @@ package vmess
import (
"fmt"
"github.com/Dreamacro/clash/common/utils"
"math/rand"
"net"
"runtime"
@ -82,7 +83,7 @@ func (c *Client) StreamConn(conn net.Conn, dst *DstAddr) (net.Conn, error) {
// NewClient return Client instance
func NewClient(config Config) (*Client, error) {
uid, err := uuid.FromString(config.UUID)
uid, err := utils.UUIDMap(config.UUID)
if err != nil {
return nil, err
}