Commit Graph
16 Commits
Author SHA1 Message Date
zonyitoo 4fdc41dbbf removed confusing redir tcp log 2020-12-22 22:51:10 +08:00
zonyitoo 80bbe04559 hide the first balancer check info log 2020-12-22 22:37:14 +08:00
zonyitoo 3e27fed614 fixed future and Arc circlar reference 2020-12-22 22:31:19 +08:00
zonyitoo 24e203f5f9 use sleep instead of interval 2020-12-22 15:38:14 +08:00
zonyitoo 9210ee63ac local server starts after plugins are started, and balancer have choosen the best server 2020-12-22 15:11:49 +08:00
zonyitoo 4065ba3d38 fixed bug, calculate UDP server score 2020-12-22 14:35:41 +08:00
zonyitoo 49961a032b increase udp pending packet slots to 1024 2020-12-22 12:44:07 +08:00
zonyitoo 3d8c4cb641 lower log level to trace 2020-12-22 09:17:20 +08:00
zonyitoo 156c588dbc redir tcp should connect remote based on acl 2020-12-22 01:12:29 +08:00
zonyitoo 5eae086313 skip unused rdata section 2020-12-22 01:01:18 +08:00
zonyitoo fc17623c9e add useful logs about association drops 2020-12-22 00:28:10 +08:00
zonyitoo 906e0ed3e2 renamed recv_from_with_destination to recv_dest_from 2020-12-21 22:26:03 +08:00
zonyitoo 89e9b1400a active cleanup of expired udp associations, fixed #351 2020-12-21 22:21:26 +08:00
zonyitoo faed7ed3e2 avoid async_trait on recv_from_with_destination call 2020-12-21 22:00:49 +08:00
zonyitoo 34fadeecd2 fixed bsd udp redir build 2020-12-21 10:30:01 +08:00
ty 07583f3cc8 Refactored and separate library into crates (#345)
* Refactored and separate library into crates

- shadowsocks: the core feature of shadowsocks
- shadowsocks-service: library for building shadowsocks services
    - dns, http, redir, socks, tunnel
    - load balancer
- shadowsocks-rust: release binaries

fix #347

* unified DnsResolver implementation

* unified local service common parameters into ServiceContext

- ServiceContext is common parameters shared between all local
implementations
- Completely removed https local support

* add #292 reply attack protection

* migrated redir local server

* support customizing outbound socket bind address

* manager outbound socket should accepts connect_opts

* republic local implementations

* socks5 udp server should always listen to client address

* socks4 controlled by local-socks4 feature

* socks4 also obey mode configuration

* socks server tcp cannot be disable. add support of udp-bind-addr parameter

* add udp-bind-addr for customizing udp-relay bind-addr

* local-dns infra, support customizing resolver

* fully implements DNS relay server

* support binding to specific interface on Linux-like platform

* tcp cannot be disabled in socks

* enable local-flow-stat

* fixed windows build

* fixed android specific warnings and compile errors

* allow udp_only mode in socks5

* dns relay listens to both TCP and UDP, mode controls outbound upstreams

* dns relay retries twice if request failed

* doc

* fix DnsClient typo

* fix stream EncryptWriter bug

* allow disable logging output

updated dependencies

* add readme

* refine doc

* remove depending on trust-dns-client

* socks4/4a client

* allow socks5 udp_only mode, fixes compile warning

* create standalone socks5 UDP relay server

- socks5 UDP association full cone (NAT2)

* server udp relay supports full cone (NAT2)

* acl moved to crate root

* redir udp relay support full cone (NAT2)

* standard socks5 udp test must use tcp_and_udp mode

* set server context fields with pub APIs

* udp_max_associations and udp_timeout default value set in Config

* local dns resolver retry with fixed attempts

* max_udp_association keeps unlimited by default

* fixed logging binary name

* pops first exited future result for local and server

* update reverse target index cache

* fix ProxyClientStreamWriteHalf that allows sending empty buffers

ref #232

* remove unused import when socks4 is disabled

* make balancer become a globally shared object

* print plugin exit status

* control local, server, manager services in features
2020-12-20 19:06:21 +08:00