diff --git a/sub/subService.go b/sub/subService.go index dfb0863e..7ddca3b3 100644 --- a/sub/subService.go +++ b/sub/subService.go @@ -313,6 +313,9 @@ func (s *SubService) genVlessLink(inbound *model.Inbound, email string) string { if inbound.Protocol != model.VLESS { return "" } + var vlessSettings model.VLESSSettings + _ = json.Unmarshal([]byte(inbound.Settings), &vlessSettings) + var stream map[string]any json.Unmarshal([]byte(inbound.StreamSettings), &stream) clients, _ := s.inboundService.GetClients(inbound) @@ -327,6 +330,9 @@ func (s *SubService) genVlessLink(inbound *model.Inbound, email string) string { port := inbound.Port streamNetwork := stream["network"].(string) params := make(map[string]string) + if vlessSettings.Encryption != "" { + params["encryption"] = vlessSettings.Encryption + } params["type"] = streamNetwork switch streamNetwork {