return False;
}
-static bool_t generate_msg1(struct site *st, const struct msg *prompt_maybe_0)
+static void kex_init(struct site *st)
{
st->random->generate(st->random->st,NONCELEN,st->localN);
+}
+
+static bool_t generate_msg1(struct site *st, const struct msg *prompt_maybe_0)
+{
+ kex_init(st);
return generate_msg(st,LABEL_MSG1,"site:MSG1",prompt_maybe_0);
}
static bool_t generate_msg2(struct site *st,
const struct msg *prompt_may_be_null)
{
- st->random->generate(st->random->st,NONCELEN,st->localN);
+ kex_init(st);
return generate_msg(st,LABEL_MSG2,"site:MSG2",prompt_may_be_null);
}