Created
April 13, 2023 14:41
-
-
Save fyx99/bc66edc590398d73f73a6725846514fe to your computer and use it in GitHub Desktop.
Python TCP Client
This file contains 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
import socket | |
host = "localhost" | |
port = 4444 | |
client = socket.socket(socket.AF_INET, socket.SOCK_STREAM) | |
client.connect((host,port)) | |
client.send(b"") | |
response = client.recv(4096) | |
print(response) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment