cookielib.CookieJar(),自动进行cookie管理:实例:cj = cookielib.Cookiejar()urlopen('...')for index, cookie in enumerate(cj):print '[',index, ']',cookie