jiangts / JS-OTP

100% Javascript Implementation of HOTP and TOTP for Two-Factor Authentication.
https://jiangts.github.io/JS-OTP
MIT License
256 stars 70 forks source link

Update jsOTP.js #4

Closed chudel closed 6 years ago

chudel commented 6 years ago

escape() does not handle UTF-8 encoding properly, resulting in some counter values (i.e.: 128) not working. Change deprecated escape function to encodeURIComponent();

chudel commented 6 years ago

Need to cancel this pull request - while the code functions (no longer errors), the hotp is not generating proper values for counter values >= 128.