Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

无法登陆 #43

Open
smartwsw opened this issue Sep 29, 2015 · 24 comments
Open

无法登陆 #43

smartwsw opened this issue Sep 29, 2015 · 24 comments

Comments

@smartwsw
Copy link

登陆会报错10003
好像是因为腾讯把smartqq改成了只能二维码登陆

@violarulan
Copy link

+10086

@floatinghotpot
Copy link
Contributor

这是个很好的项目,如果废弃实在可惜了。昨天我加上了二维码扫描认证登录的功能,已经向原作者提交PR,不知道他能否看到。

除此之外,我还增加了一些其它的小功能,想先睹为快的,可以来看看我的版本:https://github.com/floatinghotpot/qqbot

或者直接安装使用:

$ [sudo] npm install -g smartqq-bot
$ qqbot

@xros
Copy link

xros commented Nov 3, 2015

@floatinghotpot I have gotten this error after that I installed smartqq-bot on my PC.

Then I did
node main.js

/home/alex/joy/npm_proj/node_modules/smartqq-bot/src/qqauth-qrcode.js:305
check_sig_get_cookies,
^
SyntaxError: Unexpected token ,
at exports.runInThisContext (vm.js:73:16)
at Module._compile (module.js:443:25)
at Object.Module._extensions..js (module.js:478:10)
at Module.load (module.js:355:32)
at Function.Module._load (module.js:310:12)
at Module.require (module.js:365:17)
at require (module.js:384:17)
at Object. (/home/alex/joy/npm_proj/node_modules/smartqq-bot/main.js:7:14)
at Object. (/home/alex/joy/npm_proj/node_modules/smartqq-bot/main.js:67:4)
at Module._compile (module.js:460:26)

Do you know how to fix this? Thanks!

@floatinghotpot
Copy link
Contributor

sorry, it's a bug of typo error. should be check_sig_get_cookies: check_sig_get_cookies,

i've fixed it, please update to v1.6.1

$ [sudo] npm install smartqq-bot

@xros
Copy link

xros commented Nov 3, 2015

@floatinghotpot thanks for the patching. But I still got another error

/home/alex/joy/npm_proj/node_modules/smartqq-bot/src/defaults.js:8
var path = Path.join(os.homedir(), '.tmp', 'store.json');
^
TypeError: undefined is not a function
at Object. (/home/alex/joy/npm_proj/node_modules/smartqq-bot/src/defaults.js:8:27)
at Object. (/home/alex/joy/npm_proj/node_modules/smartqq-bot/src/defaults.js:48:4)
at Module._compile (module.js:460:26)
at Object.Module._extensions..js (module.js:478:10)
at Module.load (module.js:355:32)
at Function.Module._load (module.js:310:12)
at Module.require (module.js:365:17)
at require (module.js:384:17)
at Object. (/home/alex/joy/npm_proj/node_modules/smartqq-bot/main.js:10:18)
at Object. (/home/alex/joy/npm_proj/node_modules/smartqq-bot/main.js:67:4)

I would assume that was an error only about paths, right?

@floatinghotpot
Copy link
Contributor

no no ... it seems that module is not found, weird ... i will double check the code, and give you feedback.

@floatinghotpot
Copy link
Contributor

which version of nodejs are you using? on linux or mac?

@xros
Copy link

xros commented Nov 3, 2015

@floatinghotpot I am on Ubuntu14.04 AMD64, npm --version == 2.10.1 . It fails if directory .tmp was created by hand.

@floatinghotpot
Copy link
Contributor

it works fine on my host, with nodejs v4.2.1.

i mean node -v or nodejs -v, if the nodejs is too old, i just guess var Path = require('path') may not have join() function.

BTW, you can use npm install -g n to install/manage nodejs versions easily.
https://github.com/tj/n

@xros
Copy link

xros commented Nov 3, 2015

@floatinghotpot node -v v0.12.4

I have not installed nodejs. So are they two different packages? I have zero knowledge to nodejs. I would try it later if i got time.

Thank you anyway

@yanboz
Copy link

yanboz commented Nov 3, 2015

@floatinghotpot

hitokoto失效中, 似乎是原来coffee版的robot.request.get无法使用了.
是否在JS版中实现?

@lazybios
Copy link

lazybios commented Nov 7, 2015

@xros I have the same problem. I solved it by update node version. you can follow https://github.com/tj/n document.

@floatinghotpot I have a new problem. When I execute qqbot , it tell me below message:

dyld: bad external relocation length
[1]    72902 trace trap  qqbot

what's wrong?

@flyingnn
Copy link
Contributor

@floatinghotpot smartqqbot
centos 6 报错:os.homedir() 大意是没有这个对象;

然后只能用这个代替:

function getUserHome() {
return process.env[(process.platform == 'win32') ? 'USERPROFILE' : 'HOME'];
}

@floatinghotpot
Copy link
Contributor

是不是 nodejs 版本的问题?

可以考虑升级到 nodejs v4.x,参考:https://nodejs.org/en/download/package-manager/

@flyingnn
Copy link
Contributor

的确是版本问题

@flyingnn
Copy link
Contributor

flyingnn commented Dec 9, 2015

@floatinghotpot 又无法登录了:

@floatinghotpot
Copy link
Contributor

是的,腾讯又改了webqq的通讯协议,登录的最后一个环节报错,暂时还没时间去详细分析

@xros
Copy link

xros commented Dec 10, 2015

@floatinghotpot Next time tencent would do something like what 12306 did to make people very difficult to get into its system. That's called "Object Recognition". Think about the global market rather some regions. No matter how hard you try, you just can not get a persistent and stable proxy to tencent. Unless someone was employed by tencent or he had business with it. He would get the internal API and not suffer anymore. The unfair fact is that tencent charges.

@floatinghotpot
Copy link
Contributor

smartqq-bot 已经修复了,请更新。感谢两位网友 ScienJus 和 thegfw 提供的帮助。

[sudo] npm install -g smartqq-bot

@blambin
Copy link

blambin commented Jan 11, 2016

@floatinghotpot 你那边没法留issue,我写在这里吧。
我在用webapi的时候 ,调用 ip:3200/stdin 的时候 ,qq就挂掉了 ,我想远程接收信息,这个能修复么。

[Mon Jan 11 2016 08:00:10 GMT-0500 (EST)] DEBUG polling...
[Mon Jan 11 2016 08:00:25 GMT-0500 (EST)] DEBUG [api] /stdin

/usr/lib/node_modules/smartqq-bot/plugins/apiserver.js:178
      value = params.value.trim();
                           ^
TypeError: Cannot call method 'trim' of undefined
at APIServer.on_stdin (/usr/lib/node_modules/smartqq-bot/plugins/apiserver.js:178:28)
at APIServer.<anonymous> (/usr/lib/node_modules/smartqq-bot/plugins/apiserver.js:152:25)
at APIServer.handle_request (/usr/lib/node_modules/smartqq-bot/plugins/apiserver.js:173:10)
at Server.<anonymous> (/usr/lib/node_modules/smartqq-bot/plugins/apiserver.js:115:26)
at Server.emit (events.js:98:17)
at HTTPParser.parser.onIncoming (http.js:2113:12)
at HTTPParser.parserOnHeadersComplete [as onHeadersComplete] (http.js:122:23)
at Socket.socket.ondata (http.js:1971:22)
at TCP.onread (net.js:528:27)

@wujianguo
Copy link

@floatinghotpot 请问下你的 smartqq-bot 可以能否直接用在 hubot 上?貌似需要修改代码?

@floatinghotpot
Copy link
Contributor

hubot我没用过,不熟悉

@hoojianliang
Copy link

hi,我一直停留在step 1。 我是使用 smartqq-bot 的

@uwang
Copy link

uwang commented Jul 20, 2017

smartqq-bot 也无法正常运行了:

vagrant@dev:~$ qqbot
[Thu Jul 20 2017 15:34:48 GMT+0800 (CST)] INFO 登录 step0 - 登录方式检测
[Thu Jul 20 2017 15:34:48 GMT+0800 (CST)] INFO 登录 step0.5 获取二维码
[Thu Jul 20 2017 15:34:48 GMT+0800 (CST)] NOTICE 请用 手机QQ 扫描该地址的二维码图片-> http://localhost:3100
[Thu Jul 20 2017 15:34:48 GMT+0800 (CST)] INFO 登录 step1 等待二维码校验结果
[Thu Jul 20 2017 15:35:09 GMT+0800 (CST)] INFO 登录 step2 cookie 获取 ptwebqq
[Thu Jul 20 2017 15:35:09 GMT+0800 (CST)] INFO 登录 step3 获取 vfwebqq
[Thu Jul 20 2017 15:35:09 GMT+0800 (CST)] INFO 登录 step4 获取 uin, psessionid
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] INFO 登录成功
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] INFO 登录 step5 获取 好友列表
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] DEBUG Loading Plugin help
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] DEBUG Loading Plugin debug
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] DEBUG Loading Plugin apiserver
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] INFO api server started at port 3200
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] INFO fetching buddy list...
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] INFO fetching group list...
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] INFO fetching discuss group list
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] INFO update discuss group list
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] INFO fetching all groupmember...
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] DEBUG updating all: all 3 finished 2 success 2
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] INFO fetching account info: type1, uin500088096
解析出错 http://s.web2.qq.com/api/get_friend_uin2 <html><head><title>Apache Tomcat/7.0.50 - Error report</title><style><!--H1 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:22px;} H2 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:16px;} H3 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:14px;} BODY {font-family:Tahoma,Arial,sans-serif;color:black;background-color:white;} B {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;} P {font-family:Tahoma,Arial,sans-serif;background:white;color:black;font-size:12px;}A {color : black;}A.name {color : black;}HR {color : #525D76;}--></style> </head><body><h1>HTTP Status 404 - </h1><HR size="1" noshade="noshade"><p><b>type</b> Status report</p><p><b>message</b> <u></u></p><p><b>description</b> <u>The requested resource is not available.</u></p><HR size="1" noshade="noshade"><h3>Apache Tomcat/7.0.50</h3></body></html>
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] DEBUG updating all: all 3 finished 3 success 2
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] ERROR 获取信息失败,再次尝试
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] INFO fetching buddy list...
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] INFO fetching group list...
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] INFO fetching discuss group list
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] INFO update discuss group list
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] INFO fetching all groupmember...
[Thu Jul 20 2017 15:35:10 GMT+0800 (CST)] DEBUG updating all: all 3 finished 2 success 2
[Thu Jul 20 2017 15:35:11 GMT+0800 (CST)] INFO fetching account info: type1, uin500088096
解析出错 http://s.web2.qq.com/api/get_friend_uin2 <html><head><title>Apache Tomcat/7.0.50 - Error report</title><style><!--H1 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:22px;} H2 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:16px;} H3 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:14px;} BODY {font-family:Tahoma,Arial,sans-serif;color:black;background-color:white;} B {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;} P {font-family:Tahoma,Arial,sans-serif;background:white;color:black;font-size:12px;}A {color : black;}A.name {color : black;}HR {color : #525D76;}--></style> </head><body><h1>HTTP Status 404 - </h1><HR size="1" noshade="noshade"><p><b>type</b> Status report</p><p><b>message</b> <u></u></p><p><b>description</b> <u>The requested resource is not available.</u></p><HR size="1" noshade="noshade"><h3>Apache Tomcat/7.0.50</h3></body></html>
[Thu Jul 20 2017 15:35:11 GMT+0800 (CST)] DEBUG updating all: all 3 finished 3 success 2
[Thu Jul 20 2017 15:35:11 GMT+0800 (CST)] ERROR 获取信息失败,请重新运行

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests