"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "linotpd/src/linotp/tokens/emailtoken.py" between
LinOTP-release-2.11.1.tar.gz and LinOTP-release-2.11.2.tar.gz

About: LinOTP is a flexible and versatile OTP-platform for strong user authentication (two-factor authentication with one time passwords).

emailtoken.py  (LinOTP-release-2.11.1):emailtoken.py  (LinOTP-release-2.11.2)
skipping to change at line 313 skipping to change at line 313
success = True success = True
transactionid_to_use = transactionid transactionid_to_use = transactionid
message = 'challenge init ok' message = 'challenge init ok'
attributes = {} attributes = {}
now = datetime.datetime.now() now = datetime.datetime.now()
blocking_time = int(getFromConfig('EmailBlockingTimeout', blocking_time = int(getFromConfig('EmailBlockingTimeout',
self.DEFAULT_EMAIL_BLOCKING_TIMEOUT)) self.DEFAULT_EMAIL_BLOCKING_TIMEOUT))
for challenge in challenges: for challenge in challenges:
# only care about open challenges
if not challenge.is_open():
continue
challenge_timestamp = challenge.get('timestamp') challenge_timestamp = challenge.get('timestamp')
block_timeout = challenge_timestamp + \ block_timeout = challenge_timestamp + \
datetime.timedelta(seconds=blocking_time) datetime.timedelta(seconds=blocking_time)
# check if there is a challenge that is blocking # check if there is a challenge that is blocking
# the creation of new challenges # the creation of new challenges
if now <= block_timeout: if now <= block_timeout:
transactionid_to_use = challenge.getTransactionId() transactionid_to_use = challenge.getTransactionId()
message = 'e-mail with otp already submitted' message = 'e-mail with otp already submitted'
success = False success = False
attributes = {'info': 'challenge already submitted', attributes = {'info': 'challenge already submitted',
 End of changes. 1 change blocks. 
0 lines changed or deleted 5 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)