@@ -6,7 +6,7 @@ using System.Net.Sockets; | |||||
using System.Reflection; | using System.Reflection; | ||||
using Shadowsocks.Model; | using Shadowsocks.Model; | ||||
namespace Shadowsocks.Proxy | |||||
namespace Shadowsocks.Controller.Service | |||||
{ | { | ||||
// https://github.com/shadowsocks/shadowsocks-org/wiki/Plugin | // https://github.com/shadowsocks/shadowsocks-org/wiki/Plugin | ||||
public sealed class Sip003Plugin : IDisposable | public sealed class Sip003Plugin : IDisposable | ||||
@@ -41,7 +41,7 @@ namespace Shadowsocks.Proxy | |||||
{ | { | ||||
throw new ArgumentException("Value cannot be null or whitespace.", nameof(serverAddress)); | throw new ArgumentException("Value cannot be null or whitespace.", nameof(serverAddress)); | ||||
} | } | ||||
if ((uint)serverPort != serverPort) | |||||
if ((ushort)serverPort != serverPort) | |||||
{ | { | ||||
throw new ArgumentOutOfRangeException("serverPort"); | throw new ArgumentOutOfRangeException("serverPort"); | ||||
} | } |
@@ -15,6 +15,7 @@ using Shadowsocks.Model; | |||||
using Shadowsocks.Properties; | using Shadowsocks.Properties; | ||||
using Shadowsocks.Util; | using Shadowsocks.Util; | ||||
using System.Linq; | using System.Linq; | ||||
using Shadowsocks.Controller.Service; | |||||
using Shadowsocks.Proxy; | using Shadowsocks.Proxy; | ||||
namespace Shadowsocks.Controller | namespace Shadowsocks.Controller | ||||
@@ -145,7 +145,7 @@ | |||||
<Compile Include="Controller\Strategy\BalancingStrategy.cs" /> | <Compile Include="Controller\Strategy\BalancingStrategy.cs" /> | ||||
<Compile Include="Controller\Strategy\StrategyManager.cs" /> | <Compile Include="Controller\Strategy\StrategyManager.cs" /> | ||||
<Compile Include="Controller\Strategy\IStrategy.cs" /> | <Compile Include="Controller\Strategy\IStrategy.cs" /> | ||||
<Compile Include="Proxy\Sip003Plugin.cs" /> | |||||
<Compile Include="Controller\Service\Sip003Plugin.cs" /> | |||||
<Compile Include="Proxy\Socks5Proxy.cs" /> | <Compile Include="Proxy\Socks5Proxy.cs" /> | ||||
<Compile Include="Settings.cs" /> | <Compile Include="Settings.cs" /> | ||||
<Compile Include="StringEx.cs" /> | <Compile Include="StringEx.cs" /> | ||||