Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make server ciphersuite-blind #177

Open
conradoplg opened this issue Mar 22, 2024 · 0 comments · May be fixed by #223
Open

Make server ciphersuite-blind #177

conradoplg opened this issue Mar 22, 2024 · 0 comments · May be fixed by #223
Assignees

Comments

@conradoplg
Copy link
Contributor

Problem: the server needs to know the ciphersuite and only works with one. This is because the Args/Output structs have FROST structs in them, which are (de)serialized as needed. This requires specifying a ciphersuite.

Solution: the server doesn't need to do the serialization roundtrip. It can receive FROST structs serialized and just pass them around.

Coding approach suggestion:

  • Change the FROST structs in server/src/types.go to use Vec<u8> instead, e.g. pub commitments: Vec<frost::round1::SigningCommitments> becomes pub commitments: Vec<Vec<u8>>.
    • By default serde encodes these Vec<u8> as integer arrays which is awkward. It's possible to encode them as hex strings (in human-readable formats like JSON) or directly binary. Check how we do that in SigningFormat::message field in frost-core for a reference on how to do that with serde(serialize_with).
    • For type safety it's possible to use newtypes for each struct, e.g. define a EncodedSigningCommitments(Vec<u8>) and use that instead.
@conradoplg conradoplg linked a pull request May 17, 2024 that will close this issue
@conradoplg conradoplg self-assigned this May 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Review/QA
Development

Successfully merging a pull request may close this issue.

1 participant