diff options
author | Neel Chauhan <neel@neelc.org> | 2019-01-14 14:09:53 -0500 |
---|---|---|
committer | Neel Chauhan <neel@neelc.org> | 2019-01-24 10:22:41 -0500 |
commit | c985940de9ec743cbb3e9a3e32fd482bd859c9ed (patch) | |
tree | ada77d45ae70210a34c9761b36bd5e539dd2a2f9 /src/feature/hs/hs_control.c | |
parent | cef910642efb1f9a2db16146eb8a191327b51310 (diff) | |
download | tor-c985940de9ec743cbb3e9a3e32fd482bd859c9ed.tar.gz tor-c985940de9ec743cbb3e9a3e32fd482bd859c9ed.zip |
Add version 3 onion service support to HSFETCH
Diffstat (limited to 'src/feature/hs/hs_control.c')
-rw-r--r-- | src/feature/hs/hs_control.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/feature/hs/hs_control.c b/src/feature/hs/hs_control.c index a21788ecd7..df8c1958b5 100644 --- a/src/feature/hs/hs_control.c +++ b/src/feature/hs/hs_control.c @@ -10,6 +10,7 @@ #include "feature/control/control.h" #include "lib/crypt_ops/crypto_format.h" #include "lib/crypt_ops/crypto_util.h" +#include "feature/hs/hs_client.h" #include "feature/hs/hs_common.h" #include "feature/hs/hs_control.h" #include "feature/hs/hs_descriptor.h" @@ -259,3 +260,16 @@ hs_control_hspost_command(const char *body, const char *onion_address, smartlist_free(hsdirs); return ret; } + +/* With a given <b>onion_identity_pk</b>, fetch its descriptor, optionally + * using the list of directory servers given in <b>hsdirs</b>, or a random + * server if it is NULL. This function calls hs_client_launch_v3_desc_fetch(). + */ +void +hs_control_hsfetch_command(const ed25519_public_key_t *onion_identity_pk, + const smartlist_t *hsdirs) +{ + tor_assert(onion_identity_pk); + + hs_client_launch_v3_desc_fetch(onion_identity_pk, hsdirs); +} |