Skip to main content

A captcha library that generates audio and image CAPTCHAs.

Project description

A captcha library that generates audio and image CAPTCHAs.

a fork of <https://github.com/lepture/captcha> with support of a lot more data

Features

  1. Audio CAPTCHAs

  2. Image CAPTCHAs

Installation

Install captcha with pip:

$ pip install captcha

Usage

Audio and Image CAPTCHAs are in separated modules:

from captcha.audio import AudioCaptcha
from captcha.image import ImageCaptcha

audio = AudioCaptcha(voicedir='/path/to/voices')
image = ImageCaptcha(fonts=['/path/A.ttf', '/path/B.ttf'])

data = audio.generate('1234')
audio.write('1234', 'out.wav')

data = image.generate('1234')
image.write('1234', 'out.png')

This is the APIs for your daily works. We do have built-in voice data and font data. But it is suggested that you use your own voice and font data.

License

Licensed under BSD. Please see LICENSE for licensing details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

more_captcha-1.0.0-py3-none-any.whl (592.0 kB view details)

Uploaded Python 3

File details

Details for the file more_captcha-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: more_captcha-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 592.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.11.8

File hashes

Hashes for more_captcha-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 8c9fd6c5b1275a22304c3f2d84740317331890468574ec0317823422bf12cf51
MD5 c8167091133dec7da0afc80e3783afb8
BLAKE2b-256 a1578765dd4ba6834853d4ccc1870e6d282322b328124efefd3d096df4185bf2

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page