Open RaghavRao opened 2 years ago
pkp.py.txt Hi! Sorry on mobile so can't make a proper pull request. I use KP a lot for TOTP instead of Google Authenticator here's my proof of concept for TOTP support for the show command:
import pyotp
And in the show command:
print_field( "TOTP Seed", entry.get_custom_property("TOTP Seed"), skip_empty=skip_empty, color=color ) print_field( "TOTP Settings", entry.get_custom_property("TOTP Settings"), skip_empty=skip_empty, color=color ) if entry.get_custom_property("TOTP Seed") and entry.get_custom_property("TOTP Settings") == "30;6": print_field( "TOTP", pyotp.TOTP(entry.get_custom_property("TOTP Seed")).now(), skip_empty=skip_empty, color=color )
It works with show vs show -a as intended and also mirrors the KeePassXC behavior (only show TOTP field if Seed and Settings are populated)
show
show -a
Nonstandard TOTP Settings aren't handled with this
Thanks for making a usable (and readable!) CLI, it makes termux much more usable as my launcher
Mind opening a propper PR? :angel:
pkp.py.txt Hi! Sorry on mobile so can't make a proper pull request. I use KP a lot for TOTP instead of Google Authenticator here's my proof of concept for TOTP support for the show command:
import pyotp
And in the show command:
It works with
show
vsshow -a
as intended and also mirrors the KeePassXC behavior (only show TOTP field if Seed and Settings are populated)Nonstandard TOTP Settings aren't handled with this
Thanks for making a usable (and readable!) CLI, it makes termux much more usable as my launcher