使用consocket实现socks5,在代理 https的时候页面报错

68 views
Skip to first unread message

Geoff zhang

unread,
Jul 23, 2019, 7:04:52 AM7/23/19
to openresty
local data, err, partial1 = downsock:receive('*a') --下游接收数据
if partial1 then
local bytes, err = upsock:send(partial1) --向上游send数据
local data1,err,partial = upsock:receive('*a') -- 从上游接收数据
if partial then
downsock:send(partial) -- 向下游send数据
end
return
else
ngx.say("boom!")
return
end
baidu.jpg

Geoff zhang

unread,
Jul 23, 2019, 7:06:29 AM7/23/19
to openresty
大家知道什么原因或者有什么好的建议吗?

在 2019年7月23日星期二 UTC+8下午7:04:52,Geoff zhang写道:

DeJiang Zhu

unread,
Jul 26, 2019, 9:17:18 PM7/26/19
to open...@googlegroups.com
这类问题,你抓包分析一下应该就知道

Geoff zhang <zhang.ge...@gmail.com> 于2019年7月23日周二 下午7:06写道:
--
--
邮件来自列表“openresty”,专用于技术讨论!
订阅: 请发空白邮件到 openresty...@googlegroups.com
发言: 请发邮件到 open...@googlegroups.com
退订: 请发邮件至 openresty+...@googlegroups.com
归档: http://groups.google.com/group/openresty
官网: http://openresty.org/
仓库: https://github.com/agentzh/ngx_openresty
教程: http://openresty.org/download/agentzh-nginx-tutorials-zhcn.html
---
您收到此邮件是因为您订阅了Google网上论坛上的“openresty”群组。
要退订此群组并停止接收此群组的电子邮件,请发送电子邮件到openresty+...@googlegroups.com
要在网络上查看此讨论,请访问https://groups.google.com/d/msgid/openresty/5c77a364-451e-4fb0-a943-1953810cf078%40googlegroups.com

Geoff zhang

unread,
Jul 28, 2019, 10:03:05 PM7/28/19
to openresty

不正常.jpg

抓包中显示,在建立TLS连接的过程中,只到 Server Hello Done 就停止了, openresty在receive的时候就超时了。
是不是不能用receive('*a'),而是用其他的方法?

在 2019年7月27日星期六 UTC+8上午9:17:18,doujiang写道:
这类问题,你抓包分析一下应该就知道

Geoff zhang <zhang.g...@gmail.com> 于2019年7月23日周二 下午7:06写道:
大家知道什么原因或者有什么好的建议吗?

在 2019年7月23日星期二 UTC+8下午7:04:52,Geoff zhang写道:
local data, err, partial1 = downsock:receive('*a') --下游接收数据
if partial1 then
local bytes, err = upsock:send(partial1) --向上游send数据
local data1,err,partial = upsock:receive('*a') -- 从上游接收数据
if partial then
downsock:send(partial) -- 向下游send数据
end
return
else
ngx.say("boom!")
return
end

--
--
邮件来自列表“openresty”,专用于技术讨论!
订阅: 请发空白邮件到 open...@googlegroups.com
发言: 请发邮件到 open...@googlegroups.com
退订: 请发邮件至 open...@googlegroups.com

归档: http://groups.google.com/group/openresty
官网: http://openresty.org/
仓库: https://github.com/agentzh/ngx_openresty
教程: http://openresty.org/download/agentzh-nginx-tutorials-zhcn.html
---
您收到此邮件是因为您订阅了Google网上论坛上的“openresty”群组。
要退订此群组并停止接收此群组的电子邮件,请发送电子邮件到openresty+unsubscribe@googlegroups.com
要在网络上查看此讨论,请访问https://groups.google.com/d/msgid/openresty/5c77a364-451e-4fb0-a943-1953810cf078%40googlegroups.com
Reply all
Reply to author
Forward
0 new messages