Compare commits
No commits in common. "4202dc0e431cd593e5dc6cae2090bb8f9ff5470b" and "282ad8f32e595f9f601bfa23e6e36665d5c1d1c8" have entirely different histories.
4202dc0e43
...
282ad8f32e
1 changed files with 0 additions and 23 deletions
|
@ -1,23 +0,0 @@
|
|||
import socket
|
||||
import random as r
|
||||
|
||||
L=[
|
||||
"G3T / HTTP/1.1\r\nHøst: localhost\r\n\r\n",
|
||||
"GET /index.html HTTP/1.1\r\nHost: localhost\r\n\r\n",
|
||||
"GET /about.html HTTP/1.1\r\nHost: localhost\r\n\r\n"
|
||||
]
|
||||
|
||||
adresse="localhost"
|
||||
port=80
|
||||
def attaque():
|
||||
while True:
|
||||
with socket.socket(family=socket.AF_INET, type=socket.SOCK_STREAM) as s:
|
||||
s.connect(adresse,port)
|
||||
s.send(L[r.randint(0,2)].encode())
|
||||
|
||||
'''
|
||||
|
||||
GET / HTTP/1.1
|
||||
Host: example.com
|
||||
|
||||
'''
|
Loading…
Add table
Add a link
Reference in a new issue