Add headerType for trojan & vless share link

This commit is contained in:
arm64v8a
2023-01-31 17:23:53 +09:00
parent 1c0d0f8dbc
commit 9f7a830d2a
2 changed files with 10 additions and 0 deletions

View File

@@ -41,6 +41,11 @@ namespace NekoRay::fmt {
if (!stream->host.isEmpty()) query.addQueryItem("host", stream->host);
} else if (stream->network == "grpc") {
if (!stream->path.isEmpty()) query.addQueryItem("serviceName", stream->path);
} else if (stream->network == "tcp") {
if (stream->header_type == "http") {
query.addQueryItem("headerType", "http");
query.addQueryItem("host", stream->host);
}
}
url.setQuery(query);