Captcha and TcaptchaSession

class qqqr.up.captcha.Captcha(client, appid, xlogin_url, fake_ip=None)
property base64_ua

The base64_ua function encodes the User-Agent header in base64.

返回:

A string containing the base64 encoded user agent

async new(sid)

prehandle. Call this method to generate a new verify session.

参数:

sid (str) – login session id, got from UpWebLogin.new()

返回类型:

BaseTcaptchaSession

返回:

a tcaptcha session

async prehandle(sid)

alias of new()

返回类型:

BaseTcaptchaSession

async verify(sid, *, loop=None)
抛出:

NotImplementedError – cannot solve captcha

qqqr.up.captcha.TcaptchaSession

BaseTcaptchaSession 的别名