diff options
author | Suphanat Chunhapanya <haxx.pop@gmail.com> | 2018-08-18 21:24:26 +0700 |
---|---|---|
committer | David Goulet <dgoulet@torproject.org> | 2018-09-07 13:59:22 -0400 |
commit | 15af47ede07a858bfa0871befa6e1fe76cdd372d (patch) | |
tree | d93dd475acda8450dfe8f02503ede4de36ce18b2 /src/feature/hs | |
parent | b894b40e647b4839f33f3a57704cafe9e644230c (diff) | |
download | tor-15af47ede07a858bfa0871befa6e1fe76cdd372d.tar.gz tor-15af47ede07a858bfa0871befa6e1fe76cdd372d.zip |
test: HS v3 loading client auth keys service side
Signed-off-by: David Goulet <dgoulet@torproject.org>
Diffstat (limited to 'src/feature/hs')
-rw-r--r-- | src/feature/hs/hs_service.c | 4 | ||||
-rw-r--r-- | src/feature/hs/hs_service.h | 3 |
2 files changed, 5 insertions, 2 deletions
diff --git a/src/feature/hs/hs_service.c b/src/feature/hs/hs_service.c index d61b2809b4..8d1ee82abf 100644 --- a/src/feature/hs/hs_service.c +++ b/src/feature/hs/hs_service.c @@ -1091,7 +1091,7 @@ load_service_keys(hs_service_t *service) /* Check if the client file name is valid or not. Return 1 if valid, * otherwise return 0. */ -static int +STATIC int client_filename_is_valid(const char *filename) { int ret = 1; @@ -1120,7 +1120,7 @@ client_filename_is_valid(const char *filename) * The <key-type> can only be "x25519". * * Return the key on success, return NULL, otherwise. */ -static hs_service_authorized_client_t * +STATIC hs_service_authorized_client_t * parse_authorized_client(const char *client_key_str) { char *auth_type = NULL; diff --git a/src/feature/hs/hs_service.h b/src/feature/hs/hs_service.h index c64eb7763c..cab9b41bc0 100644 --- a/src/feature/hs/hs_service.h +++ b/src/feature/hs/hs_service.h @@ -349,6 +349,9 @@ STATIC hs_service_descriptor_t *service_desc_find_by_intro( const hs_service_t *service, const hs_service_intro_point_t *ip); /* Helper functions. */ +STATIC int client_filename_is_valid(const char *filename); +STATIC hs_service_authorized_client_t * +parse_authorized_client(const char *client_key_str); STATIC void get_objects_from_ident(const hs_ident_circuit_t *ident, hs_service_t **service, hs_service_intro_point_t **ip, |