12 2017 档案
摘要:1 FTP - File Transfer Protocol 2 FTP 实际上使用了两个 TCP 链接. 一个作为控制信道用, 主要传输一些指令和响应, 3 比如 ACK 或 错误码. 另一个链接是数据信道, 用来传输文件和一些诸如目录列表的 4 信息等. 5 6 from ftplib import FTP, all_errors 7 ...
阅读全文
摘要:1 POP and IMAP - Post Office Protocol and Internet Message Access Protocol 2 3 用来从 SMTP Server 上下载邮件的协议. 4 5 POP - The Post Office Protocol 6 通过 poplib 链接服务器, 7 例子, 8 ...
阅读全文
摘要:Email via Python 1 MIME - Multipurpose Internet Mail Extensions 2 SMTP - Simple Message Transport Protocol 3 4 邮件的发送, 5 例子 - send email 6 import smtplib 7 from em...
阅读全文
摘要:1 Html / XHtml 解析 - Parsing Html and XHtml 2 3 HTMLParser 模块 4 通过 HTMLParser 模块来解析 html 文件通常的做法是, 建立一个 HTMLParser 子类, 5 然后子类中实现处理的标签()的方法, 其实现是通过 '重写' 父类(HTMLParser)的 6 handl...
阅读全文
摘要:1 urllib 模块 - urllib module 2 3 获取 web 页面, 4 html = urllib.request.urlopen("http://www.zzyzz.top/") 5 html2 = urllib.request.Request("http://www.zzyzz.top/") 6 print("html",h...
阅读全文
摘要:1 Python 高级网络操作 - Python Advanced Network Operations 2 3 Half Open Socket, 4 一个单向的 socket 被称为 half open socket, 即数据只能在一个方向上传输. 5 Half Open Socket 是通过在 socket 对象上调用 shutdown() 方法得到....
阅读全文
摘要:1 DNS 查询 - Domain Name Server 2 socket.getaddrinfo("www.baidu.com",None) 3 返回时一个 tuple list - (family, sockettype, protocol, canonname, socketaddr) 4 list 的没一个 tuple 元素是一个对应该 ...
阅读全文
摘要:1 Python socket 基础 Server - Foundations of Python Socket 2 3 通过 python socket 模块建立一个提供 TCP 链接服务的 server 可分为 4 个步骤, 4 1, 建立 socket 对象 5 s = socket.socket(socket.AF_INET, socket.SOCK_...
阅读全文
摘要:1 Python socket 基础- Foundations of Python Socket 2 3 建立socket - establish socket 4 import socket 5 s = socket.socket(socket.AF_INET,socket.SOCK_STREAM) 6 # s = 通信类型(type)...
阅读全文
摘要:Document Object Model
阅读全文
摘要:Software Testing Concepts
阅读全文

浙公网安备 33010602011771号