semigodking / redsocks

transparent redirector of any TCP/UDP connection to proxy
Apache License 2.0
1.17k stars 247 forks source link

默认配置文件报错 #131

Closed pch18 closed 9 months ago

pch18 commented 5 years ago

通过./redsocks2 -c ./redsocks.conf.example启动后,报错如下

/app/redsocks-master # ./redsocks2 -c ./redsocks.conf.example
file parsing error at line 60: assignment with unknown key <bind>
file parsing error at line 60: unclosed section

配置文件60行附近是如下内容

redsocks {
    /* `bind' defaults to 127.0.0.1:0 for security reasons,
     * use 0.0.0.0 if you want to listen on every interface.
     * `bind' are used as ip:port to redirect to.
     */
    bind = "127.0.0.1:12345";           <- 这是60行

    // listen() queue length. Default value is SOMAXCONN and it should be
    // good enough for most of us.
    // listenq = 128; // SOMAXCONN equals 128 on my Linux box.

    // `max_accept_backoff` is a delay to retry `accept()` after accept
    // failur
semigodking commented 5 years ago

感谢报告问题。请试下最新提交是否解决。

semigodking commented 5 years ago

注意哦,最新代码是不兼容以前配置文件的。已将local_ip 这些换成bind这样。在config example中有示例

X.K. YANG notifications@github.com 于 2019年11月17日周日 13:36写道:

我先发最新提交的编译也是有问题;我的配置文件是这样:

base { log_debug = on; log_info = on; log = stderr; daemon = off; //user = nobody; //group = nobody; // chroot = "/var/chroot"; redirector = iptables; } redsocks { local_ip=127.0.0.1; local_port=443; type = shadowsocks; ip = 202.192.45.11; port = 8300; timeout = 13; autoproxy = 0; login = "aes-256-cfb"; password = "gis"; }

但是运行的时候提示 file parsing error at line 12: assignment with unknown key file parsing error at line 12: unclosed section

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/semigodking/redsocks/issues/131?email_source=notifications&email_token=AAP2XD6P3WXMSMQYCLJPCHDQUDJ6VA5CNFSM4JEDFXB2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEEIC43I#issuecomment-554708589, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAP2XD2TGMQHRGCMLFZ3DSLQUDJ6VANCNFSM4JEDFXBQ .

yanggis commented 5 years ago

注意哦,最新代码是不兼容以前配置文件的。已将local_ip 这些换成bind这样。在config example中有示例 X.K. YANG notifications@github.com 于 2019年11月17日周日 13:36写道: 我先发最新提交的编译也是有问题;我的配置文件是这样: base { log_debug = on; log_info = on; log = stderr; daemon = off; //user = nobody; //group = nobody; // chroot = "/var/chroot"; redirector = iptables; } redsocks { local_ip=127.0.0.1; local_port=443; type = shadowsocks; ip = 202.192.45.11; port = 8300; timeout = 13; autoproxy = 0; login = "aes-256-cfb"; password = "gis"; } 但是运行的时候提示 file parsing error at line 12: assignment with unknown key file parsing error at line 12: unclosed section — You are receiving this because you commented. Reply to this email directly, view it on GitHub <#131?email_source=notifications&email_token=AAP2XD6P3WXMSMQYCLJPCHDQUDJ6VA5CNFSM4JEDFXB2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEEIC43I#issuecomment-554708589>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAP2XD2TGMQHRGCMLFZ3DSLQUDJ6VANCNFSM4JEDFXBQ .

谢谢,已经看到新代码了。

yanggis commented 5 years ago

但是,我用了新的配置文件:

base { log_debug = on; log_info = on; log = stderr; daemon = off; //user = nobody; //group = nobody; // chroot = "/var/chroot"; redirector = iptables; } redsocks { bind = "0.0.0.0:8443"; type = shadowsocks; relay = "61.14.14.91:8339"; timeout = 120; autoproxy = 0; login = "aes-256-cfb"; password = "abc"; }

连接远程的SS服务器,无法获取任何数据,服务器ss日志报unsupported addrtype 54, maybe wrong password or encryption method 已经仔细检查了加密方法和密码肯定都没问题,用SS的windows客户端连接也是没有问题,唯独用redsocks2这个这个配置方法连接远程服务器就报这个错误。

yanggis commented 5 years ago

redsocks2的日志报错是: both client and server disconnected dropping client @ state: 1

semigodking commented 5 years ago

我找时间查一下

X.K. YANG notifications@github.com 于 2019年11月17日周日 23:32写道:

redsocks2的日志报错是: both client and server disconnected dropping client @ state: 1

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/semigodking/redsocks/issues/131?email_source=notifications&email_token=AAP2XD2L7356HVXA3KJU5GTQUFPZ7A5CNFSM4JEDFXB2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEEIOYFI#issuecomment-554757141, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAP2XD4TORRKUDLDUZBS7HDQUFPZ7ANCNFSM4JEDFXBQ .

yanggis commented 5 years ago

嗯,谢谢。

semigodking commented 4 years ago

确认是这个commit 把ss给弄坏了。 e7ff18b55131bcb850363f85ecdc73693c0202b5 我想想怎么修先

semigodking commented 4 years ago

试试最新代码吧。

yanggis commented 4 years ago

好的,谢谢。