diff options
author | rl1987 <rl1987@sdf.lonestar.org> | 2014-11-16 15:51:23 +0200 |
---|---|---|
committer | rl1987 <rl1987@sdf.lonestar.org> | 2014-11-16 15:51:23 +0200 |
commit | 0db96d023b9a927d55c18c06f57b6cc0a9bd34de (patch) | |
tree | 0c59e6434effd60f72fb148d8d64689004f53b9e /src/test/test_hs.c | |
parent | ab08d8c4f7a4a6120756e964a086219a1dc3aaa2 (diff) | |
download | tor-0db96d023b9a927d55c18c06f57b6cc0a9bd34de.tar.gz tor-0db96d023b9a927d55c18c06f57b6cc0a9bd34de.zip |
Adding REASON field to HS_DESC FAILED controller event.
Diffstat (limited to 'src/test/test_hs.c')
-rw-r--r-- | src/test/test_hs.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/test/test_hs.c b/src/test/test_hs.c index 2db88a4c0c..a5cd841a55 100644 --- a/src/test/test_hs.c +++ b/src/test/test_hs.c @@ -99,18 +99,20 @@ test_hs_desc_event(void *arg) /* test failed event */ rend_query.auth_type = 2; - control_event_hs_descriptor_failed(&rend_query, HSDIR_NONE_EXIST_ID); + control_event_hs_descriptor_failed(&rend_query, HSDIR_NONE_EXIST_ID, + "QUERY_REJECTED"); expected_msg = "650 HS_DESC FAILED "STR_HS_ADDR" STEALTH_AUTH "\ - STR_HSDIR_NONE_EXIST_LONGNAME"\r\n"; + STR_HSDIR_NONE_EXIST_LONGNAME" REASON=QUERY_REJECTED\r\n"; tt_assert(received_msg); tt_str_op(received_msg,OP_EQ, expected_msg); tor_free(received_msg); /* test invalid auth type */ rend_query.auth_type = 999; - control_event_hs_descriptor_failed(&rend_query, HSDIR_EXIST_ID); + control_event_hs_descriptor_failed(&rend_query, HSDIR_EXIST_ID, + "QUERY_REJECTED"); expected_msg = "650 HS_DESC FAILED "STR_HS_ADDR" UNKNOWN "\ - STR_HSDIR_EXIST_LONGNAME"\r\n"; + STR_HSDIR_EXIST_LONGNAME" REASON=QUERY_REJECTED\r\n"; tt_assert(received_msg); tt_str_op(received_msg,OP_EQ, expected_msg); tor_free(received_msg); |