Get the code of conduct and JWT signing key without hitting the database from the main thread.

This commit is contained in:
2024-06-10 16:37:12 -04:00
parent c259defab5
commit 3fff706848
2 changed files with 36 additions and 43 deletions

View File

@ -1087,6 +1087,8 @@ bool tf_ssb_db_identity_create(tf_ssb_t* ssb, const char* user, uint8_t* out_pub
if (out_private_key)
{
tf_ssb_id_str_to_bin(out_private_key, private);
/* HACK: tf_ssb_id_str_to_bin only produces 32 bytes even though the full private key is 32 + 32. */
tf_ssb_id_str_to_bin(out_private_key + crypto_sign_PUBLICKEYBYTES, public);
}
return true;
}