[keyserver] implement function to get account prekey and prekey signature
Summary:
Issue: ENG-3944.
This is part of D8476 (breaking this for smaller diffs because it's complex).
Extracting code to separate function, will be used later in the stack so this reduces code duplication.
Depends on D9419
Test Plan: Flow, this only moves some code around.
Reviewers: varun, marcin, ashoat
Reviewed By: marcin, ashoat
Subscribers: tomek, wyilio
Differential Revision: https://phab.comm.dev/D9420