diff options
author | Elias Summermatter <elias.summermatter@seccom.ch> | 2021-03-31 11:17:24 +0200 |
---|---|---|
committer | Elias Summermatter <elias.summermatter@seccom.ch> | 2021-03-31 11:17:24 +0200 |
commit | 26d2c0d58612fb233cc25b2739bcf96693f5cd85 (patch) | |
tree | 16baec844f4a5d9b5383d91589fe4c8f74eec725 /src/revocation/plugin_block_revocation.c | |
parent | b5660e0a33f4c7a819de0b5056172f78f912e352 (diff) | |
parent | ca4c9eae269c34765df26699fe756860c7827693 (diff) | |
download | gnunet-26d2c0d58612fb233cc25b2739bcf96693f5cd85.tar.gz gnunet-26d2c0d58612fb233cc25b2739bcf96693f5cd85.zip |
Merge branch 'master' of ssh://gnunet.org/gnunet
Diffstat (limited to 'src/revocation/plugin_block_revocation.c')
-rw-r--r-- | src/revocation/plugin_block_revocation.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/revocation/plugin_block_revocation.c b/src/revocation/plugin_block_revocation.c index 3c9344a49..1928d09cd 100644 --- a/src/revocation/plugin_block_revocation.c +++ b/src/revocation/plugin_block_revocation.c | |||
@@ -134,6 +134,7 @@ block_plugin_revocation_evaluate (void *cls, | |||
134 | { | 134 | { |
135 | struct InternalContext *ic = cls; | 135 | struct InternalContext *ic = cls; |
136 | struct GNUNET_HashCode chash; | 136 | struct GNUNET_HashCode chash; |
137 | ssize_t pklen; | ||
137 | const struct RevokeMessage *rm = reply_block; | 138 | const struct RevokeMessage *rm = reply_block; |
138 | 139 | ||
139 | if (NULL == reply_block) | 140 | if (NULL == reply_block) |
@@ -153,8 +154,14 @@ block_plugin_revocation_evaluate (void *cls, | |||
153 | GNUNET_break_op (0); | 154 | GNUNET_break_op (0); |
154 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | 155 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; |
155 | } | 156 | } |
157 | pklen = GNUNET_IDENTITY_key_get_length (pk); | ||
158 | if (0 > pklen) | ||
159 | { | ||
160 | GNUNET_break_op (0); | ||
161 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
162 | } | ||
156 | GNUNET_CRYPTO_hash (pk, | 163 | GNUNET_CRYPTO_hash (pk, |
157 | GNUNET_IDENTITY_key_get_length (pk), | 164 | pklen, |
158 | &chash); | 165 | &chash); |
159 | if (GNUNET_YES == | 166 | if (GNUNET_YES == |
160 | GNUNET_BLOCK_GROUP_bf_test_and_set (group, | 167 | GNUNET_BLOCK_GROUP_bf_test_and_set (group, |