PowerShell-Misc icon indicating copy to clipboard operation
PowerShell-Misc copied to clipboard

GoogleAuthenticator.psm1 generates wrong pin if secret >16 symbols

Open hdsouza opened this issue 2 years ago • 0 comments

Hi, I was unsure if the earlier ticket could be reopened. So I created a new one I am having the same issue... GoogleAuthenticator.psm1 generates wrong pin if secret >16 symbols Here is a code for example "MNXF22LJKB2DENSRFI3SK43JKJFFU6ZDMR2EILC3OJJG4URQIYVA"

If I pass it through the Google authenticator app (Or even the Microsoft authenticator app) I get the same pin. But when I pass it through Get-GoogleAuthenticatorPin -Secret "MNXF22LJKB2DENSRFI3SK43JKJFFU6ZDMR2EILC3OJJG4URQIYVA" ... It generates a different pin.

To add the code to Google Authenticator app I did a copy-paste. Tried on Apple Iphone.

If it helps I was able to use the Python script and associated modules on https://pyauth.github.io/pyotp/ and it was able to generate the correct code.

hdsouza avatar Mar 16 '23 17:03 hdsouza