@@ -104,7 +104,7 @@ static int xdrbg256_drng_selftest(struct lc_rng_ctx *xdrbg256_ctx)
104104 lc_hash_final (xdrbg256_compare , compare1 );
105105 unpoison (state -> v , LC_XDRBG256_DRNG_KEYSIZE );
106106 rc += lc_compare (compare1 , state -> v , LC_XDRBG256_DRNG_KEYSIZE ,
107- "SHAKE DRNG state generation" );
107+ "SHAKE DRNG state generation" );
108108
109109 /* Verify the generate operation */
110110 /* Use the already generated state from above */
@@ -135,14 +135,15 @@ static int xdrbg256_drng_selftest(struct lc_rng_ctx *xdrbg256_ctx)
135135 LC_XDRBG256_DRNG_KEYSIZE ));
136136 lc_hash_final (xdrbg256_compare , compare1 );
137137 /* Second loop iteratipn: generate data */
138- CKINT (lc_hash_set_digestsize (
139- xdrbg256_compare , sizeof (compare1 ) - LC_XDRBG256_DRNG_MAX_CHUNK -
140- LC_XDRBG256_DRNG_KEYSIZE ));
138+ CKINT (lc_hash_set_digestsize (xdrbg256_compare ,
139+ sizeof (compare1 ) -
140+ LC_XDRBG256_DRNG_MAX_CHUNK -
141+ LC_XDRBG256_DRNG_KEYSIZE ));
141142 lc_hash_final (xdrbg256_compare , compare1 + LC_XDRBG256_DRNG_MAX_CHUNK +
142143 LC_XDRBG256_DRNG_KEYSIZE );
143144
144145 rc += lc_compare (compare1 + LC_XDRBG256_DRNG_KEYSIZE , exp1 ,
145- sizeof (exp1 ), "SHAKE DRNG verification" );
146+ sizeof (exp1 ), "SHAKE DRNG verification" );
146147
147148 lc_rng_zero (xdrbg256_ctx );
148149
@@ -154,7 +155,7 @@ static int xdrbg256_drng_selftest(struct lc_rng_ctx *xdrbg256_ctx)
154155 lc_rng_seed (xdrbg256_ctx , seed , sizeof (seed ), NULL , 0 );
155156 lc_rng_generate (xdrbg256_ctx , exp1 , 83 , act2 , sizeof (act2 ));
156157 rc += lc_compare (act2 , exp83 , sizeof (act2 ),
157- "SHAKE DRNG with alpha 83 bytes" );
158+ "SHAKE DRNG with alpha 83 bytes" );
158159 lc_rng_zero (xdrbg256_ctx );
159160
160161 /*
@@ -164,7 +165,7 @@ static int xdrbg256_drng_selftest(struct lc_rng_ctx *xdrbg256_ctx)
164165 lc_rng_seed (xdrbg256_ctx , seed , sizeof (seed ), NULL , 0 );
165166 lc_rng_generate (xdrbg256_ctx , exp1 , 84 , act2 , sizeof (act2 ));
166167 rc += lc_compare (act2 , exp84 , sizeof (act2 ),
167- "SHAKE DRNG with alpha 84 bytes" );
168+ "SHAKE DRNG with alpha 84 bytes" );
168169 lc_rng_zero (xdrbg256_ctx );
169170
170171 /*
@@ -175,7 +176,7 @@ static int xdrbg256_drng_selftest(struct lc_rng_ctx *xdrbg256_ctx)
175176 lc_rng_seed (xdrbg256_ctx , seed , sizeof (seed ), NULL , 0 );
176177 lc_rng_generate (xdrbg256_ctx , exp1 , 85 , act2 , sizeof (act2 ));
177178 rc += lc_compare (act2 , exp84 , sizeof (act2 ),
178- "SHAKE DRNG with alpha 85 bytes" );
179+ "SHAKE DRNG with alpha 85 bytes" );
179180 lc_rng_zero (xdrbg256_ctx );
180181
181182 /* Verify the generate operation with additional data */
@@ -209,8 +210,8 @@ static int xdrbg256_drng_selftest(struct lc_rng_ctx *xdrbg256_ctx)
209210 LC_XDRBG256_DRNG_KEYSIZE + sizeof (act2 )));
210211 lc_hash_final (xdrbg256_compare , compare1 );
211212 rc += lc_compare (compare1 + LC_XDRBG256_DRNG_KEYSIZE , exp84 ,
212- sizeof (exp84 ),
213- "SHAKE DRNG with alpha 84 bytes verification" );
213+ sizeof (exp84 ),
214+ "SHAKE DRNG with alpha 84 bytes verification" );
214215
215216 lc_rng_zero (xdrbg256_ctx );
216217
0 commit comments