Cатсн²² (in)sесuяitу / ChrisJohnRiley

Because we're damned if we do, and we're damned if we don't!

[PoC] scr.im.tessercap (CAPTCHA OCR)

This is a simple PoC script for using the Python-Tesseract Python library for the purpose of CAPTCHA breaking.

The script is adapted from a version by Andreas Riancho on the bonsai-sec.com blog. It has been altered to use the Python-Tesseract module instead of the pytesser version he originally used. It has also been tuned a little to prepare CAPTCHA images from the scr.im service.

Example of image preparation:

Example code for tesseract-ocr:

from tesseract import image_to_string
image = Image.open('input.tif')
print image_to_string(image)


  • [PoC] scr.im.tesseract.py script –> here
  • Python OCR… or how to break CAPTCHAs –> here
  • Breaking Weak CAPTCHA in 26 Lines of Code –> bonsai-sec.com
  • Pytesser –> here
  • Tesseract-OCR –> here
  • Python-Tesseract –> here

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: