summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorStelios Fragkakis <52996999+stelfrag@users.noreply.github.com>2024-05-15 23:49:29 +0300
committerGitHub <noreply@github.com>2024-05-15 23:49:29 +0300
commite1d8b9bdbfe7ec234ab61cf67c4bae4a5aa08915 (patch)
tree6df229d38397a9ab5d9323da2700af4fa31648db /src
parent0788158bd310266c71ad911370a6e88b80bc02fc (diff)
Include the Host in the HTTP header (#17670)
Include the host in the header
Diffstat (limited to 'src')
-rw-r--r--src/aclk/https_client.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/aclk/https_client.c b/src/aclk/https_client.c
index 7fed1962a0..df647ce663 100644
--- a/src/aclk/https_client.c
+++ b/src/aclk/https_client.c
@@ -524,9 +524,7 @@ static int handle_http_request(https_req_ctx_t *ctx) {
buffer_strcat(hdr, HTTP_1_1 HTTP_ENDL);
//TODO Headers!
- if (ctx->request->request_type != HTTP_REQ_CONNECT) {
- buffer_sprintf(hdr, "Host: %s\x0D\x0A", ctx->request->host);
- }
+ buffer_sprintf(hdr, "Host: %s\x0D\x0A", ctx->request->host);
buffer_strcat(hdr, "User-Agent: Netdata/rocks newhttpclient\x0D\x0A");
if (ctx->request->request_type == HTTP_REQ_POST && ctx->request->payload && ctx->request->payload_size) {