124 Commits

Author SHA1 Message Date
Haruue Icymoon
f7de18fd43
chore: a better approach for http proxy error log 2022-08-25 00:53:52 +08:00
Haruue Icymoon
2fb70bdb58
feat: log http proxy error
goproxy actually discard all upstream errors, you can find its error
handling here [1], the upstream error from proxy.connectDial() is always
hidden in the two if branches, and never got logged. we need to log
hysteria layer errors by ourselves.

[1] 8ea89ba920/https.go (L321-L328)

according to some bug reports (such like #404 and the resolve_preference
one report via telegram private message), some users use http proxy, got a
http 502 error without any useful logs.
2022-08-25 00:42:36 +08:00
Haruue Icymoon
7c9fbf22dd
feat: tcp buffer size options for tun mode
close: #407
2022-08-24 23:26:56 +08:00
Toby
8960aefca3 chore: update module names (hysteria & quic-go fork) 2022-08-20 11:44:12 -07:00
Toby
944c0ecf64 fix: resolve_preference should only assign each ip once 2 2022-08-13 11:48:09 -07:00
Toby
88099ee72d fix: resolve_preference should only assign each ip once 2022-08-13 11:39:40 -07:00
Toby
1462cadfdc format: gofumpt 2022-08-13 11:04:28 -07:00
Haruue Icymoon
4747be198e
fix: resolve_preference not work 2022-08-13 22:05:07 +08:00
Haruue Icymoon
0ba4c36bc6
Merge remote-tracking branch 'origin/master' into wip-newtun-license 2022-08-10 18:05:45 +08:00
Haruue Icymoon
720b97da67
chore: solve license conflict against tun2socks 2022-08-10 12:24:06 +08:00
Haruue Icymoon
80b0c87654
chore: log tun2socks internal warn as info 2022-08-10 11:39:29 +08:00
Haruue Icymoon
4abb30620a
fix: tun device not closed when killed 2022-08-10 11:39:10 +08:00
Haruue Icymoon
f3f604b59a
refactor(tun): switch to xjasonlyu/tun2socks
fix: #306, #394, #185, #161

break changes:

we won't create or maintain the interface now, so it is user's duty to
create the tun interface, for example, with command like
  ip tuntap add dev hytun mode tun
(or maybe we can use songgao/water to keep this behavior unchanged).

correspondingly, the "address", "gateway", "mask", "dns", "persist"
options in the "tun" config have been removed.

in addition, please note xjasonlyu/tun2socks is licensed under GPLv3 and
hysteria is licensed under MIT, I don't ensure is it legal to use it as
a go mod, but there are too many requests related on it so whatever...
2022-08-10 02:43:07 +08:00
Toby
3f0953ffdd feat: rework resolver support 2022-08-06 19:58:05 -07:00
Toby
5e4773a117
Merge branch 'master' into bind_to_device 2022-06-08 20:45:19 -07:00
Toby
8a64099a96 fix: build failure on linux 386 2022-06-07 12:44:38 -07:00
Toby
575de280ff feat: TCP redirect implementation 2022-06-06 18:09:34 -07:00
Toby
6d8e79170e chore: code optimizations 2022-06-06 16:06:30 -07:00
hellodword
32f35894cc feat: bind socket to a particular device 2022-05-23 22:33:37 +08:00
Toby
f3b999bce0 chore: change minAckRate to 0.8 2022-05-11 18:20:46 -07:00
Toby
343bfc3e0a feat: protocol port aliases 2022-05-11 17:43:25 -07:00
Toby
e9974b0398 ACL protocol & port support 2022-05-11 17:26:39 -07:00
Toby
28b6210ce5 perf: reduce time.Now overhead 2 2022-05-06 19:11:35 -07:00
Toby
95d8ea49cc perf: reduce time.Now overhead 2022-05-06 00:11:07 -07:00
Toby
56825c5525 fix tun timeout check 2022-04-30 12:00:13 -07:00
Toby
877affec42 feat: update quic-go to 0.27.0 2022-04-14 19:51:08 -07:00
Toby
fba6cf7a1c feat: server SOCKS5 outbound domain passthrough 2022-04-14 00:11:44 -07:00
Toby
f98eec69f2 feat: resolve preference 2022-03-27 15:10:16 -07:00
Toby
d4117504eb fix: incorrect UDP frag sendErr handling 2022-02-28 14:26:52 -08:00
Toby
2385959936 fix: SOCKS5 outbound bugs 2022-02-27 23:01:34 -08:00
Toby
a94009ed4b chore: code improvements 2022-02-27 13:53:37 -08:00
Toby
97ef033b65 feat: server SOCKS5 outbound 2022-02-26 20:45:20 -08:00
Toby
6b880ba22d feat wip: SOCKS5 client DialTCP 2022-02-26 13:05:52 -08:00
Toby
c0f53ea712 feat: v2 compatibility 2022-02-25 17:59:01 -08:00
Toby
1789db9ade feat: full frag support 2022-02-25 17:08:54 -08:00
Toby
6efa976a56 feat wip: bump protocol version & quic-go version, frag & defrag implementation 2022-02-25 00:14:22 -08:00
Toby
52bcc1d57b chore: move "disable TCP timeout for SOCKS5 UDP holder" out of the loop 2022-02-20 23:48:34 -08:00
Toby
cea6052309 fix: disable TCP timeout for SOCKS5 UDP holder 2022-02-20 23:42:35 -08:00
Toby
7466b69cce feat: re-enable PMTUD on Windows & Linux 2022-02-19 23:21:13 -08:00
Toby
d6b549cea4 fix: incorrect TProxy UDP implementation (228) 2022-02-19 17:42:02 -08:00
Toby
a4a4130ba1 fix: zero initMaxDatagramSize in brutal CC (wtf...) 2022-02-03 20:54:30 -08:00
Toby
c28cbcfcaa feat: multi-password & cmd auth 2022-01-24 17:26:33 -08:00
Toby
858d36cf30 chore: remove useless laddr from ListenUDP 2022-01-23 17:40:59 -08:00
Toby
841810d6ca feat: transport refactorization 2022-01-23 17:00:02 -08:00
Toby
013e44a9c5 feat: client connect & disconnect log for server 2022-01-21 17:21:56 -08:00
Toby
89452dd9c5 feat: ACL country support 2022-01-09 18:11:52 -08:00
Toby
069bcde2ac feat: wechat-video 2022-01-03 22:25:27 -08:00
Toby
23ed99ad05 feat: minAckRate = 0.75 2022-01-03 21:58:08 -08:00
Toby
8e1f43093a feat: better ack rate mechanism for brutal CC 2021-12-29 22:52:34 -08:00
Toby
1c06b66cdc feat: transport & obfs refactoring 2021-12-27 18:07:01 -08:00