https://en.wikipedia.org/wiki/Time-based_one-time_password
edit: here's a cli tool for doing this: https://www.nongnu.org/oath-toolkit/oathtool.1.html
https://github.com/arcanericky/totp