-
Notifications
You must be signed in to change notification settings - Fork 366
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
INDY-2157: TAA acceptance use date #1256
Conversation
Signed-off-by: toktar <renata.toktar@dsr-corporation.com>
test this please |
…nto story-2157-taa-time
Signed-off-by: toktar <renata.toktar@dsr-corporation.com>
test this please |
plenum/test/txn_author_agreement/acceptance/test_taa_acceptance_validation.py
Outdated
Show resolved
Hide resolved
plenum/test/txn_author_agreement/acceptance/test_taa_acceptance_validation.py
Outdated
Show resolved
Hide resolved
Signed-off-by: toktar <renata.toktar@dsr-corporation.com>
if datetime_r_taa.time() != time(0): | ||
raise InvalidClientTaaAcceptanceError( | ||
request.identifier, request.reqId, | ||
"TAA timestamp {} is too precise and is a privacy risk." |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it would be more clear to have the following error message (to be more consistent with other error messages):
Txn Author Agreement acceptance time {} is too precise and is a privacy risk.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will be changed in #1263
max_last_accepted_pre_prepare_time + | ||
randint(0, tconf.TXN_AUTHOR_AGREEMENT_ACCEPTANCE_TIME_AFTER_PP_TIME) | ||
) | ||
pp_time = max_last_accepted_pre_prepare_time |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why did we remove adding the delta here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because it is the addition of randomness to the test as a small time shift. Now we use the date and this is impossible.
Signed-off-by: toktar renata.toktar@dsr-corporation.com