MediaWiki
1.29.2
|
Go to the source code of this file.
Namespaces | |
captcha | |
Functions | |
def | captcha.gen_captcha (text, fontname, fontsize, file_name) |
def | captcha.gen_subdir (basedir, md5hash, levels) |
def | captcha.pick_word (words, blacklist, verbose, nwords, min_length, max_length) |
def | captcha.read_wordlist (filename) |
def | captcha.try_pick_word (words, blacklist, verbose, nwords, min_length, max_length) |
def | captcha.wobbly_copy (src, wob, col, scale, ang) |
Variables | |
captcha.action | |
captcha.args | |
def | captcha.blacklist = read_wordlist(opts.blacklist) |
captcha.count = opts.count | |
captcha.default | |
captcha.dirs = opts.dirs | |
string | captcha.filename = "image_%s_%s.png" % (salt, md5hash) |
captcha.fill = opts.fill | |
captcha.font = opts.font | |
captcha.fontsize = opts.font_size | |
captcha.help | |
captcha.key = opts.key | |
captcha.md5hash = hashlib.md5((key+salt+word+key+salt).encode('utf-8')).hexdigest()[:16] | |
captcha.metavar | |
captcha.nonalpha = re.compile('[^a-z]') | |
captcha.opts | |
captcha.output = opts.output | |
captcha.parser = OptionParser() | |
string | captcha.salt = "%08x" % random.randrange(2**32) |
captcha.script_dir = os.path.dirname(os.path.realpath(__file__)) | |
def | captcha.subdir = gen_subdir(output, md5hash, dirs) |
captcha.type | |
captcha.verbose = opts.verbose | |
def | captcha.word = pick_word(words, blacklist, verbose, opts.number_words, opts.min_length, opts.max_length) |
captcha.wordlist = opts.wordlist | |
captcha.words = None | |