From e41487f80c7bee8339e753014eca14743551bcbd Mon Sep 17 00:00:00 2001 From: 0Gitnick <36289298+0Gitnick@users.noreply.github.com> Date: Tue, 26 Nov 2019 18:19:28 -0600 Subject: [PATCH] Simplify replay_timestamp_validation --- src/onionrcrypto/cryptoutils/replayvalidation.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/onionrcrypto/cryptoutils/replayvalidation.py b/src/onionrcrypto/cryptoutils/replayvalidation.py index 59c338eb..fc8e8fd0 100644 --- a/src/onionrcrypto/cryptoutils/replayvalidation.py +++ b/src/onionrcrypto/cryptoutils/replayvalidation.py @@ -1,6 +1,3 @@ from onionrutils import epoch def replay_timestamp_validation(timestamp): - if epoch.get_epoch() - int(timestamp) > 2419200: - return False - else: - return True \ No newline at end of file + return epoch.get_epoch() - int(timestamp) <= 2419200 \ No newline at end of file