Add udp over tcp support for shadowsocks-2022

This commit is contained in:
世界 2022-06-01 11:12:43 +08:00
parent 6f93ef7736
commit c3505632fd
No known key found for this signature in database
GPG key ID: CD109927C34A63C4
14 changed files with 119 additions and 33 deletions

View file

@ -211,6 +211,10 @@ func (h *Handler) Dial(ctx context.Context, dest net.Destination) (stat.Connecti
}
}
if conn, err := h.getUoTConnection(ctx, dest); err != os.ErrInvalid {
return conn, err
}
conn, err := internet.Dial(ctx, dest, h.streamSettings)
return h.getStatCouterConnection(conn), err
}