Electrum will have this option soon
It was the Bitcointalk forum that inspired us to create Bitcointalksearch.org - Bitcointalk is an excellent site that should be the default page for anybody dealing in cryptocurrency, since it is a virtual gold-mine of data. However, our experience and user feedback led us create our site; Bitcointalk's search is slow, and difficult to get the results you need, because you need to log in first to find anything useful - furthermore, there are rate limiters for their search functionality.
The aim of our project is to create a faster website that yields more results and faster without having to create an account and eliminate the need to log in - your personal data, therefore, will never be in jeopardy since we are not asking for any of your data and you don't need to provide them to use our site with all of its capabilities.
We created this website with the sole purpose of users being able to search quickly and efficiently in the field of cryptocurrency so they will have access to the latest and most accurate information and thereby assisting the crypto-community at large.
#!/usr/bin/env python
#
# calculate google authenticator codes
#
# usage:
#
# for Time-based One-time Passwords (TOTP), supply just one argument: the secret
#
# for HMAC-based One-Time Passwords (HOTP), supply two arguments: the secret, and the counter
# the counter should go up by one each time you generate a password
#
import base64, hashlib, hmac, string, struct, sys, time
def get_hotp_token(secret, number):
h = hmac.new(base64.b32decode(secret, True), struct.pack(">Q", number), hashlib.sha1).digest()
o = ord(h[19]) & 15
return (struct.unpack(">I", h[o:o+4])[0] & 0x7fffffff) % 1000000
def get_totp_token(secret):
return get_hotp_token(secret, int(time.time())//30)
def usage():
sys.stderr.write("Usage: %s[ number ]\n")
sys.exit(1)
argc = len(sys.argv)
if argc < 2 or argc > 3:
usage()
secret = sys.argv[1]
secret += '======='[:7-((len(secret)-1)%8)]
if argc < 3:
print "%06d" % (get_totp_token(secret))
else:
number = string.atoi(sys.argv[2])
print "%06d" % (get_hotp_token(secret, number))