From 517a443636daa1e8085cb4e5325524a54e8a8fd7 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Tue, 17 Oct 2023 11:30:23 +0200 Subject: Merging upstream version 1.43.0. Signed-off-by: Daniel Baumann --- registry/registry.c | 4 ++-- registry/registry.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'registry') diff --git a/registry/registry.c b/registry/registry.c index a2a8dd7e..cd33e5ca 100644 --- a/registry/registry.c +++ b/registry/registry.c @@ -163,7 +163,7 @@ void registry_update_cloud_base_url() { // ---------------------------------------------------------------------------- // public HELLO request -int registry_request_hello_json(RRDHOST *host, struct web_client *w) { +int registry_request_hello_json(RRDHOST *host, struct web_client *w, bool do_not_track) { registry_json_header(host, w, "hello", REGISTRY_STATUS_OK); if(host->node_id) @@ -191,7 +191,7 @@ int registry_request_hello_json(RRDHOST *host, struct web_client *w) { buffer_json_member_add_string(w->response.data, "cloud_base_url", registry.cloud_base_url); buffer_json_member_add_string(w->response.data, "registry", registry.registry_to_announce); - buffer_json_member_add_boolean(w->response.data, "anonymous_statistics", netdata_anonymous_statistics_enabled); + buffer_json_member_add_boolean(w->response.data, "anonymous_statistics", do_not_track ? false : netdata_anonymous_statistics_enabled); buffer_json_member_add_boolean(w->response.data, "X-Netdata-Auth", true); buffer_json_member_add_array(w->response.data, "nodes"); diff --git a/registry/registry.h b/registry/registry.h index a572991c..746fe430 100644 --- a/registry/registry.h +++ b/registry/registry.h @@ -66,7 +66,7 @@ int registry_request_access_json(RRDHOST *host, struct web_client *w, char *pers int registry_request_delete_json(RRDHOST *host, struct web_client *w, char *person_guid, char *machine_guid, char *url, char *delete_url, time_t when); int registry_request_search_json(RRDHOST *host, struct web_client *w, char *person_guid, char *request_machine); int registry_request_switch_json(RRDHOST *host, struct web_client *w, char *person_guid, char *machine_guid, char *url, char *new_person_guid, time_t when); -int registry_request_hello_json(RRDHOST *host, struct web_client *w); +int registry_request_hello_json(RRDHOST *host, struct web_client *w, bool do_not_track); // update the registry config void registry_update_cloud_base_url(); -- cgit v1.2.3