From 6e37086f85aa3e421ebc6f4d64de1cd82bcdeaa6 Mon Sep 17 00:00:00 2001 From: Neel Chauhan Date: Thu, 6 Aug 2020 22:32:30 -0700 Subject: v3 control: Persist ONION_CLIENT_AUTH_ADD client name --- src/feature/hs/hs_client.c | 2 ++ src/feature/hs/hs_client.h | 3 +++ 2 files changed, 5 insertions(+) (limited to 'src/feature/hs') diff --git a/src/feature/hs/hs_client.c b/src/feature/hs/hs_client.c index d9c5d8ca1d..fc1fd76efc 100644 --- a/src/feature/hs/hs_client.c +++ b/src/feature/hs/hs_client.c @@ -2168,6 +2168,8 @@ client_service_authorization_free_(hs_client_service_authorization_t *auth) return; } + tor_free(auth->client_name); + memwipe(auth, 0, sizeof(*auth)); tor_free(auth); } diff --git a/src/feature/hs/hs_client.h b/src/feature/hs/hs_client.h index a11caa309f..88dede8126 100644 --- a/src/feature/hs/hs_client.h +++ b/src/feature/hs/hs_client.h @@ -71,6 +71,9 @@ typedef struct hs_client_service_authorization_t { /** An onion address that is used to connect to the onion service. */ char onion_address[HS_SERVICE_ADDR_LEN_BASE32+1]; + /** An client name used to connect to the onion service. */ + char *client_name; + /* Optional flags for this client. */ int flags; } hs_client_service_authorization_t; -- cgit v1.2.3-54-g00ecf