req = urllib2.Request('https://passport.baidu.com/v2/api/?logincheck&tpl=mn&charset=UTF-8&index=0&username=%s&time=%s' % (self.username, timestamp()))
data = self._opener.open(req).read().strip()[1:-1] # remove brackets
===>this returns:
{"errno":0,"codestring":null,"index":"0"}
therefore, we cannot get correct verify code pic.
req = urllib2.Request('https://passport.baidu.com/v2/api/?logincheck&tpl=mn&charset=UTF-8&index=0&username=%s&time=%s' % (self.username, timestamp()))
data = self._opener.open(req).read().strip()[1:-1] # remove brackets
===>this returns:
{"errno":0,"codestring":null,"index":"0"}
therefore, we cannot get correct verify code pic.