-
Notifications
You must be signed in to change notification settings - Fork 31
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
Comparing Vdaf::PrepareState
in constant time
#722
Comments
I think we don't actually need Other than test uses, we currently use the
|
Oof, the report share doesn't actually store the incoming input share (it only gets recorded to the report aggregations). So idempotency-checking aggregation jobs can't use the report shares. However: checking the |
I noticed the preexisting Since |
We already depend on the |
Users of
prio
need to compare various objects related to VDAFs such asVdaf::PrepareState
to one another. For example, to check whether a given state transition occurred as expected in a test, or to check whether a database row already contains some incoming value.In test settings, it's probably fine to use derived
PartialEq + Eq
implementations which will boil down to comparing slices of bytes. But in other contexts, we need to make sure that comparisons are done in constant time.We could address this by auditing the
PartialEq
implementations on each VDAF implementation's associated types, replacing them with hand-written, constant time verisons as needed. But the risk there is that new VDAFs will use derivedPartialEq
implementations that aren't constant time. So perhaps we would want to remove allPartialEq + Eq
trait bounds and instead define some customConstantTimeEq
trait.Originally posted by @cjpatton in #683 (comment)
The text was updated successfully, but these errors were encountered: