Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- stream = client.makefile('w+') # Create file object from socket
- stream.write("HELO\n")
- data = sys.stdin.readline()
- filesize = os.stat('final.py')
- sys.stdout.write(data)
- stream.write("PUT plee4 {}\n".format(filesize.st_size))
- stream.flush()
- fd = os.open('script.py',OS_RDWRONLY)
- f=os.read(fd,1024)
- stream.write(f)
- stream.flush()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement