MediaWiki REL1_33
captcha-old Namespace Reference

Functions

 gen_captcha (text, fontname, fontsize, file_name)
 
 gen_subdir (basedir, md5hash, levels)
 
 pick_word (words, blacklist, verbose, nwords, min_length, max_length)
 
 read_wordlist (filename)
 
 run_in_thread (object)
 
 try_pick_word (words, blacklist, verbose, nwords, min_length, max_length)
 
 wobbly_copy (src, wob, col, scale, ang)
 

Variables

 action
 
 args
 
 blacklist = read_wordlist(opts.blacklist)
 
int chunks = 1
 
 count = opts.count
 
list data = []
 
 default
 
 dirs = opts.dirs
 
 fill = opts.fill
 
 font = opts.font
 
 fontsize = opts.font_size
 
 help
 
 key = opts.key
 
 metavar
 
 nonalpha = re.compile('[^a-z]')
 
 opts
 
 output = opts.output
 
 p = multiprocessing.Pool(threads);
 
 parser = OptionParser()
 
 script_dir = os.path.dirname(os.path.realpath(__file__))
 
 threads = opts.threads
 
 type
 
 verbose = opts.verbose
 
 wordlist = opts.wordlist
 
 words = None
 

Function Documentation

◆ gen_captcha()

captcha-old.gen_captcha ( text,
fontname,
fontsize,
file_name )
Generate a captcha image

Definition at line 75 of file captcha-old.py.

References and(), and wobbly_copy().

Referenced by run_in_thread().

◆ gen_subdir()

captcha-old.gen_subdir ( basedir,
md5hash,
levels )
Generate a subdirectory path out of the first _levels_
    characters of _hash_, and ensure the directories exist
    under _basedir_.

Definition at line 113 of file captcha-old.py.

References and().

Referenced by run_in_thread().

◆ pick_word()

captcha-old.pick_word ( words,
blacklist,
verbose,
nwords,
min_length,
max_length )

Definition at line 167 of file captcha-old.py.

References and(), and try_pick_word().

Referenced by run_in_thread().

◆ read_wordlist()

captcha-old.read_wordlist ( filename)

Definition at line 174 of file captcha-old.py.

References and().

◆ run_in_thread()

captcha-old.run_in_thread ( object)

Definition at line 180 of file captcha-old.py.

References and(), gen_captcha(), gen_subdir(), pick_word(), and print.

◆ try_pick_word()

captcha-old.try_pick_word ( words,
blacklist,
verbose,
nwords,
min_length,
max_length )

Definition at line 129 of file captcha-old.py.

References and(), and print.

Referenced by pick_word().

◆ wobbly_copy()

captcha-old.wobbly_copy ( src,
wob,
col,
scale,
ang )

Definition at line 50 of file captcha-old.py.

References and().

Referenced by gen_captcha().

Variable Documentation

◆ action

captcha-old.action

Definition at line 212 of file captcha-old.py.

◆ args

captcha-old.args

Definition at line 227 of file captcha-old.py.

◆ blacklist

captcha-old.blacklist = read_wordlist(opts.blacklist)

Definition at line 248 of file captcha-old.py.

◆ chunks

captcha-old.chunks = 1

Definition at line 270 of file captcha-old.py.

◆ count

captcha-old.count = opts.count

Definition at line 249 of file captcha-old.py.

◆ data

list captcha-old.data = []

Definition at line 276 of file captcha-old.py.

◆ default

captcha-old.default

Definition at line 216 of file captcha-old.py.

◆ dirs

captcha-old.dirs = opts.dirs

Definition at line 251 of file captcha-old.py.

◆ fill

captcha-old.fill = opts.fill

Definition at line 250 of file captcha-old.py.

◆ font

captcha-old.font = opts.font

Definition at line 244 of file captcha-old.py.

◆ fontsize

captcha-old.fontsize = opts.font_size

Definition at line 253 of file captcha-old.py.

◆ help

captcha-old.help

Definition at line 211 of file captcha-old.py.

◆ key

captcha-old.key = opts.key

Definition at line 236 of file captcha-old.py.

◆ metavar

captcha-old.metavar

Definition at line 211 of file captcha-old.py.

◆ nonalpha

captcha-old.nonalpha = re.compile('[^a-z]')

Definition at line 47 of file captcha-old.py.

◆ opts

captcha-old.opts

Definition at line 227 of file captcha-old.py.

◆ output

captcha-old.output = opts.output

Definition at line 240 of file captcha-old.py.

◆ p

captcha-old.p = multiprocessing.Pool(threads);

Definition at line 275 of file captcha-old.py.

◆ parser

captcha-old.parser = OptionParser()

Definition at line 210 of file captcha-old.py.

◆ script_dir

captcha-old.script_dir = os.path.dirname(os.path.realpath(__file__))

Definition at line 209 of file captcha-old.py.

◆ threads

int captcha-old.threads = opts.threads

Definition at line 254 of file captcha-old.py.

◆ type

captcha-old.type

Definition at line 216 of file captcha-old.py.

◆ verbose

captcha-old.verbose = opts.verbose

Definition at line 252 of file captcha-old.py.

◆ wordlist

captcha-old.wordlist = opts.wordlist

Definition at line 230 of file captcha-old.py.

◆ words

list captcha-old.words = None

Definition at line 259 of file captcha-old.py.