Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/python
- # myscript
- import time
- import random
- from splinter import Browser
- import sys
- class DevNull:
- def write(self,msg):
- pass
- sys.stderr = DevNull()
- email = str(random.randrange(10000000,99999999))+'@yahoo.com'
- zip_code = random.randrange(10000,99999)
- url = 'http://captive.apple.com'
- browser = Browser('firefox')
- browser.visit(url)
- time.sleep(1)
- browser.find_by_text('I am not an XFINITY customer').first.click()
- time.sleep(1)
- browser.click_link_by_partial_href('https://xfinity.nnu.com/xfinitywifi/')
- time.sleep(1)
- browser.select("rateplanid","spn")
- browser.fill('spn_postal',zip_code)
- browser.fill('spn_email',email)
- sys.stderr = DevNull()
- email = str(random.randrange(10000000,99999999))+'@yahoo.com'
- zip_code = random.randrange(10000,99999)
- url = 'http://captive.apple.com'
- browser = Browser('firefox')
- browser.visit(url)
- time.sleep(1)
- browser.find_by_text('I am not an XFINITY customer').first.click()
- time.sleep(1)
- browser.click_link_by_partial_href('https://xfinity.nnu.com/xfinitywifi/')
- time.sleep(1)
- browser.select("rateplanid","spn")
- browser.fill('spn_postal',zip_code)
- browser.fill('spn_email',email)
- browser.check('spn_terms')
- time.sleep(1)
- browser.find_by_value('submit').first.click()
- time.sleep(10)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement