Commit Graph
50 Commits
Author SHA1 Message Date
Syrone Wong f70b177e56 Misc
Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
2016-08-29 21:30:05 +08:00
noisyfox ed54b249db Close services while closing listener.
Now it will close all existing TCP relay connections
while reloading the listener.

Signed-off-by: noisyfox <timemanager.rick@gmail.com>
2016-08-26 21:08:04 +10:00
noisyfox 37d894594e Use immutable remote reference during async process.
To prevent "The IAsyncResult object was not returned from
the corresponding asynchronous method on this class." exception.

Signed-off-by: noisyfox <timemanager.rick@gmail.com>
2016-08-22 11:49:53 +10:00
noisyfox 2ed8ab50cd Only parse socks5 header once per connection.
To avoid unreadable and uncessary output

Signed-off-by: noisyfox <timemanager.rick@gmail.com>
2016-08-19 13:36:49 +10:00
noisyfox 6cb58b229d Fix a null ref exception.
At that time the remote even doesn't exist.
Also this debug output doesn't make any sense because when handling
udp request, this tcp connection won't have any meaningful data.
So I simply removed these two lines.

Signed-off-by: noisyfox <timemanager.rick@gmail.com>
2016-08-16 20:52:53 +10:00
noisyfox 53ce1948e4 Unified ipv4, ipv6 and domain connections.
-Use dual-mode socket & DnsEndPoint to handle all domain name connection.
-Move all socket creation into one single function.

So that we could treat domain name just like ipv4 & ipv6 address.
This also solves the async domain solving problem because the os will
hanlde it for us.
2016-08-16 20:40:09 +10:00
noisyfox ad15c7e64b Improve host address handling using DnsEndPoint
Signed-off-by: noisyfox <timemanager.rick@gmail.com>
2016-08-16 17:28:26 +10:00
noisyfox a02cd11dc9 Let proxy module handle name resolving itself.
Fix wrong output in proxyConnectTimer_Elapsed.

Signed-off-by: noisyfox <timemanager.rick@gmail.com>
2016-08-16 01:11:33 +10:00
Syrone Wong a9af9fdfc0 Refactor
- use null conditional access in case some connections been
  cancelled unexpectedly and may cause null reference exception
- Refine error message
- use conditional operator to simplify some code

Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
2016-08-10 15:27:38 +08:00
Syrone Wong 93e7641446 Minor changes
- display user-friendly server name
- clarify proxy type

Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
2016-08-09 08:24:44 +08:00
Noisyfox He e23641c522 Improved debug info output by using isVerboseLogging 2016-08-08 22:24:00 +10:00
Noisyfox He 6a3e06cdb3 Merge branch 'master' of https://github.com/shadowsocks/shadowsocks-windows.git into dev_proxy
# Conflicts:
#	shadowsocks-csharp/Controller/Service/TCPRelay.cs
#	shadowsocks-csharp/Controller/ShadowsocksController.cs
#	shadowsocks-csharp/View/MenuViewController.cs
2016-08-08 21:21:53 +10:00
Syrone Wong d3acb3e681 Refine verbose logging handling
I can't wait until PR #604 get merged, do it manually.

Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
2016-08-08 15:36:04 +08:00
Syrone Wong fb3fcdb90d Add verbose logging to log every connection
Note:
- Added a configuration entry, user should add this
  by hand or reset from scratch.

Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
2016-08-08 10:33:17 +08:00
Syrone Wong f21c534704 minor changes
Signed-off-by: Syrone Wong <wong.syrone@gmail.com>
2016-08-05 16:31:05 +08:00
noisyfox 4a1aa01a4f Enable proxy switch 2016-06-30 00:09:45 +08:00
noisyfox 95d4e3a0c0 Add proxy support 2016-06-29 22:38:51 +08:00
kimw f9296b49b1 clean up buggy parameter.
Replaced SocketFlags.None (an enum which euqals 0) from zero.
2016-05-15 02:17:05 -04:00
kimw ff04a2a18a clean up code in C# 6 2016-05-15 02:04:04 -04:00
kimw 0cee110e59 renamed private properties with prefix underline 2016-05-15 01:44:03 -04:00
kimw 4b3ec38691 featured print "connect to hostname:port" to log 2016-05-15 01:34:28 -04:00
icylogic a99fef37d3 track multiple servers at the same time
Correct AvailabilityStatistics's behavior under special strategies like "LoadBalance", which may switch the server several times in a short period.
2016-03-01 21:32:43 +08:00
icylogic 7599704d1f add speed to statistics 2016-01-18 01:31:50 +08:00
Gang Zhuo b918cb85ae tiny fix 2016-01-05 01:54:42 -05:00
kimw 2cce646700 featured show bandwidth in log form's title 2016-01-04 23:21:53 +08:00
kimw 0b16ef7445 Merge upstream
# Conflicts:
#	README.md
#	shadowsocks-csharp/Controller/Service/AvailabilityStatistics.cs
#	shadowsocks-csharp/Controller/Service/PACServer.cs
#	shadowsocks-csharp/Controller/Strategy/SimplyChooseByStatisticsStrategy.cs
#	shadowsocks-csharp/Data/cn.txt
#	shadowsocks-csharp/Model/Configuration.cs
#	shadowsocks-csharp/Model/LogViewerConfig.cs
#	shadowsocks-csharp/View/LogForm.Designer.cs
#	shadowsocks-csharp/View/LogForm.cs
#	shadowsocks-csharp/View/MenuViewController.cs
2016-01-04 09:14:55 +08:00
10people d0e16dc658 Add debug log in network transfer. 2015-11-16 14:59:10 +08:00
Gang Zhuo 29d70acfb5 replace 'one_time_auth' to 'auth' 2015-10-07 23:43:41 -04:00
Gang Zhuo 098640e792 refact 2015-09-25 04:42:56 -04:00
Gang Zhuo c5e27486fb Protocol V2 2015-09-25 04:03:04 -04:00
Gang Zhuo 3aac1cfcfc Refine the authentication for true CCA 2015-09-23 02:08:41 -04:00
Gang Zhuo 19085a3cd1 Update the hash function
follow with https://github.com/shadowsocks/shadowsocks-libev/commit/5ae4df94e440c4f6826a679a62687ad27303d89b
2015-09-20 23:25:37 -04:00
Gang Zhuo eae3943556 reserve buffer for one-time auth 2015-09-20 15:13:12 +08:00
Gang Zhuo ca8df1b51f fix buffer size 2015-09-20 15:13:11 +08:00
Gang Zhuo 1564e9ff81 support onetime auth 2015-09-20 15:13:11 +08:00
kimw 0a733c61b8 fixed: standardize Logging usage
1. Add Logging.Info()
2. Console.WriteLine() -> Logging.Info()
3. Console.WriteLine() in exceptions -> Logging.LogUsefulException()
2015-09-14 14:58:46 +08:00
kimw f6085d9362 Merge remote-tracking branch 'upstream/master' 2015-08-19 18:39:23 +08:00
clowwindy 7081819390 timeout 30min -> 15min 2015-08-19 13:05:12 +08:00
kimw 758c497eba same the source code format.
1/ removed dual empty line
2/ removed tailing spaces
3/ converted tabs into spaces
4/ added some TODO comments
2015-08-19 00:24:08 +08:00
clowwindy 750ee4fa5f add handler timeout 2015-08-18 21:34:05 -07:00
clowwindy 3bc77d212a reduce cache size 2015-08-18 21:34:04 -07:00
clowwindy c66ede2f59 fix a warning 2015-07-26 12:38:08 +08:00
clowwindy eda92b80e1 refine logs 2015-07-26 12:27:34 +08:00
clowwindy dafe33f7ed fix a crash 2015-07-25 19:05:37 +08:00
clowwindy 008e3544f2 refine HA 2015-07-25 18:39:14 +08:00
clowwindy 449df1022d add connect timeout 2015-07-25 17:40:08 +08:00
clowwindy cb5fece8b3 HA almost works 2015-07-25 16:22:28 +08:00
clowwindy 8c869ca38e add retry 2015-07-25 14:16:29 +08:00
clowwindy ddd46ed8c6 add HA 2015-07-24 04:17:33 +08:00
clowwindy 4afd5faf3f add load balancing 2015-07-22 15:58:39 +08:00