Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Exercise 3 A toy one - time - password ( OTP ) generator Using any of your password hashing program implemented so far, implement a
Exercise A toy onetimepassword OTP generator Using any of your password hashing program implemented so far, implement a toy OTP scheme as follows: Immediately after user registration o TheserverstoresthehashedandsaltedpasswordasHSPHnpasswordsaltasusual where H is a hash function and indicates bytestring concatenation. For each login o TheserverupdatestheHSPasfollows:HSPHHSPtwheretisthecurrentdateand time in any format you decide. o TheservercalculateanOTPasthelastbytesofHSPandsenditshexadecimal representation to the user via SMS o TheuserentersthereceivedOTPtologin. o Theservercheckstheusersinputtodecideacceptorrejecttheuser In the above scheme, you dont need to implement the real SMS feature, but just assume the user get the OTP and write a script to demonstrate that if the right OTP is given the user will be accepted; otherwise she will be rejected.
Exercise A toy onetimepassword OTP generator
Using any of your password hashing program implemented so far, implement a toy OTP scheme as follows: Immediately after user registration
o TheserverstoresthehashedandsaltedpasswordasHSPHnpasswordsaltasusual where H is a hash function and indicates bytestring concatenation.
For each login
o TheserverupdatestheHSPasfollows:HSPHHSPtwheretisthecurrentdateand
time in any format you decide.
o TheservercalculateanOTPasthelastbytesofHSPandsenditshexadecimal
representation to the user via SMS
o TheuserentersthereceivedOTPtologin.
o Theservercheckstheusersinputtodecideacceptorrejecttheuser
In the above scheme, you dont need to implement the real SMS feature, but just assume the user get the OTP and write a script to demonstrate that if the right OTP is given the user will be accepted; otherwise she will be rejected.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access with AI-Powered Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started