Created
March 17, 2014 21:39
-
-
Save bagvendt/9608948 to your computer and use it in GitHub Desktop.
Never gonna give you up
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
from bs4 import BeautifulSoup as soup | |
import requests | |
rick_luv = "We're no strangers to love You know the rules and so do I A full commitment's what I'm thinking of You wouldn't get this from any other guy I just wanna tell you how I'm feeling Gotta make you understand, Never gonna give you up, Never gonna let you down Never gonna run around and desert you Never gonna make you cry, Never gonna say goodbye Never gonna tell a lie and hurt you" | |
rick_luv = rick_luv.replace("'", "") | |
rick_luv = rick_luv.replace(",", "") | |
create_url_get = "http://192.237.216.119/users/create" | |
create_url_post = "http://192.237.216.119/users/store" | |
get = requests.get(create_url_get) | |
get_soup = soup(get.text) | |
token = get_soup.findAll('input', {'name':'_token'})[0]['value'] | |
laravel_session = get.cookies['laravel_session'] | |
cookies = {"laravel_session": laravel_session} | |
password = "123456" | |
for word in rick_luv.split(): | |
payload = {'_token': token, 'username': word, "password": password} | |
r = requests.post(create_url_post, data=payload, cookies=cookies) | |
print word |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment