Python内建模块编程(1)
发布时间
阅读量:
阅读量
设置IIS服务器

2.在客户端完成SSL协议的安装配置后,即可实现对Web服务器的安全访问。
#!/usr/bin/env python
import socket, sys
def sendall(s, buf):
byteswritten = 0
while byteswritten < len(buf):
byteswritten += s.write(buf[byteswritten:])
print "Creating socket...",
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
print "done."
print "Connecting to remote host...",
s.connect(("127.0.0.1", 443))
print "done."
全部评论 (0)
还没有任何评论哟~
