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

Optimization, IDPF: only derive the extend and convert PRG fixed keys once #511

Closed
divergentdave opened this issue Mar 11, 2023 · 2 comments · Fixed by #525
Closed

Optimization, IDPF: only derive the extend and convert PRG fixed keys once #511

divergentdave opened this issue Mar 11, 2023 · 2 comments · Fixed by #525

Comments

@divergentdave
Copy link
Contributor

Following #510, we may want to introduce a new way to construct PrgFixedKeyAes128 that separates the fixed key derivation so we can only perform it once, and then reuse it across multiple IDPF levels, with different seeds each time. We'd need to add a new factory type, and use that instead of Prg::init() to construct a new PRG with each successive seed.

@divergentdave
Copy link
Contributor Author

Poplar1 with the fixed key PRG is currently 7%-10% slower, which makes sense because we do the same amount of cSHAKE128 absorbing, cut the squeezing in about half, and add AES key derivation and encryption. We'll need to make this optimization to realize the performance benefits of fixed key AES.

@cjpatton
Copy link
Collaborator

Let's definitely do it before the next release?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants