the TAP IP was the same as the microtcp instance, which wasn't right. Now the TAP is at 10.0.0.5 and the TCP at 10.0.0.4; fixed some bugs in the TCP state machine and made it so it always ACKs; fixed TCP checksum calculation
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
|
||||
from http.server import BaseHTTPRequestHandler, HTTPServer
|
||||
|
||||
class RequestHandler(BaseHTTPRequestHandler):
|
||||
|
||||
def do_GET(self):
|
||||
self.send_response(200)
|
||||
self.send_header('Content-type','text/html')
|
||||
self.end_headers()
|
||||
message = "Hello world!"
|
||||
self.wfile.write(bytes(message, "utf8"))
|
||||
return
|
||||
|
||||
addr = ('127.0.0.1', 8080)
|
||||
HTTPServer(addr, RequestHandler).serve_forever()
|
||||
Reference in New Issue
Block a user