Skip to content
Snippets Groups Projects
Commit 75bcdf46 authored by jkerdreu's avatar jkerdreu
Browse files

Added info about too old msg

git-svn-id: https://redmine.imt-atlantique.fr/svn/xaal/code/Python/trunk@1980 b32b6428-25c9-4566-ad07-03861ab6144f
parent 965d61e6
No related branches found
No related tags found
No related merge requests found
......@@ -106,10 +106,10 @@ class MessageFactory(object):
now = build_timestamp()[0] # test done only on seconds ...
if msg_time < (now - config.cipher_window):
raise MessageParserError("Potential replay attack, message too old")
raise MessageParserError("Potential replay attack, message too old: %d sec" % round(now - msg_time) )
if msg_time > (now + config.cipher_window):
raise MessageParserError("Potential replay attack, message too young")
raise MessageParserError("Potential replay attack, message too young: %d sec" % round(now - msg_time))
# Payload De-Ciphering
ad = data_rx['targets'].encode("utf8") # Additional Data
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment