diff --git a/DotNetCore/HackerSpray.Middleware.Test/project.json b/DotNetCore/HackerSpray.Middleware.Test/project.json index e3fc8f6..efa4431 100644 --- a/DotNetCore/HackerSpray.Middleware.Test/project.json +++ b/DotNetCore/HackerSpray.Middleware.Test/project.json @@ -8,20 +8,20 @@ "HackerSpray.Middleware": "1.0.0-*", "HackerSpray.Module": "1.0.0-*", "MSTest.TestFramework": "1.0.0-preview", - "Microsoft.AspNetCore.TestHost": "1.0.0-rc2-final", - "Microsoft.EntityFrameworkCore": "1.0.0-rc2-final", - "Microsoft.AspNetCore.Identity": "1.0.0-rc2-final", - "Microsoft.AspNetCore.Mvc": "1.0.0-rc2-final", - "Microsoft.Extensions.Configuration.FileExtensions": "1.0.0-rc2-final", - "Microsoft.Extensions.Logging.Console": "1.0.0-rc2-final", - "Microsoft.Extensions.Logging.Debug": "1.0.0-rc2-final", - "Microsoft.Extensions.Configuration.Json": "1.0.0-rc2-final", - "Microsoft.Extensions.Configuration.EnvironmentVariables": "1.0.0-rc2-final", - "Microsoft.Extensions.Configuration.UserSecrets": "1.0.0-rc2-final", - "Microsoft.Extensions.DependencyInjection.Abstractions": "1.0.0-rc2-final", - "Microsoft.AspNetCore.Hosting": "1.0.0-rc2-final", - "Microsoft.AspNetCore.Http.Abstractions": "1.0.0-rc2-final", - "System.Diagnostics.TextWriterTraceListener": "4.0.0-beta-23516", + "Microsoft.AspNetCore.TestHost": "1.0.0", + "Microsoft.EntityFrameworkCore": "1.0.0", + "Microsoft.AspNetCore.Identity": "1.0.0", + "Microsoft.AspNetCore.Mvc": "1.0.0", + "Microsoft.Extensions.Configuration.FileExtensions": "1.0.0", + "Microsoft.Extensions.Logging.Console": "1.0.0", + "Microsoft.Extensions.Logging.Debug": "1.0.0", + "Microsoft.Extensions.Configuration.Json": "1.0.0", + "Microsoft.Extensions.Configuration.EnvironmentVariables": "1.0.0", + "Microsoft.Extensions.Configuration.UserSecrets": "1.0.0", + "Microsoft.Extensions.DependencyInjection.Abstractions": "1.0.0", + "Microsoft.AspNetCore.Hosting": "1.0.0", + "Microsoft.AspNetCore.Http.Abstractions": "1.0.0", + "System.Diagnostics.TextWriterTraceListener": "4.0.0", "Serilog": "2.0.0-rc-622", "Serilog.Sinks.Seq": "2.0.0-rc-55", "Serilog.Extensions.Logging": "1.0.0-rc2-10110" @@ -36,7 +36,7 @@ "dependencies": { "Microsoft.NETCore.App": { - "version": "1.0.0-rc2-3002702", + "version": "1.0.0", "type": "platform" } } diff --git a/DotNetCore/HackerSpray.Middleware/project.json b/DotNetCore/HackerSpray.Middleware/project.json index d3edc80..e6ee0fe 100644 --- a/DotNetCore/HackerSpray.Middleware/project.json +++ b/DotNetCore/HackerSpray.Middleware/project.json @@ -5,19 +5,24 @@ "version": "1.0.0-*", "dependencies": { - "Microsoft.AspNetCore.Http.Abstractions": "1.0.0-rc2-final", - "Microsoft.Extensions.Configuration.Abstractions": "1.0.0-rc2-final", - "Microsoft.Extensions.Logging.Abstractions": "1.0.0-rc2-final", - "Microsoft.Extensions.Options": "1.0.0-rc2-final", - "NETStandard.Library": "1.5.0-rc2-24027" + "Microsoft.AspNetCore.Http.Abstractions": "1.0.0", + "Microsoft.Extensions.Configuration.Abstractions": "1.0.0", + "Microsoft.Extensions.Logging.Abstractions": "1.0.0", + "Microsoft.Extensions.Options": "1.0.0", + "NETStandard.Library": "1.6.0" }, "frameworks": { - "netstandard1.5": { + "netstandard1.6": { "dependencies": { "HackerSpray.Module": "1.0.0-*" }, "imports": "dnxcore50" - } + }, + "netcoreapp1.0": { + "dependencies": { + "HackerSpray.Module": "1.0.0-*" + } + } } } diff --git a/DotNetCore/HackerSpray.Module/project.json b/DotNetCore/HackerSpray.Module/project.json index 74662a0..cfc956c 100644 --- a/DotNetCore/HackerSpray.Module/project.json +++ b/DotNetCore/HackerSpray.Module/project.json @@ -5,15 +5,18 @@ "version": "1.0.0-*", "dependencies": { - "Microsoft.Extensions.Logging.Abstractions": "1.0.0-rc2-final", - "NETStandard.Library": "1.5.0-rc2-24027", + "Microsoft.Extensions.Logging.Abstractions": "1.0.0", + "NETStandard.Library": "1.6.0", "StackExchange.Redis": "1.1.604-alpha", "System.Diagnostics.TraceSource": "4.0.0-rc2-24027" }, "frameworks": { - "netstandard1.5": { + "netstandard1.6": { "imports": "dnxcore50" + }, + "netcoreapp1.0": { + } } } diff --git a/DotNetCore/SampleASPNETCoreWebApp/Data/log-20160711.txt b/DotNetCore/SampleASPNETCoreWebApp/Data/log-20160711.txt new file mode 100644 index 0000000..77e770b --- /dev/null +++ b/DotNetCore/SampleASPNETCoreWebApp/Data/log-20160711.txt @@ -0,0 +1,12 @@ +2016-07-11 20:47:13.200 +01:00 [Fatal] Application startup exception +StackExchange.Redis.RedisConnectionException: It was not possible to connect to the redis server(s); to create a disconnected multiplexer, disable AbortOnConnectFail. SocketFailure on PING + at StackExchange.Redis.ConnectionMultiplexer.ConnectImpl(Func`1 multiplexerFactory, TextWriter log) + at HackerSpray.Module.RedisDefenceStore..ctor(String connectionString, String prefix, DefenceConfig config) in E:\GitHub\HackerSpray\DotNetCore\HackerSpray.Module\RedisDefenceStore.cs:line 33 + at HackerSpray.Middleware.HackerSprayerMiddleware..ctor(RequestDelegate next, ILoggerFactory loggerFactory, HackerSprayOption option) in E:\GitHub\HackerSpray\DotNetCore\HackerSpray.Middleware\HackerSprayerMiddleware.cs:line 41 +--- End of stack trace from previous location where exception was thrown --- + at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + at Microsoft.Extensions.Internal.ActivatorUtilities.ConstructorMatcher.CreateInstance(IServiceProvider provider) + at Microsoft.Extensions.Internal.ActivatorUtilities.CreateInstance(IServiceProvider provider, Type instanceType, Object[] parameters) + at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.<>c__DisplayClass3_0.b__0(RequestDelegate next) + at Microsoft.AspNetCore.Builder.Internal.ApplicationBuilder.Build() + at Microsoft.AspNetCore.Hosting.Internal.WebHost.BuildApplication() diff --git a/DotNetCore/SampleASPNETCoreWebApp/Data/log-20160712.txt b/DotNetCore/SampleASPNETCoreWebApp/Data/log-20160712.txt new file mode 100644 index 0000000..850a760 --- /dev/null +++ b/DotNetCore/SampleASPNETCoreWebApp/Data/log-20160712.txt @@ -0,0 +1,12 @@ +2016-07-12 23:07:27.509 +01:00 [Fatal] Application startup exception +StackExchange.Redis.RedisConnectionException: It was not possible to connect to the redis server(s); to create a disconnected multiplexer, disable AbortOnConnectFail. SocketFailure on PING + at StackExchange.Redis.ConnectionMultiplexer.ConnectImpl(Func`1 multiplexerFactory, TextWriter log) + at HackerSpray.Module.RedisDefenceStore..ctor(String connectionString, String prefix, DefenceConfig config) in E:\GitHub\HackerSpray\DotNetCore\HackerSpray.Module\RedisDefenceStore.cs:line 32 + at HackerSpray.Middleware.HackerSprayerMiddleware..ctor(RequestDelegate next, ILoggerFactory loggerFactory, HackerSprayOption option) in E:\GitHub\HackerSpray\DotNetCore\HackerSpray.Middleware\HackerSprayerMiddleware.cs:line 41 +--- End of stack trace from previous location where exception was thrown --- + at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + at Microsoft.Extensions.Internal.ActivatorUtilities.ConstructorMatcher.CreateInstance(IServiceProvider provider) + at Microsoft.Extensions.Internal.ActivatorUtilities.CreateInstance(IServiceProvider provider, Type instanceType, Object[] parameters) + at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.<>c__DisplayClass3_0.b__0(RequestDelegate next) + at Microsoft.AspNetCore.Builder.Internal.ApplicationBuilder.Build() + at Microsoft.AspNetCore.Hosting.Internal.WebHost.BuildApplication() diff --git a/DotNetCore/SampleASPNETCoreWebApp/Startup.cs b/DotNetCore/SampleASPNETCoreWebApp/Startup.cs index 1fba05c..0d77768 100644 --- a/DotNetCore/SampleASPNETCoreWebApp/Startup.cs +++ b/DotNetCore/SampleASPNETCoreWebApp/Startup.cs @@ -27,6 +27,7 @@ public Startup(IHostingEnvironment env) var builder = new ConfigurationBuilder() .SetBasePath(env.ContentRootPath) .AddJsonFile("appsettings.json", optional: true, reloadOnChange: true) + .AddJsonFile("hackerspray.json", optional: true, reloadOnChange: true) .AddJsonFile($"appsettings.{env.EnvironmentName}.json", optional: true); if (env.IsDevelopment()) diff --git a/DotNetCore/SampleASPNETCoreWebApp/appsettings.json b/DotNetCore/SampleASPNETCoreWebApp/appsettings.json index 86b264e..8d38806 100644 --- a/DotNetCore/SampleASPNETCoreWebApp/appsettings.json +++ b/DotNetCore/SampleASPNETCoreWebApp/appsettings.json @@ -3,15 +3,7 @@ //"DefaultConnection": "Server=(localdb)\\mssqllocaldb;Database=aspnet-SampleASPNETCoreWebApp-c969a878-7ed3-488b-a03d-d360a385aaa6;Trusted_Connection=True;MultipleActiveResultSets=true" "DefaultConnection": "Server=.\\sqlexpress12;Database=aspnet5-HackerSpray.SampleDotNetCoreWebsite-f6a67b61-ff0f-4456-9e9e-edc29843b443;Trusted_Connection=True;MultipleActiveResultSets=true" }, - "HackerSpray": { - "Redis": "127.0.0.1", - "Prefix": "AuthTest-Core:", - "Keys": [ - "POST /Account/Login 100 00:10:00 key+origin", - "GET /Account/Login 100 00:10:00 key+origin", - "GET /Home/ 10000 00:10:00 key+origin" - ] - }, + "Logging": { "IncludeScopes": false, "LogLevel": { diff --git a/DotNetCore/SampleASPNETCoreWebApp/hackerspray.json b/DotNetCore/SampleASPNETCoreWebApp/hackerspray.json new file mode 100644 index 0000000..434c990 --- /dev/null +++ b/DotNetCore/SampleASPNETCoreWebApp/hackerspray.json @@ -0,0 +1,11 @@ +{ + "HackerSpray": { + "Redis": "127.0.0.1", + "Prefix": "AuthTest-Core:", + "Keys": [ + "POST /Account/Login 100 00:10:00 key+origin", + "GET /Account/Login 100 00:10:00 key+origin", + "GET /Home/ 10000 00:10:00 key+origin" + ] + } +} diff --git a/DotNetCore/SampleASPNETCoreWebApp/project.json b/DotNetCore/SampleASPNETCoreWebApp/project.json index 44be5ea..6757e97 100644 --- a/DotNetCore/SampleASPNETCoreWebApp/project.json +++ b/DotNetCore/SampleASPNETCoreWebApp/project.json @@ -1,75 +1,65 @@ { - "userSecretsId": "aspnet-SampleASPNETCoreWebApp-c969a878-7ed3-488b-a03d-d360a385aaa6", + "userSecretsId": "aspnet-WebApplication5-1e3fe45c-e09a-4240-967b-54897fdc035a", "dependencies": { "Microsoft.NETCore.App": { - "version": "1.0.0-rc2-3002702", + "version": "1.0.0", "type": "platform" }, - "Microsoft.AspNetCore.Authentication.Cookies": "1.0.0-rc2-final", - "Microsoft.AspNetCore.Diagnostics": "1.0.0-rc2-final", - "Microsoft.AspNetCore.Diagnostics.EntityFrameworkCore": "1.0.0-rc2-final", - "Microsoft.AspNetCore.Identity.EntityFrameworkCore": "1.0.0-rc2-final", - "Microsoft.AspNetCore.Mvc": "1.0.0-rc2-final", + "Microsoft.AspNetCore.Authentication.Cookies": "1.0.0", + "Microsoft.AspNetCore.Diagnostics": "1.0.0", + "Microsoft.AspNetCore.Diagnostics.EntityFrameworkCore": "1.0.0", + "Microsoft.AspNetCore.Identity.EntityFrameworkCore": "1.0.0", + "Microsoft.AspNetCore.Mvc": "1.0.0", "Microsoft.AspNetCore.Razor.Tools": { - "version": "1.0.0-preview1-final", + "version": "1.0.0-preview2-final", + "type": "build" + }, + "Microsoft.AspNetCore.Server.IISIntegration": "1.0.0", + "Microsoft.AspNetCore.Server.Kestrel": "1.0.0", + "Microsoft.AspNetCore.StaticFiles": "1.0.0", + "Microsoft.EntityFrameworkCore.SqlServer": "1.0.0", + "Microsoft.EntityFrameworkCore.SqlServer.Design": { + "version": "1.0.0", "type": "build" }, - "Microsoft.AspNetCore.Server.IISIntegration": "1.0.0-rc2-final", - "Microsoft.AspNetCore.Server.Kestrel": "1.0.0-rc2-final", - "Microsoft.AspNetCore.StaticFiles": "1.0.0-rc2-final", - "Microsoft.EntityFrameworkCore.SqlServer": "1.0.0-rc2-final", "Microsoft.EntityFrameworkCore.Tools": { - "version": "1.0.0-preview1-final", + "version": "1.0.0-preview2-final", "type": "build" }, - "Microsoft.Extensions.Configuration.EnvironmentVariables": "1.0.0-rc2-final", - "Microsoft.Extensions.Configuration.Json": "1.0.0-rc2-final", - "Microsoft.Extensions.Configuration.UserSecrets": "1.0.0-rc2-final", - "Microsoft.Extensions.Logging": "1.0.0-rc2-final", - "Microsoft.Extensions.Logging.Console": "1.0.0-rc2-final", - "Microsoft.Extensions.Logging.Debug": "1.0.0-rc2-final", - "Microsoft.VisualStudio.Web.BrowserLink.Loader": "14.0.0-rc2-final", + "Microsoft.Extensions.Configuration.EnvironmentVariables": "1.0.0", + "Microsoft.Extensions.Configuration.Json": "1.0.0", + "Microsoft.Extensions.Configuration.UserSecrets": "1.0.0", + "Microsoft.Extensions.Logging": "1.0.0", + "Microsoft.Extensions.Logging.Console": "1.0.0", + "Microsoft.Extensions.Logging.Debug": "1.0.0", + "Microsoft.Extensions.Options.ConfigurationExtensions": "1.0.0", + "Microsoft.VisualStudio.Web.BrowserLink.Loader": "14.0.0", "Microsoft.VisualStudio.Web.CodeGeneration.Tools": { - "version": "1.0.0-preview1-final", + "version": "1.0.0-preview2-final", "type": "build" }, "Microsoft.VisualStudio.Web.CodeGenerators.Mvc": { - "version": "1.0.0-preview1-final", + "version": "1.0.0-preview2-final", "type": "build" }, "HackerSpray.Module": "1.0.0-*", "HackerSpray.Middleware": "1.0.0-*", - "System.Diagnostics.TextWriterTraceListener": "4.0.0-beta-23516", + "System.Diagnostics.TextWriterTraceListener": "4.0.0", "Serilog": "2.0.0-rc-622", "Serilog.Sinks.Seq": "2.0.0-rc-55", "Serilog.Extensions.Logging": "1.0.0-rc2-10110" }, "tools": { - "Microsoft.AspNetCore.Razor.Tools": { - "version": "1.0.0-preview1-final", - "imports": "portable-net45+win8+dnxcore50" - }, - "Microsoft.AspNetCore.Server.IISIntegration.Tools": { - "version": "1.0.0-preview1-final", - "imports": "portable-net45+win8+dnxcore50" - }, - "Microsoft.EntityFrameworkCore.Tools": { - "version": "1.0.0-preview1-final", - "imports": [ - "portable-net45+win8+dnxcore50", - "portable-net45+win8" - ] - }, - "Microsoft.Extensions.SecretManager.Tools": { - "version": "1.0.0-preview1-final", - "imports": "portable-net45+win8+dnxcore50" - }, + "BundlerMinifier.Core": "2.0.238", + "Microsoft.AspNetCore.Razor.Tools": "1.0.0-preview2-final", + "Microsoft.AspNetCore.Server.IISIntegration.Tools": "1.0.0-preview2-final", + "Microsoft.EntityFrameworkCore.Tools": "1.0.0-preview2-final", + "Microsoft.Extensions.SecretManager.Tools": "1.0.0-preview2-final", "Microsoft.VisualStudio.Web.CodeGeneration.Tools": { - "version": "1.0.0-preview1-final", + "version": "1.0.0-preview2-final", "imports": [ - "portable-net45+win8+dnxcore50", "portable-net45+win8" ] } @@ -79,7 +69,6 @@ "netcoreapp1.0": { "imports": [ "dotnet5.6", - "dnxcore50", "portable-net45+win8" ] } @@ -91,20 +80,23 @@ }, "runtimeOptions": { - "gcServer": true + "configProperties": { + "System.GC.Server": true + } }, "publishOptions": { "include": [ "wwwroot", "Views", + "Areas/**/Views", "appsettings.json", "web.config" ] }, "scripts": { - "prepublish": [ "npm install", "bower install", "gulp clean", "gulp min" ], + "prepublish": [ "bower install", "dotnet bundle" ], "postpublish": [ "dotnet publish-iis --publish-folder %publish:OutputPath% --framework %publish:FullTargetFramework%" ] } } diff --git a/README.md b/README.md index ea84f2f..2b8b326 100644 --- a/README.md +++ b/README.md @@ -118,9 +118,7 @@ HackerSpray will then maintain success and failure counters. If there are too many success or failed attempt as per the configuration, it will block further execution of the code inside the delegate, thus protecting your expensive business logic from attacks. -# This is so wrong! - -"This is absolutely wrong approach! Why on earth will you do this at the webserver level? This should be done at firewall level!", you say? +# Why not use a firewall? Couple of reasons: @@ -132,23 +130,100 @@ Couple of reasons: With that being said, you should use Firewall for certain cases and Hacker Spray for different cases. You should use Firewall to limit maximum number of connections per IP, maximum number of connections opened to a webserver, rate limit, blacklisted IP and URLs. More than that, go for HackerSpray. It is better to perform CPU intensive operations at webserver level, because you have plenty of them. Usually you have only one active firewall and thus best not to put CPU intensive operation on them. +# Getting Started +### .NET 4 -# Getting Started -## Nuget Get the Hacker Spray library and HTTP Module to defend your website using: Install-Package HackerSpray +It will do all the configuration to enable HackerSpray for your web project. + +### .NET core For .NET Core, use: Install-Package HackerSprayCore -Or you can just drop the Hacker.XXX.dll files in the bin folder and proceed with the configuration. +It will do *nothing* to enable HackerSpray for your web project. You need to do the following: + +Step 1: Add hackerspray.json in the configuration + +``` +{ + "HackerSpray": { + "Redis": "127.0.0.1", + "Prefix": "AuthTest-Core:", + "Keys": [ + "POST /Account/Login 100 00:10:00 key+origin", + "GET /Account/Login 100 00:10:00 key+origin", + "GET /Home/ 10000 00:10:00 key+origin" + ] + } +} +``` + +On your Startup.cs, load this config file: + +``` +var builder = new ConfigurationBuilder() + .SetBasePath(env.ContentRootPath) + .AddJsonFile("appsettings.json", optional: true, reloadOnChange: true) +Add this line--> .AddJsonFile("hackerspray.json", optional: true, reloadOnChange: true) + .AddJsonFile($"appsettings.{env.EnvironmentName}.json", optional: true); +``` + +Step 2: Add the Hacker Spray service in Startup.cs + +``` +public void ConfigureServices(IServiceCollection services) +{ + + . + . + services.AddHackerSpray(Configuration.GetSection("HackerSpray")); +} +``` + -## Using Hacker Spray -### Step 1 -In the ``web.config`` you need to specify which paths to protect using the ``HttpModule``, if you are planning to use the HttpModule. +Step 3: Add HackerSpray middleware in Startup.service + +Add app.UseXForwardedFor(); and app.UseHackerSpray(); right after UseStaticFiles() and before UseMvc(); + +``` +public void Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory) +{ + . + . + . + + app.UseStaticFiles(); + + app.UseXForwardedFor(); + app.UseHackerSpray(); + + . + . + . + + app.UseMvc(routes => + { + routes.MapRoute( + name: "default", + template: "{controller=Home}/{action=Index}/{id?}"); + }); + +} +``` + + +## Run Redis server + +If you have installed from Nuget, redis will be downloaded and stored in ``packages`` folder. + +# Configuring HackerSpray + +In the ``web.config`` or ``hackerspray.json`` you need to specify which paths to protect using the ``HttpModule`` or ``Middleware``: ```xml @@ -171,26 +246,11 @@ In the ``web.config`` you need to specify which paths to protect using the ``Htt - _perorigin_ - While checking hits to this key, if the origin IP has produced more than the maxAttempts hit overall on any key, then block. For ex, allow 1000 hits per IP, to any key, but do this check on Login page hit. - _perkeyorigin_ - Count hits to this key, per IP. For example, 1000 hits per IP on the Login page. -### Step 2 -Add the Hacker Spray ``HttpModule`` in web.config: - -```c# - - - - - - -``` - -### Step 3 Run a [Redis](http://redis.io/) node or a [cluster](http://redis.io/topics/cluster-tutorial) of Redis nodes. Provide the redis connection string in IP:host form in the web.config. If you are running multiple nodes in the cluster, provide IP:host for all nodes. That's all! -### Step 4 - **Warning!** If you have a Load Balancer, then you need to configure the Load Balancer to send the original Client's IP as the Request IP to the webserver. Or it must pass the original Client IP in a ``X-Forwarded-For`` header. **This is very important**. Hacker Spray maintains its counters using the Client IP. If the Client IP is the Load Balancer's IP, not the original Client's IP, then it will lock out the load balancer, causing total outage on your website. @@ -296,4 +356,9 @@ Look for ``Defend End``. You can see how long the .NET Core Middleware has taken - Make sure the HttpModule (.net 4) or the Middleware (.net core) has been properly registered. The Middleware must be registered right after ``app.UseStaticFiles`` and before ``app.UseMvc``. - For .net core, see the sample project's Startup.cs how to proper register it. It is very important you register the middleware right after StaticFile handler. - - Ensure you haven't set the numbers too high in configuration. \ No newline at end of file + - Ensure you haven't set the numbers too high in configuration. + + +### HackerSpray is blocking all requests + + - If you have a load balancer, make sure it is generating X-Forwarded-For header containing the original Client IP. Otherwise HackerSpray sees the load balancer as the client and blocks it. \ No newline at end of file diff --git a/nuget/net45/web.config.transform b/nuget/net45/web.config.transform index 9b4df95..e7ed00e 100644 --- a/nuget/net45/web.config.transform +++ b/nuget/net45/web.config.transform @@ -1,9 +1,11 @@ +
+ @@ -19,6 +21,7 @@ + @@ -28,10 +31,12 @@ + + \ No newline at end of file diff --git a/nuget/netcore/HackerSprayCore.nuspec b/nuget/netcore/HackerSprayCore.nuspec new file mode 100644 index 0000000..bbc6e86 --- /dev/null +++ b/nuget/netcore/HackerSprayCore.nuspec @@ -0,0 +1,145 @@ + + + + HackerSprayCore + 1.0.25-alpha + HackerSpray .NET Core + Omar AL Zabir + https://github.com/oazabir/HackerSpray + https://github.com/oazabir/HackerSpray + false + A .NET Core library to defend websites and web APIs against brute force and Denial-of-service attacks. + +.NET 4 version also available. + +Features: + + * Protect login, registration, password reset pages against brute force and DOS attacks. + * Block users from performing any action too many times. + * Prevent too many hits from any IP or IP Range. + * Blacklist/Whitelist specific IP, IP range, username, URLs, transactions for a period. + +An example scenario is a Bank Login page, where brute force password attempts on user accounts and DOS attack on Login page are a regular event. +Using this library, you can protect login page from brute force attacks, blocking too many usernames from certain IPs, +or too many hits from a range of IP trying to do DOS attack, +or even simple 3 invalid login attempts per username, per 15 mins. + +This high performance, very lightweight library protects you from hitting the database too many times on pages and APIs that are prone to attacks, thus lowering web server and database CPU, increasing the scalability of the overall application. + +Example code: + +var result = await Hacker.DefendAsync("/Account/LogOn", Request.UserHostAddress); +if (result == Hacker.Result.TooManyHitsFromOrigin) + await Hacker.BlacklistOriginAsync(Request.UserHostAddress, TimeSpan.FromMinutes(10)); +else if (result == Hacker.Result.TooManyHitsOnKey) + await Hacker.BlacklistKeyAsync("/Account/LogOn", TimeSpan.FromMinutes(10)); + +. +. +. +Hacker.DefendAsync("/Account/PasswordReset", Request.UserHostAddress, TimeSpan.FromMinutes(5), 100); +Hacker.DefendAsync("Username" + username, Request.UserHostAddress); +Hacker.DefendAsync("Comment", Request.UserHostAddress); + + + +# Getting started with HackerSpray + +## Step 1: Add hackerspray.json in the configuration + +{ + "HackerSpray": { + "Redis": "127.0.0.1", + "Prefix": "AuthTest-Core:", + "Keys": [ + "POST /Account/Login 100 00:10:00 key+origin", + "GET /Account/Login 100 00:10:00 key+origin", + "GET /Home/ 10000 00:10:00 key+origin" + ] + } +} + +On your Startup.cs, load this config file: + +var builder = new ConfigurationBuilder() + .SetBasePath(env.ContentRootPath) + .AddJsonFile("appsettings.json", optional: true, reloadOnChange: true) +Add this line--> .AddJsonFile("hackerspray.json", optional: true, reloadOnChange: true) + .AddJsonFile($"appsettings.{env.EnvironmentName}.json", optional: true); + + +## Step 2: Add the Hacker Spray service in Startup.cs + +public void ConfigureServices(IServiceCollection services) +{ + . + . + . + . + services.AddHackerSpray(Configuration.GetSection("HackerSpray")); +} + + +## Step 3: Add HackerSpray middleware in Startup.service + +Add app.UseXForwardedFor(); and app.UseHackerSpray(); right after UseStaticFiles() and before UseMvc(); + +public void Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory) +{ + . + . + . + + app.UseStaticFiles(); + + app.UseXForwardedFor(); + app.UseHackerSpray(); + + . + . + . + + app.UseMvc(routes => + { + routes.MapRoute( + name: "default", + template: "{controller=Home}/{action=Index}/{id?}"); + }); + +} + +## Step 4: Configure hackerspray.json + +{ + "HackerSpray": { + "Redis": "127.0.0.1", + "Prefix": "AuthTest-Core:", + "Keys": [ + "POST /Account/Login 100 00:10:00 key+origin", + "GET /Account/Login 100 00:10:00 key+origin", + "GET /Home/ 10000 00:10:00 key+origin" + ] + } +} + + + A .NET Core library to protect websites from brute force and DOS attacks + Copyright © Omar AL Zabir 2016 + asp.net, hacker, brute force, DOS + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/nuget/netcore/contentFiles/any/any/hackerspray.json b/nuget/netcore/contentFiles/any/any/hackerspray.json new file mode 100644 index 0000000..434c990 --- /dev/null +++ b/nuget/netcore/contentFiles/any/any/hackerspray.json @@ -0,0 +1,11 @@ +{ + "HackerSpray": { + "Redis": "127.0.0.1", + "Prefix": "AuthTest-Core:", + "Keys": [ + "POST /Account/Login 100 00:10:00 key+origin", + "GET /Account/Login 100 00:10:00 key+origin", + "GET /Home/ 10000 00:10:00 key+origin" + ] + } +} diff --git a/nuget/netcore/contentFiles/any/any/readme.txt b/nuget/netcore/contentFiles/any/any/readme.txt new file mode 100644 index 0000000..e2778e8 --- /dev/null +++ b/nuget/netcore/contentFiles/any/any/readme.txt @@ -0,0 +1,66 @@ +# Getting started with HackerSpray + +## Step 1: Add hackerspray.json in the configuration + +On your Startup.cs: + +var builder = new ConfigurationBuilder() + .SetBasePath(env.ContentRootPath) + .AddJsonFile("appsettings.json", optional: true, reloadOnChange: true) +Add this line--> .AddJsonFile("hackerspray.json", optional: true, reloadOnChange: true) + .AddJsonFile($"appsettings.{env.EnvironmentName}.json", optional: true); + + +## Step 2: Add the Hacker Spray service in Startup.cs + +public void ConfigureServices(IServiceCollection services) +{ + . + . + . + . + services.AddHackerSpray(Configuration.GetSection("HackerSpray")); +} + + +## Step 3: Add HackerSpray middleware in Startup.service + +Add app.UseXForwardedFor(); and app.UseHackerSpray(); right after UseStaticFiles() and before UseMvc(); + +public void Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory) +{ + . + . + . + + app.UseStaticFiles(); + + app.UseXForwardedFor(); + app.UseHackerSpray(); + + . + . + . + + app.UseMvc(routes => + { + routes.MapRoute( + name: "default", + template: "{controller=Home}/{action=Index}/{id?}"); + }); + +} + +## Step 4: Configure hackerspray.json + +{ + "HackerSpray": { + "Redis": "127.0.0.1", + "Prefix": "AuthTest-Core:", + "Keys": [ + "POST /Account/Login 100 00:10:00 key+origin", + "GET /Account/Login 100 00:10:00 key+origin", + "GET /Home/ 10000 00:10:00 key+origin" + ] + } +} \ No newline at end of file diff --git a/nuget/netcore/lib/netstandard1.6/HackerSpray.Middleware.deps.json b/nuget/netcore/lib/netstandard1.6/HackerSpray.Middleware.deps.json new file mode 100644 index 0000000..ca862a0 --- /dev/null +++ b/nuget/netcore/lib/netstandard1.6/HackerSpray.Middleware.deps.json @@ -0,0 +1,1442 @@ +{ + "runtimeTarget": { + "name": ".NETStandard,Version=v1.6/", + "signature": "234b50be2bc195c8105532dc038c632913c6b2c4" + }, + "compilationOptions": {}, + "targets": { + ".NETStandard,Version=v1.6": {}, + ".NETStandard,Version=v1.6/": { + "HackerSpray.Middleware/1.0.0": { + "dependencies": { + "HackerSpray.Module": "1.0.0", + "Microsoft.AspNetCore.Http.Abstractions": "1.0.0", + "Microsoft.Extensions.Configuration.Abstractions": "1.0.0", + "Microsoft.Extensions.Logging.Abstractions": "1.0.0", + "Microsoft.Extensions.Options": "1.0.0", + "NETStandard.Library": "1.6.0" + }, + "runtime": { + "HackerSpray.Middleware.dll": {} + } + }, + "Microsoft.AspNetCore.Http.Abstractions/1.0.0": { + "dependencies": { + "Microsoft.AspNetCore.Http.Features": "1.0.0", + "System.Globalization.Extensions": "4.0.1", + "System.Linq.Expressions": "4.1.0", + "System.Reflection.TypeExtensions": "4.1.0", + "System.Runtime.InteropServices": "4.1.0", + "System.Text.Encodings.Web": "4.0.0" + }, + "runtime": { + "lib/netstandard1.3/Microsoft.AspNetCore.Http.Abstractions.dll": {} + } + }, + "Microsoft.AspNetCore.Http.Features/1.0.0": { + "dependencies": { + "Microsoft.Extensions.Primitives": "1.0.0", + "System.Collections": "4.0.11", + "System.ComponentModel": "4.0.1", + "System.Linq": "4.1.0", + "System.Net.Primitives": "4.0.11", + "System.Net.WebSockets": "4.0.0", + "System.Runtime.Extensions": "4.1.0", + "System.Security.Claims": "4.0.1", + "System.Security.Cryptography.X509Certificates": "4.1.0", + "System.Security.Principal": "4.0.1" + }, + "runtime": { + "lib/netstandard1.3/Microsoft.AspNetCore.Http.Features.dll": {} + } + }, + "Microsoft.Extensions.Configuration.Abstractions/1.0.0": { + "dependencies": { + "Microsoft.Extensions.Primitives": "1.0.0", + "System.Linq": "4.1.0" + }, + "runtime": { + "lib/netstandard1.0/Microsoft.Extensions.Configuration.Abstractions.dll": {} + } + }, + "Microsoft.Extensions.DependencyInjection.Abstractions/1.0.0": { + "dependencies": { + "System.ComponentModel": "4.0.1", + "System.Diagnostics.Debug": "4.0.11", + "System.Globalization": "4.0.11", + "System.Linq": "4.1.0", + "System.Linq.Expressions": "4.1.0", + "System.Reflection": "4.1.0", + "System.Resources.ResourceManager": "4.0.1" + }, + "runtime": { + "lib/netstandard1.0/Microsoft.Extensions.DependencyInjection.Abstractions.dll": {} + } + }, + "Microsoft.Extensions.Logging.Abstractions/1.0.0": { + "dependencies": { + "System.Collections": "4.0.11", + "System.Collections.Concurrent": "4.0.12", + "System.Diagnostics.Debug": "4.0.11", + "System.Globalization": "4.0.11", + "System.Linq": "4.1.0", + "System.Reflection": "4.1.0", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime.Extensions": "4.1.0", + "System.Runtime.InteropServices": "4.1.0" + }, + "runtime": { + "lib/netstandard1.1/Microsoft.Extensions.Logging.Abstractions.dll": {} + } + }, + "Microsoft.Extensions.Options/1.0.0": { + "dependencies": { + "Microsoft.Extensions.DependencyInjection.Abstractions": "1.0.0", + "Microsoft.Extensions.Primitives": "1.0.0", + "System.ComponentModel": "4.0.1", + "System.Diagnostics.Debug": "4.0.11", + "System.Globalization": "4.0.11", + "System.Linq": "4.1.0", + "System.Linq.Expressions": "4.1.0", + "System.Reflection": "4.1.0", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime.Extensions": "4.1.0", + "System.Threading": "4.0.11" + }, + "runtime": { + "lib/netstandard1.0/Microsoft.Extensions.Options.dll": {} + } + }, + "Microsoft.Extensions.Primitives/1.0.0": { + "dependencies": { + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0" + }, + "runtime": { + "lib/netstandard1.0/Microsoft.Extensions.Primitives.dll": {} + } + }, + "Microsoft.NETCore.Platforms/1.0.1": {}, + "Microsoft.NETCore.Targets/1.0.1": {}, + "Microsoft.Win32.Primitives/4.0.1": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.Runtime": "4.1.0" + } + }, + "NETStandard.Library/1.6.0": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.Win32.Primitives": "4.0.1", + "System.AppContext": "4.1.0", + "System.Collections": "4.0.11", + "System.Collections.Concurrent": "4.0.12", + "System.Console": "4.0.0", + "System.Diagnostics.Debug": "4.0.11", + "System.Diagnostics.Tools": "4.0.1", + "System.Diagnostics.Tracing": "4.1.0", + "System.Globalization": "4.0.11", + "System.Globalization.Calendars": "4.0.1", + "System.IO": "4.1.0", + "System.IO.Compression": "4.1.0", + "System.IO.Compression.ZipFile": "4.0.1", + "System.IO.FileSystem": "4.0.1", + "System.IO.FileSystem.Primitives": "4.0.1", + "System.Linq": "4.1.0", + "System.Linq.Expressions": "4.1.0", + "System.Net.Http": "4.1.0", + "System.Net.Primitives": "4.0.11", + "System.Net.Sockets": "4.1.0", + "System.ObjectModel": "4.0.12", + "System.Reflection": "4.1.0", + "System.Reflection.Extensions": "4.0.1", + "System.Reflection.Primitives": "4.0.1", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Runtime.Handles": "4.0.1", + "System.Runtime.InteropServices": "4.1.0", + "System.Runtime.InteropServices.RuntimeInformation": "4.0.0", + "System.Runtime.Numerics": "4.0.1", + "System.Security.Cryptography.Algorithms": "4.2.0", + "System.Security.Cryptography.Encoding": "4.0.0", + "System.Security.Cryptography.Primitives": "4.0.0", + "System.Security.Cryptography.X509Certificates": "4.1.0", + "System.Text.Encoding": "4.0.11", + "System.Text.Encoding.Extensions": "4.0.11", + "System.Text.RegularExpressions": "4.1.0", + "System.Threading": "4.0.11", + "System.Threading.Tasks": "4.0.11", + "System.Threading.Timer": "4.0.1", + "System.Xml.ReaderWriter": "4.0.11", + "System.Xml.XDocument": "4.0.11" + } + }, + "runtime.native.System/4.0.0": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1" + } + }, + "runtime.native.System.IO.Compression/4.1.0": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1" + } + }, + "runtime.native.System.Net.Http/4.0.1": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1" + } + }, + "runtime.native.System.Net.Security/4.0.1-rc2-24027": {}, + "runtime.native.System.Security.Cryptography/4.0.0": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1" + } + }, + "StackExchange.Redis/1.1.604-alpha": { + "dependencies": { + "NETStandard.Library": "1.6.0", + "System.Collections.NonGeneric": "4.0.1-rc2-24027", + "System.IO.FileSystem": "4.0.1", + "System.Net.NameResolution": "4.0.0-rc2-24027", + "System.Net.Security": "4.0.0-rc2-24027", + "System.Net.Sockets": "4.1.0", + "System.Reflection.Emit": "4.0.1", + "System.Reflection.Emit.Lightweight": "4.0.1", + "System.Reflection.TypeExtensions": "4.1.0", + "System.Security.Cryptography.Algorithms": "4.2.0", + "System.Security.Cryptography.X509Certificates": "4.1.0", + "System.Threading.Thread": "4.0.0-rc2-24027", + "System.Threading.ThreadPool": "4.0.10-rc2-24027", + "System.Threading.Timer": "4.0.1" + }, + "runtime": { + "lib/netstandard1.5/StackExchange.Redis.dll": {} + } + }, + "System.AppContext/4.1.0": { + "dependencies": { + "System.Runtime": "4.1.0" + }, + "runtime": { + "lib/netstandard1.6/System.AppContext.dll": {} + } + }, + "System.Buffers/4.0.0": { + "dependencies": { + "System.Diagnostics.Debug": "4.0.11", + "System.Diagnostics.Tracing": "4.1.0", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Threading": "4.0.11" + }, + "runtime": { + "lib/netstandard1.1/System.Buffers.dll": {} + } + }, + "System.Collections/4.0.11": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.Runtime": "4.1.0" + } + }, + "System.Collections.Concurrent/4.0.12": { + "dependencies": { + "System.Collections": "4.0.11", + "System.Diagnostics.Debug": "4.0.11", + "System.Diagnostics.Tracing": "4.1.0", + "System.Globalization": "4.0.11", + "System.Reflection": "4.1.0", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Threading": "4.0.11", + "System.Threading.Tasks": "4.0.11" + }, + "runtime": { + "lib/netstandard1.3/System.Collections.Concurrent.dll": {} + } + }, + "System.Collections.NonGeneric/4.0.1-rc2-24027": { + "dependencies": { + "System.Diagnostics.Debug": "4.0.11", + "System.Globalization": "4.0.11", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Threading": "4.0.11" + }, + "runtime": { + "lib/netstandard1.3/System.Collections.NonGeneric.dll": {} + } + }, + "System.ComponentModel/4.0.1": { + "dependencies": { + "System.Runtime": "4.1.0" + }, + "runtime": { + "lib/netstandard1.3/System.ComponentModel.dll": {} + } + }, + "System.Console/4.0.0": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.IO": "4.1.0", + "System.Runtime": "4.1.0", + "System.Text.Encoding": "4.0.11" + } + }, + "System.Diagnostics.Debug/4.0.11": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.Runtime": "4.1.0" + } + }, + "System.Diagnostics.DiagnosticSource/4.0.0": { + "dependencies": { + "System.Collections": "4.0.11", + "System.Diagnostics.Tracing": "4.1.0", + "System.Reflection": "4.1.0", + "System.Runtime": "4.1.0", + "System.Threading": "4.0.11" + }, + "runtime": { + "lib/netstandard1.3/System.Diagnostics.DiagnosticSource.dll": {} + } + }, + "System.Diagnostics.Tools/4.0.1": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.Runtime": "4.1.0" + } + }, + "System.Diagnostics.TraceSource/4.0.0-rc2-24027": { + "dependencies": { + "System.Collections": "4.0.11", + "System.Diagnostics.Debug": "4.0.11", + "System.Globalization": "4.0.11", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Threading": "4.0.11" + } + }, + "System.Diagnostics.Tracing/4.1.0": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.Runtime": "4.1.0" + } + }, + "System.Globalization/4.0.11": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.Runtime": "4.1.0" + } + }, + "System.Globalization.Calendars/4.0.1": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.Globalization": "4.0.11", + "System.Runtime": "4.1.0" + } + }, + "System.Globalization.Extensions/4.0.1": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "System.Globalization": "4.0.11", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Runtime.InteropServices": "4.1.0" + } + }, + "System.IO/4.1.0": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.Runtime": "4.1.0", + "System.Text.Encoding": "4.0.11", + "System.Threading.Tasks": "4.0.11" + } + }, + "System.IO.Compression/4.1.0": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "System.Collections": "4.0.11", + "System.Diagnostics.Debug": "4.0.11", + "System.IO": "4.1.0", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Runtime.Handles": "4.0.1", + "System.Runtime.InteropServices": "4.1.0", + "System.Text.Encoding": "4.0.11", + "System.Threading": "4.0.11", + "System.Threading.Tasks": "4.0.11", + "runtime.native.System": "4.0.0", + "runtime.native.System.IO.Compression": "4.1.0" + } + }, + "System.IO.Compression.ZipFile/4.0.1": { + "dependencies": { + "System.Buffers": "4.0.0", + "System.IO": "4.1.0", + "System.IO.Compression": "4.1.0", + "System.IO.FileSystem": "4.0.1", + "System.IO.FileSystem.Primitives": "4.0.1", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Text.Encoding": "4.0.11" + }, + "runtime": { + "lib/netstandard1.3/System.IO.Compression.ZipFile.dll": {} + } + }, + "System.IO.FileSystem/4.0.1": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.IO": "4.1.0", + "System.IO.FileSystem.Primitives": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Handles": "4.0.1", + "System.Text.Encoding": "4.0.11", + "System.Threading.Tasks": "4.0.11" + } + }, + "System.IO.FileSystem.Primitives/4.0.1": { + "dependencies": { + "System.Runtime": "4.1.0" + }, + "runtime": { + "lib/netstandard1.3/System.IO.FileSystem.Primitives.dll": {} + } + }, + "System.Linq/4.1.0": { + "dependencies": { + "System.Collections": "4.0.11", + "System.Diagnostics.Debug": "4.0.11", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0" + }, + "runtime": { + "lib/netstandard1.6/System.Linq.dll": {} + } + }, + "System.Linq.Expressions/4.1.0": { + "dependencies": { + "System.Collections": "4.0.11", + "System.Diagnostics.Debug": "4.0.11", + "System.Globalization": "4.0.11", + "System.IO": "4.1.0", + "System.Linq": "4.1.0", + "System.ObjectModel": "4.0.12", + "System.Reflection": "4.1.0", + "System.Reflection.Emit": "4.0.1", + "System.Reflection.Emit.ILGeneration": "4.0.1", + "System.Reflection.Emit.Lightweight": "4.0.1", + "System.Reflection.Extensions": "4.0.1", + "System.Reflection.Primitives": "4.0.1", + "System.Reflection.TypeExtensions": "4.1.0", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Threading": "4.0.11" + }, + "runtime": { + "lib/netstandard1.6/System.Linq.Expressions.dll": {} + } + }, + "System.Net.Http/4.1.0": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "System.Collections": "4.0.11", + "System.Diagnostics.Debug": "4.0.11", + "System.Diagnostics.DiagnosticSource": "4.0.0", + "System.Diagnostics.Tracing": "4.1.0", + "System.Globalization": "4.0.11", + "System.Globalization.Extensions": "4.0.1", + "System.IO": "4.1.0", + "System.IO.FileSystem": "4.0.1", + "System.Net.Primitives": "4.0.11", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Runtime.Handles": "4.0.1", + "System.Runtime.InteropServices": "4.1.0", + "System.Security.Cryptography.Algorithms": "4.2.0", + "System.Security.Cryptography.Encoding": "4.0.0", + "System.Security.Cryptography.OpenSsl": "4.0.0", + "System.Security.Cryptography.Primitives": "4.0.0", + "System.Security.Cryptography.X509Certificates": "4.1.0", + "System.Text.Encoding": "4.0.11", + "System.Threading": "4.0.11", + "System.Threading.Tasks": "4.0.11", + "runtime.native.System": "4.0.0", + "runtime.native.System.Net.Http": "4.0.1", + "runtime.native.System.Security.Cryptography": "4.0.0" + } + }, + "System.Net.NameResolution/4.0.0-rc2-24027": { + "dependencies": { + "System.Collections": "4.0.11", + "System.Diagnostics.Tracing": "4.1.0", + "System.Globalization": "4.0.11", + "System.Net.Primitives": "4.0.11", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Runtime.Handles": "4.0.1", + "System.Runtime.InteropServices": "4.1.0", + "System.Security.Principal.Windows": "4.0.0-rc2-24027", + "System.Threading": "4.0.11", + "System.Threading.Tasks": "4.0.11" + } + }, + "System.Net.Primitives/4.0.11": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Handles": "4.0.1" + } + }, + "System.Net.Security/4.0.0-rc2-24027": { + "dependencies": { + "Microsoft.Win32.Primitives": "4.0.1", + "System.Collections": "4.0.11", + "System.Collections.Concurrent": "4.0.12", + "System.Diagnostics.Tracing": "4.1.0", + "System.Globalization": "4.0.11", + "System.Globalization.Extensions": "4.0.1", + "System.IO": "4.1.0", + "System.Net.Primitives": "4.0.11", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Runtime.Handles": "4.0.1", + "System.Runtime.InteropServices": "4.1.0", + "System.Security.Claims": "4.0.1", + "System.Security.Cryptography.Algorithms": "4.2.0", + "System.Security.Cryptography.Encoding": "4.0.0", + "System.Security.Cryptography.OpenSsl": "4.0.0", + "System.Security.Cryptography.Primitives": "4.0.0", + "System.Security.Cryptography.X509Certificates": "4.1.0", + "System.Security.Principal": "4.0.1", + "System.Text.Encoding": "4.0.11", + "System.Threading": "4.0.11", + "System.Threading.Tasks": "4.0.11", + "System.Threading.ThreadPool": "4.0.10-rc2-24027", + "runtime.native.System.Net.Security": "4.0.1-rc2-24027" + } + }, + "System.Net.Sockets/4.1.0": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.IO": "4.1.0", + "System.Net.Primitives": "4.0.11", + "System.Runtime": "4.1.0", + "System.Threading.Tasks": "4.0.11" + } + }, + "System.Net.WebSockets/4.0.0": { + "dependencies": { + "Microsoft.Win32.Primitives": "4.0.1", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Threading.Tasks": "4.0.11" + }, + "runtime": { + "lib/netstandard1.3/System.Net.WebSockets.dll": {} + } + }, + "System.ObjectModel/4.0.12": { + "dependencies": { + "System.Collections": "4.0.11", + "System.Diagnostics.Debug": "4.0.11", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Threading": "4.0.11" + }, + "runtime": { + "lib/netstandard1.3/System.ObjectModel.dll": {} + } + }, + "System.Reflection/4.1.0": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.IO": "4.1.0", + "System.Reflection.Primitives": "4.0.1", + "System.Runtime": "4.1.0" + } + }, + "System.Reflection.Emit/4.0.1": { + "dependencies": { + "System.IO": "4.1.0", + "System.Reflection": "4.1.0", + "System.Reflection.Emit.ILGeneration": "4.0.1", + "System.Reflection.Primitives": "4.0.1", + "System.Runtime": "4.1.0" + }, + "runtime": { + "lib/netstandard1.3/System.Reflection.Emit.dll": {} + } + }, + "System.Reflection.Emit.ILGeneration/4.0.1": { + "dependencies": { + "System.Reflection": "4.1.0", + "System.Reflection.Primitives": "4.0.1", + "System.Runtime": "4.1.0" + }, + "runtime": { + "lib/netstandard1.3/System.Reflection.Emit.ILGeneration.dll": {} + } + }, + "System.Reflection.Emit.Lightweight/4.0.1": { + "dependencies": { + "System.Reflection": "4.1.0", + "System.Reflection.Emit.ILGeneration": "4.0.1", + "System.Reflection.Primitives": "4.0.1", + "System.Runtime": "4.1.0" + }, + "runtime": { + "lib/netstandard1.3/System.Reflection.Emit.Lightweight.dll": {} + } + }, + "System.Reflection.Extensions/4.0.1": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.Reflection": "4.1.0", + "System.Runtime": "4.1.0" + } + }, + "System.Reflection.Primitives/4.0.1": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.Runtime": "4.1.0" + } + }, + "System.Reflection.TypeExtensions/4.1.0": { + "dependencies": { + "System.Reflection": "4.1.0", + "System.Runtime": "4.1.0" + }, + "runtime": { + "lib/netstandard1.5/System.Reflection.TypeExtensions.dll": {} + } + }, + "System.Resources.ResourceManager/4.0.1": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.Globalization": "4.0.11", + "System.Reflection": "4.1.0", + "System.Runtime": "4.1.0" + } + }, + "System.Runtime/4.1.0": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1" + } + }, + "System.Runtime.Extensions/4.1.0": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.Runtime": "4.1.0" + } + }, + "System.Runtime.Handles/4.0.1": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.Runtime": "4.1.0" + } + }, + "System.Runtime.InteropServices/4.1.0": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.Reflection": "4.1.0", + "System.Reflection.Primitives": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Handles": "4.0.1" + } + }, + "System.Runtime.InteropServices.RuntimeInformation/4.0.0": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "System.Reflection": "4.1.0", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.InteropServices": "4.1.0", + "System.Threading": "4.0.11", + "runtime.native.System": "4.0.0" + } + }, + "System.Runtime.Numerics/4.0.1": { + "dependencies": { + "System.Globalization": "4.0.11", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0" + }, + "runtime": { + "lib/netstandard1.3/System.Runtime.Numerics.dll": {} + } + }, + "System.Security.Claims/4.0.1": { + "dependencies": { + "System.Collections": "4.0.11", + "System.Globalization": "4.0.11", + "System.IO": "4.1.0", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Security.Principal": "4.0.1" + }, + "runtime": { + "lib/netstandard1.3/System.Security.Claims.dll": {} + } + }, + "System.Security.Cryptography.Algorithms/4.2.0": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "System.Collections": "4.0.11", + "System.IO": "4.1.0", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Runtime.Handles": "4.0.1", + "System.Runtime.InteropServices": "4.1.0", + "System.Runtime.Numerics": "4.0.1", + "System.Security.Cryptography.Encoding": "4.0.0", + "System.Security.Cryptography.Primitives": "4.0.0", + "System.Text.Encoding": "4.0.11", + "runtime.native.System.Security.Cryptography": "4.0.0" + } + }, + "System.Security.Cryptography.Cng/4.2.0": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "System.IO": "4.1.0", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Runtime.Handles": "4.0.1", + "System.Runtime.InteropServices": "4.1.0", + "System.Security.Cryptography.Algorithms": "4.2.0", + "System.Security.Cryptography.Encoding": "4.0.0", + "System.Security.Cryptography.Primitives": "4.0.0", + "System.Text.Encoding": "4.0.11" + } + }, + "System.Security.Cryptography.Csp/4.0.0": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "System.IO": "4.1.0", + "System.Reflection": "4.1.0", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Runtime.Handles": "4.0.1", + "System.Runtime.InteropServices": "4.1.0", + "System.Security.Cryptography.Algorithms": "4.2.0", + "System.Security.Cryptography.Encoding": "4.0.0", + "System.Security.Cryptography.Primitives": "4.0.0", + "System.Text.Encoding": "4.0.11", + "System.Threading": "4.0.11" + } + }, + "System.Security.Cryptography.Encoding/4.0.0": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "System.Collections": "4.0.11", + "System.Collections.Concurrent": "4.0.12", + "System.Linq": "4.1.0", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Runtime.Handles": "4.0.1", + "System.Runtime.InteropServices": "4.1.0", + "System.Security.Cryptography.Primitives": "4.0.0", + "System.Text.Encoding": "4.0.11", + "runtime.native.System.Security.Cryptography": "4.0.0" + } + }, + "System.Security.Cryptography.OpenSsl/4.0.0": { + "dependencies": { + "System.Collections": "4.0.11", + "System.IO": "4.1.0", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Runtime.Handles": "4.0.1", + "System.Runtime.InteropServices": "4.1.0", + "System.Runtime.Numerics": "4.0.1", + "System.Security.Cryptography.Algorithms": "4.2.0", + "System.Security.Cryptography.Encoding": "4.0.0", + "System.Security.Cryptography.Primitives": "4.0.0", + "System.Text.Encoding": "4.0.11", + "runtime.native.System.Security.Cryptography": "4.0.0" + }, + "runtime": { + "lib/netstandard1.6/System.Security.Cryptography.OpenSsl.dll": {} + } + }, + "System.Security.Cryptography.Primitives/4.0.0": { + "dependencies": { + "System.Diagnostics.Debug": "4.0.11", + "System.Globalization": "4.0.11", + "System.IO": "4.1.0", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Threading": "4.0.11", + "System.Threading.Tasks": "4.0.11" + }, + "runtime": { + "lib/netstandard1.3/System.Security.Cryptography.Primitives.dll": {} + } + }, + "System.Security.Cryptography.X509Certificates/4.1.0": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "System.Collections": "4.0.11", + "System.Diagnostics.Debug": "4.0.11", + "System.Globalization": "4.0.11", + "System.Globalization.Calendars": "4.0.1", + "System.IO": "4.1.0", + "System.IO.FileSystem": "4.0.1", + "System.IO.FileSystem.Primitives": "4.0.1", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Runtime.Handles": "4.0.1", + "System.Runtime.InteropServices": "4.1.0", + "System.Runtime.Numerics": "4.0.1", + "System.Security.Cryptography.Algorithms": "4.2.0", + "System.Security.Cryptography.Cng": "4.2.0", + "System.Security.Cryptography.Csp": "4.0.0", + "System.Security.Cryptography.Encoding": "4.0.0", + "System.Security.Cryptography.OpenSsl": "4.0.0", + "System.Security.Cryptography.Primitives": "4.0.0", + "System.Text.Encoding": "4.0.11", + "System.Threading": "4.0.11", + "runtime.native.System": "4.0.0", + "runtime.native.System.Net.Http": "4.0.1", + "runtime.native.System.Security.Cryptography": "4.0.0" + } + }, + "System.Security.Principal/4.0.1": { + "dependencies": { + "System.Runtime": "4.1.0" + }, + "runtime": { + "lib/netstandard1.0/System.Security.Principal.dll": {} + } + }, + "System.Security.Principal.Windows/4.0.0-rc2-24027": { + "dependencies": { + "Microsoft.Win32.Primitives": "4.0.1", + "System.Collections": "4.0.11", + "System.Diagnostics.Debug": "4.0.11", + "System.Reflection": "4.1.0", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Runtime.Handles": "4.0.1", + "System.Runtime.InteropServices": "4.1.0", + "System.Security.Claims": "4.0.1", + "System.Security.Principal": "4.0.1", + "System.Text.Encoding": "4.0.11", + "System.Threading": "4.0.11" + } + }, + "System.Text.Encoding/4.0.11": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.Runtime": "4.1.0" + } + }, + "System.Text.Encoding.Extensions/4.0.11": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.Runtime": "4.1.0", + "System.Text.Encoding": "4.0.11" + } + }, + "System.Text.Encodings.Web/4.0.0": { + "dependencies": { + "System.Diagnostics.Debug": "4.0.11", + "System.IO": "4.1.0", + "System.Reflection": "4.1.0", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Threading": "4.0.11" + }, + "runtime": { + "lib/netstandard1.0/System.Text.Encodings.Web.dll": {} + } + }, + "System.Text.RegularExpressions/4.1.0": { + "dependencies": { + "System.Collections": "4.0.11", + "System.Globalization": "4.0.11", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Threading": "4.0.11" + }, + "runtime": { + "lib/netstandard1.6/System.Text.RegularExpressions.dll": {} + } + }, + "System.Threading/4.0.11": { + "dependencies": { + "System.Runtime": "4.1.0", + "System.Threading.Tasks": "4.0.11" + }, + "runtime": { + "lib/netstandard1.3/System.Threading.dll": {} + } + }, + "System.Threading.Tasks/4.0.11": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.Runtime": "4.1.0" + } + }, + "System.Threading.Tasks.Extensions/4.0.0": { + "dependencies": { + "System.Collections": "4.0.11", + "System.Runtime": "4.1.0", + "System.Threading.Tasks": "4.0.11" + }, + "runtime": { + "lib/netstandard1.0/System.Threading.Tasks.Extensions.dll": {} + } + }, + "System.Threading.Thread/4.0.0-rc2-24027": { + "dependencies": { + "System.Runtime": "4.1.0" + }, + "runtime": { + "lib/netstandard1.3/System.Threading.Thread.dll": {} + } + }, + "System.Threading.ThreadPool/4.0.10-rc2-24027": { + "dependencies": { + "System.Runtime": "4.1.0", + "System.Runtime.Handles": "4.0.1" + }, + "runtime": { + "lib/netstandard1.3/System.Threading.ThreadPool.dll": {} + } + }, + "System.Threading.Timer/4.0.1": { + "dependencies": { + "Microsoft.NETCore.Platforms": "1.0.1", + "Microsoft.NETCore.Targets": "1.0.1", + "System.Runtime": "4.1.0" + } + }, + "System.Xml.ReaderWriter/4.0.11": { + "dependencies": { + "System.Collections": "4.0.11", + "System.Diagnostics.Debug": "4.0.11", + "System.Globalization": "4.0.11", + "System.IO": "4.1.0", + "System.IO.FileSystem": "4.0.1", + "System.IO.FileSystem.Primitives": "4.0.1", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Runtime.InteropServices": "4.1.0", + "System.Text.Encoding": "4.0.11", + "System.Text.Encoding.Extensions": "4.0.11", + "System.Text.RegularExpressions": "4.1.0", + "System.Threading.Tasks": "4.0.11", + "System.Threading.Tasks.Extensions": "4.0.0" + }, + "runtime": { + "lib/netstandard1.3/System.Xml.ReaderWriter.dll": {} + } + }, + "System.Xml.XDocument/4.0.11": { + "dependencies": { + "System.Collections": "4.0.11", + "System.Diagnostics.Debug": "4.0.11", + "System.Diagnostics.Tools": "4.0.1", + "System.Globalization": "4.0.11", + "System.IO": "4.1.0", + "System.Reflection": "4.1.0", + "System.Resources.ResourceManager": "4.0.1", + "System.Runtime": "4.1.0", + "System.Runtime.Extensions": "4.1.0", + "System.Text.Encoding": "4.0.11", + "System.Threading": "4.0.11", + "System.Xml.ReaderWriter": "4.0.11" + }, + "runtime": { + "lib/netstandard1.3/System.Xml.XDocument.dll": {} + } + }, + "HackerSpray.Module/1.0.0": { + "dependencies": { + "Microsoft.Extensions.Logging.Abstractions": "1.0.0", + "NETStandard.Library": "1.6.0", + "StackExchange.Redis": "1.1.604-alpha", + "System.Diagnostics.TraceSource": "4.0.0-rc2-24027" + }, + "runtime": { + "HackerSpray.Module.dll": {} + } + } + } + }, + "libraries": { + "HackerSpray.Middleware/1.0.0": { + "type": "project", + "serviceable": false, + "sha512": "" + }, + "Microsoft.AspNetCore.Http.Abstractions/1.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-OJHlqdJOWKKBfsiVdX4Z4KCNuqvBIu6+1MVKuejRDyHnGyMkNHNoP/dtVzhPqvJXaJg9N4HlD0XNc6GDCFVffg==" + }, + "Microsoft.AspNetCore.Http.Features/1.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-6x7zgfbTo1gL9xMEb7EMO2ES/48bqwnWyfH09z+ubWhnzxdhHls8rtqstPylu5FPD9nid6Vo2pgDm5vufRAy5Q==" + }, + "Microsoft.Extensions.Configuration.Abstractions/1.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-nJ+Et/rnDMDmGhxvFAKdN3va7y+YDPICv1nUEP8I4IKgOkWwr/dCZHMqxVhJFrkbW9ux8Kd7erC4mvxfZh0WnA==" + }, + "Microsoft.Extensions.DependencyInjection.Abstractions/1.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-+XwaNo3o9RhLQhUnnOBCaukeRi1X9yYc0Fzye9RlErSflKZdw0VgHtn6rvKo0FTionsW0x8QVULhKH+nkqVjQA==" + }, + "Microsoft.Extensions.Logging.Abstractions/1.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-wHT6oY50q36mAXBRKtFaB7u07WxKC5u2M8fi3PqHOOnHyUo9gD0u1TlCNR8UObHQxKMYwqlgI8TLcErpt29n8A==" + }, + "Microsoft.Extensions.Options/1.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-SdP3yPKF++JTkoa91pBDiE70uQkR/gdXWzOnMPbSj+eOqY1vgY+b8RVl+gh7TrJ2wlCK2QqnQtvCQlPPZRK36w==" + }, + "Microsoft.Extensions.Primitives/1.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-3q2vzfKEDjL6JFkRpk5SFA3zarYsO6+ZYgoucNImrUMzDn0mFbEOL5p9oPoWiypwypbJVVjWTf557bXZ0YFLig==" + }, + "Microsoft.NETCore.Platforms/1.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-2G6OjjJzwBfNOO8myRV/nFrbTw5iA+DEm0N+qUqhrOmaVtn4pC77h38I1jsXGw5VH55+dPfQsqHD0We9sCl9FQ==" + }, + "Microsoft.NETCore.Targets/1.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-rkn+fKobF/cbWfnnfBOQHKVKIOpxMZBvlSHkqDWgBpwGDcLRduvs3D9OLGeV6GWGvVwNlVi2CBbTjuPmtHvyNw==" + }, + "Microsoft.Win32.Primitives/4.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-fQnBHO9DgcmkC9dYSJoBqo6sH1VJwJprUHh8F3hbcRlxiQiBUuTntdk8tUwV490OqC2kQUrinGwZyQHTieuXRA==" + }, + "NETStandard.Library/1.6.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-ypsCvIdCZ4IoYASJHt6tF2fMo7N30NLgV1EbmC+snO490OMl9FvVxmumw14rhReWU3j3g7BYudG6YCrchwHJlA==" + }, + "runtime.native.System/4.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-QfS/nQI7k/BLgmLrw7qm7YBoULEvgWnPI+cYsbfCVFTW8Aj+i8JhccxcFMu1RWms0YZzF+UHguNBK4Qn89e2Sg==" + }, + "runtime.native.System.IO.Compression/4.1.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-Ob7nvnJBox1aaB222zSVZSkf4WrebPG4qFscfK7vmD7P7NxoSxACQLtO7ytWpqXDn2wcd/+45+EAZ7xjaPip8A==" + }, + "runtime.native.System.Net.Http/4.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-Nh0UPZx2Vifh8r+J+H2jxifZUD3sBrmolgiFWJd2yiNrxO0xTa6bAw3YwRn1VOiSen/tUXMS31ttNItCZ6lKuA==" + }, + "runtime.native.System.Net.Security/4.0.1-rc2-24027": { + "type": "package", + "serviceable": true, + "sha512": "sha512-LFbuFstk7gCPPefhVlfvTsnf0GbRSRpzI8yK319/IZakJBQhIEBQEK1aawg29PfAQf7Pqmt8FAUT4tkhhHmH9A==" + }, + "runtime.native.System.Security.Cryptography/4.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-2CQK0jmO6Eu7ZeMgD+LOFbNJSXHFVQbCJJkEyEwowh1SCgYnrn9W9RykMfpeeVGw7h4IBvYikzpGUlmZTUafJw==" + }, + "StackExchange.Redis/1.1.604-alpha": { + "type": "package", + "serviceable": true, + "sha512": "sha512-b4b6Vx0TyCPHiyLLOgP/UyEiKqHc3eKsNrBUg4rlOjumNkqgUT2yF7zhRf3fXMlz+DTp2ohxVQRjNGP1RF3HSA==" + }, + "System.AppContext/4.1.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-3QjO4jNV7PdKkmQAVp9atA+usVnKRwI3Kx1nMwJ93T0LcQfx7pKAYk0nKz5wn1oP5iqlhZuy6RXOFdhr7rDwow==" + }, + "System.Buffers/4.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-msXumHfjjURSkvxUjYuq4N2ghHoRi2VpXcKMA7gK6ujQfU3vGpl+B6ld0ATRg+FZFpRyA6PgEPA+VlIkTeNf2w==" + }, + "System.Collections/4.0.11": { + "type": "package", + "serviceable": true, + "sha512": "sha512-YUJGz6eFKqS0V//mLt25vFGrrCvOnsXjlvFQs+KimpwNxug9x0Pzy4PlFMU3Q2IzqAa9G2L4LsK3+9vCBK7oTg==" + }, + "System.Collections.Concurrent/4.0.12": { + "type": "package", + "serviceable": true, + "sha512": "sha512-2gBcbb3drMLgxlI0fBfxMA31ec6AEyYCHygGse4vxceJan8mRIWeKJ24BFzN7+bi/NFTgdIgufzb94LWO5EERQ==" + }, + "System.Collections.NonGeneric/4.0.1-rc2-24027": { + "type": "package", + "serviceable": true, + "sha512": "sha512-txfwF71o0wY1QkQQqY9svm0+w12fZla/DBNMV1lpcuqzipu854Qg40meH2aPU3qjnHbRvdyM9dglYyE6/RachQ==" + }, + "System.ComponentModel/4.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-oBZFnm7seFiVfugsIyOvQCWobNZs7FzqDV/B7tx20Ep/l3UUFCPDkdTnCNaJZTU27zjeODmy2C/cP60u3D4c9w==" + }, + "System.Console/4.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-qSKUSOIiYA/a0g5XXdxFcUFmv1hNICBD7QZ0QhGYVipPIhvpiydY8VZqr1thmCXvmn8aipMg64zuanB4eotK9A==" + }, + "System.Diagnostics.Debug/4.0.11": { + "type": "package", + "serviceable": true, + "sha512": "sha512-w5U95fVKHY4G8ASs/K5iK3J5LY+/dLFd4vKejsnI/ZhBsWS9hQakfx3Zr7lRWKg4tAw9r4iktyvsTagWkqYCiw==" + }, + "System.Diagnostics.DiagnosticSource/4.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-YKglnq4BMTJxfcr6nuT08g+yJ0UxdePIHxosiLuljuHIUR6t4KhFsyaHOaOc1Ofqp0PUvJ0EmcgiEz6T7vEx3w==" + }, + "System.Diagnostics.Tools/4.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-xBfJ8pnd4C17dWaC9FM6aShzbJcRNMChUMD42I6772KGGrqaFdumwhn9OdM68erj1ueNo3xdQ1EwiFjK5k8p0g==" + }, + "System.Diagnostics.TraceSource/4.0.0-rc2-24027": { + "type": "package", + "serviceable": true, + "sha512": "sha512-qv6TcsC9l4V79sDIiMJzRmQbIXywMHWpHAnkoVhR+lDxeQp9+rutN+rVL/8vvRD5/a4FiX9SV971K4FaKHBv3w==" + }, + "System.Diagnostics.Tracing/4.1.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-vDN1PoMZCkkdNjvZLql592oYJZgS7URcJzJ7bxeBgGtx5UtR5leNm49VmfHGqIffX4FKacHbI3H6UyNSHQknBg==" + }, + "System.Globalization/4.0.11": { + "type": "package", + "serviceable": true, + "sha512": "sha512-B95h0YLEL2oSnwF/XjqSWKnwKOy/01VWkNlsCeMTFJLLabflpGV26nK164eRs5GiaRSBGpOxQ3pKoSnnyZN5pg==" + }, + "System.Globalization.Calendars/4.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-L1c6IqeQ88vuzC1P81JeHmHA8mxq8a18NUBNXnIY/BVb+TCyAaGIFbhpZt60h9FJNmisymoQkHEFSE9Vslja1Q==" + }, + "System.Globalization.Extensions/4.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-KKo23iKeOaIg61SSXwjANN7QYDr/3op3OWGGzDzz7mypx0Za0fZSeG0l6cco8Ntp8YMYkIQcAqlk8yhm5/Uhcg==" + }, + "System.IO/4.1.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-3KlTJceQc3gnGIaHZ7UBZO26SHL1SHE4ddrmiwumFnId+CEHP+O8r386tZKaE6zlk5/mF8vifMBzHj9SaXN+mQ==" + }, + "System.IO.Compression/4.1.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-TjnBS6eztThSzeSib+WyVbLzEdLKUcEHN69VtS3u8aAsSc18FU6xCZlNWWsEd8SKcXAE+y1sOu7VbU8sUeM0sg==" + }, + "System.IO.Compression.ZipFile/4.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-hBQYJzfTbQURF10nLhd+az2NHxsU6MU7AB8RUf4IolBP5lOAm4Luho851xl+CqslmhI5ZH/el8BlngEk4lBkaQ==" + }, + "System.IO.FileSystem/4.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-IBErlVq5jOggAD69bg1t0pJcHaDbJbWNUZTPI96fkYWzwYbN6D9wRHMULLDd9dHsl7C2YsxXL31LMfPI1SWt8w==" + }, + "System.IO.FileSystem.Primitives/4.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-kWkKD203JJKxJeE74p8aF8y4Qc9r9WQx4C0cHzHPrY3fv/L/IhWnyCHaFJ3H1QPOH6A93whlQ2vG5nHlBDvzWQ==" + }, + "System.Linq/4.1.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-bQ0iYFOQI0nuTnt+NQADns6ucV4DUvMdwN6CbkB1yj8i7arTGiTN5eok1kQwdnnNWSDZfIUySQY+J3d5KjWn0g==" + }, + "System.Linq.Expressions/4.1.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-I+y02iqkgmCAyfbqOmSDOgqdZQ5tTj80Akm5BPSS8EeB0VGWdy6X1KCoYe8Pk6pwDoAKZUOdLVxnTJcExiv5zw==" + }, + "System.Net.Http/4.1.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-ULq9g3SOPVuupt+Y3U+A37coXzdNisB1neFCSKzBwo182u0RDddKJF8I5+HfyXqK6OhJPgeoAwWXrbiUXuRDsg==" + }, + "System.Net.NameResolution/4.0.0-rc2-24027": { + "type": "package", + "serviceable": true, + "sha512": "sha512-c5LsVEi57gpr+CgmNKHX/AAS/ydv400yHjm+OM5gqTZ834W/R0M3t/AjdFv+LYBaliAPIUZ/ysBymyyo9ISNFQ==" + }, + "System.Net.Primitives/4.0.11": { + "type": "package", + "serviceable": true, + "sha512": "sha512-hVvfl4405DRjA2408luZekbPhplJK03j2Y2lSfMlny7GHXlkByw1iLnc9mgKW0GdQn73vvMcWrWewAhylXA4Nw==" + }, + "System.Net.Security/4.0.0-rc2-24027": { + "type": "package", + "serviceable": true, + "sha512": "sha512-NDppeK2WgQ1nMar+gz2jvnMl7fgLnhUtI9zd8UKf8Xy3GiXAY3k8IcNkGhFTODBGVcu7OF9ZNjJmieDLMYaRwA==" + }, + "System.Net.Sockets/4.1.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-xAz0N3dAV/aR/9g8r0Y5oEqU1JRsz29F5EGb/WVHmX3jVSLqi2/92M5hTad2aNWovruXrJpJtgZ9fccPMG9uSw==" + }, + "System.Net.WebSockets/4.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-2KJo8hir6Edi9jnMDAMhiJoI691xRBmKcbNpwjrvpIMOCTYOtBpSsSEGBxBDV7PKbasJNaFp1+PZz1D7xS41Hg==" + }, + "System.ObjectModel/4.0.12": { + "type": "package", + "serviceable": true, + "sha512": "sha512-tAgJM1xt3ytyMoW4qn4wIqgJYm7L7TShRZG4+Q4Qsi2PCcj96pXN7nRywS9KkB3p/xDUjc2HSwP9SROyPYDYKQ==" + }, + "System.Reflection/4.1.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-JCKANJ0TI7kzoQzuwB/OoJANy1Lg338B6+JVacPl4TpUwi3cReg3nMLplMq2uqYfHFQpKIlHAUVAJlImZz/4ng==" + }, + "System.Reflection.Emit/4.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-P2wqAj72fFjpP6wb9nSfDqNBMab+2ovzSDzUZK7MVIm54tBJEPr9jWfSjjoTpPwj1LeKcmX3vr0ttyjSSFM47g==" + }, + "System.Reflection.Emit.ILGeneration/4.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-Ov6dU8Bu15Bc7zuqttgHF12J5lwSWyTf1S+FJouUXVMSqImLZzYaQ+vRr1rQ0OZ0HqsrwWl4dsKHELckQkVpgA==" + }, + "System.Reflection.Emit.Lightweight/4.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-sSzHHXueZ5Uh0OLpUQprhr+ZYJrLPA2Cmr4gn0wj9+FftNKXx8RIMKvO9qnjk2ebPYUjZ+F2ulGdPOsvj+MEjA==" + }, + "System.Reflection.Extensions/4.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-GYrtRsZcMuHF3sbmRHfMYpvxZoIN2bQGrYGerUiWLEkqdEUQZhH3TRSaC/oI4wO0II1RKBPlpIa1TOMxIcOOzQ==" + }, + "System.Reflection.Primitives/4.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-4inTox4wTBaDhB7V3mPvp9XlCbeGYWVEM9/fXALd52vNEAVisc1BoVWQPuUuD0Ga//dNbA/WeMy9u9mzLxGTHQ==" + }, + "System.Reflection.TypeExtensions/4.1.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-tsQ/ptQ3H5FYfON8lL4MxRk/8kFyE0A+tGPXmVP967cT/gzLHYxIejIYSxp4JmIeFHVP78g/F2FE1mUUTbDtrg==" + }, + "System.Resources.ResourceManager/4.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-TxwVeUNoTgUOdQ09gfTjvW411MF+w9MBYL7AtNVc+HtBCFlutPLhUCdZjNkjbhj3bNQWMdHboF0KIWEOjJssbA==" + }, + "System.Runtime/4.1.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-v6c/4Yaa9uWsq+JMhnOFewrYkgdNHNG2eMKuNqRn8P733rNXeRCGvV5FkkjBXn2dbVkPXOsO0xjsEeM1q2zC0g==" + }, + "System.Runtime.Extensions/4.1.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-CUOHjTT/vgP0qGW22U4/hDlOqXmcPq5YicBaXdUR2UiUoLwBT+olO6we4DVbq57jeX5uXH2uerVZhf0qGj+sVQ==" + }, + "System.Runtime.Handles/4.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-nCJvEKguXEvk2ymk1gqj625vVnlK3/xdGzx0vOKicQkoquaTBJTP13AIYkocSUwHCLNBwUbXTqTWGDxBTWpt7g==" + }, + "System.Runtime.InteropServices/4.1.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-16eu3kjHS633yYdkjwShDHZLRNMKVi/s0bY8ODiqJ2RfMhDMAwxZaUaWVnZ2P71kr/or+X9o/xFWtNqz8ivieQ==" + }, + "System.Runtime.InteropServices.RuntimeInformation/4.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-hWPhJxc453RCa8Z29O91EmfGeZIHX1ZH2A8L6lYQVSaKzku2DfArSfMEb1/MYYzPQRJZeu0c9dmYeJKxW5Fgng==" + }, + "System.Runtime.Numerics/4.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-+XbKFuzdmLP3d1o9pdHu2nxjNr2OEPqGzKeegPLCUMM71a0t50A/rOcIRmGs9wR7a8KuHX6hYs/7/TymIGLNqg==" + }, + "System.Security.Claims/4.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-4Jlp0OgJLS/Voj1kyFP6MJlIYp3crgfH8kNQk2p7+4JYfc1aAmh9PZyAMMbDhuoolGNtux9HqSOazsioRiDvCw==" + }, + "System.Security.Cryptography.Algorithms/4.2.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-8JQFxbLVdrtIOKMDN38Fn0GWnqYZw/oMlwOUG/qz1jqChvyZlnUmu+0s7wLx7JYua/nAXoESpHA3iw11QFWhXg==" + }, + "System.Security.Cryptography.Cng/4.2.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-cUJ2h+ZvONDe28Szw3st5dOHdjndhJzQ2WObDEXAWRPEQBtVItVoxbXM/OEsTthl3cNn2dk2k0I3y45igCQcLw==" + }, + "System.Security.Cryptography.Csp/4.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-/i1Usuo4PgAqgbPNC0NjbO3jPW//BoBlTpcWFD1EHVbidH21y4c1ap5bbEMSGAXjAShhMH4abi/K8fILrnu4BQ==" + }, + "System.Security.Cryptography.Encoding/4.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-FbKgE5MbxSQMPcSVRgwM6bXN3GtyAh04NkV8E5zKCBE26X0vYW0UtTa2FIgkH33WVqBVxRgxljlVYumWtU+HcQ==" + }, + "System.Security.Cryptography.OpenSsl/4.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-HUG/zNUJwEiLkoURDixzkzZdB5yGA5pQhDP93ArOpDPQMteURIGERRNzzoJlmTreLBWr5lkFSjjMSk8ySEpQMw==" + }, + "System.Security.Cryptography.Primitives/4.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-Wkd7QryWYjkQclX0bngpntW5HSlMzeJU24UaLJQ7YTfI8ydAVAaU2J+HXLLABOVJlKTVvAeL0Aj39VeTe7L+oA==" + }, + "System.Security.Cryptography.X509Certificates/4.1.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-4HEfsQIKAhA1+ApNn729Gi09zh+lYWwyIuViihoMDWp1vQnEkL2ct7mAbhBlLYm+x/L4Rr/pyGge1lIY635e0w==" + }, + "System.Security.Principal/4.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-On+SKhXY5rzxh/S8wlH1Rm0ogBlu7zyHNxeNBiXauNrhHRXAe9EuX8Yl5IOzLPGU5Z4kLWHMvORDOCG8iu9hww==" + }, + "System.Security.Principal.Windows/4.0.0-rc2-24027": { + "type": "package", + "serviceable": true, + "sha512": "sha512-0zK9NALYpgSfw3oADZFPqtqS9JPHPTMT6RtYawKySlGOnElJG5+hhOsLq+ktG6k10Pyvem8/Pu5CrqJEqhLQFQ==" + }, + "System.Text.Encoding/4.0.11": { + "type": "package", + "serviceable": true, + "sha512": "sha512-U3gGeMlDZXxCEiY4DwVLSacg+DFWCvoiX+JThA/rvw37Sqrku7sEFeVBBBMBnfB6FeZHsyDx85HlKL19x0HtZA==" + }, + "System.Text.Encoding.Extensions/4.0.11": { + "type": "package", + "serviceable": true, + "sha512": "sha512-jtbiTDtvfLYgXn8PTfWI+SiBs51rrmO4AAckx4KR6vFK9Wzf6tI8kcRdsYQNwriUeQ1+CtQbM1W4cMbLXnj/OQ==" + }, + "System.Text.Encodings.Web/4.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-TWZnuiJgPDAEEUfobD7njXvSVR2Toz+jvKWds6yL4oSztmKQfnWzucczjzA+6Dv1bktBdY71sZW1YN0X6m9chQ==" + }, + "System.Text.RegularExpressions/4.1.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-i88YCXpRTjCnoSQZtdlHkAOx4KNNik4hMy83n0+Ftlb7jvV6ZiZWMpnEZHhjBp6hQVh8gWd/iKNPzlPF7iyA2g==" + }, + "System.Threading/4.0.11": { + "type": "package", + "serviceable": true, + "sha512": "sha512-N+3xqIcg3VDKyjwwCGaZ9HawG9aC6cSDI+s7ROma310GQo8vilFZa86hqKppwTHleR/G0sfOzhvgnUxWCR/DrQ==" + }, + "System.Threading.Tasks/4.0.11": { + "type": "package", + "serviceable": true, + "sha512": "sha512-k1S4Gc6IGwtHGT8188RSeGaX86Qw/wnrgNLshJvsdNUOPP9etMmo8S07c+UlOAx4K/xLuN9ivA1bD0LVurtIxQ==" + }, + "System.Threading.Tasks.Extensions/4.0.0": { + "type": "package", + "serviceable": true, + "sha512": "sha512-pH4FZDsZQ/WmgJtN4LWYmRdJAEeVkyriSwrv2Teoe5FOU0Yxlb6II6GL8dBPOfRmutHGATduj3ooMt7dJ2+i+w==" + }, + "System.Threading.Thread/4.0.0-rc2-24027": { + "type": "package", + "serviceable": true, + "sha512": "sha512-pb71GbyEOz4LIVFjssvJ+xXRXA7dye0TuRfW/H9ocfyHensQCWZIeo89Z4rEqbK+3/mE3avAsCpBYenwop0hQA==" + }, + "System.Threading.ThreadPool/4.0.10-rc2-24027": { + "type": "package", + "serviceable": true, + "sha512": "sha512-MyuiERgONOnLCD45PQ1rTHYEv6R/2RL1/LxmqJh5/MXYBeh7o8B3VrXlMuxpTZwKg4pbQbLe5uWIueoPwyq8IA==" + }, + "System.Threading.Timer/4.0.1": { + "type": "package", + "serviceable": true, + "sha512": "sha512-saGfUV8uqVW6LeURiqxcGhZ24PzuRNaUBtbhVeuUAvky1naH395A/1nY0P2bWvrw/BreRtIB/EzTDkGBpqCwEw==" + }, + "System.Xml.ReaderWriter/4.0.11": { + "type": "package", + "serviceable": true, + "sha512": "sha512-ZIiLPsf67YZ9zgr31vzrFaYQqxRPX9cVHjtPSnmx4eN6lbS/yEyYNr2vs1doGDEscF0tjCZFsk9yUg1sC9e8tg==" + }, + "System.Xml.XDocument/4.0.11": { + "type": "package", + "serviceable": true, + "sha512": "sha512-Mk2mKmPi0nWaoiYeotq1dgeNK1fqWh61+EK+w4Wu8SWuTYLzpUnschb59bJtGywaPq7SmTuPf44wrXRwbIrukg==" + }, + "HackerSpray.Module/1.0.0": { + "type": "project", + "serviceable": false, + "sha512": "" + } + } +} \ No newline at end of file diff --git a/nuget/netcore/lib/netstandard1.6/HackerSpray.Middleware.dll b/nuget/netcore/lib/netstandard1.6/HackerSpray.Middleware.dll new file mode 100644 index 0000000..4c4cec4 Binary files /dev/null and b/nuget/netcore/lib/netstandard1.6/HackerSpray.Middleware.dll differ diff --git a/nuget/netcore/lib/netstandard1.6/HackerSpray.Module.dll b/nuget/netcore/lib/netstandard1.6/HackerSpray.Module.dll new file mode 100644 index 0000000..90cb2ef Binary files /dev/null and b/nuget/netcore/lib/netstandard1.6/HackerSpray.Module.dll differ diff --git a/nuget/netcore/nuget.exe b/nuget/netcore/nuget.exe new file mode 100644 index 0000000..6bb79fe Binary files /dev/null and b/nuget/netcore/nuget.exe differ diff --git a/nuget/netcore/readme.txt b/nuget/netcore/readme.txt new file mode 100644 index 0000000..e2778e8 --- /dev/null +++ b/nuget/netcore/readme.txt @@ -0,0 +1,66 @@ +# Getting started with HackerSpray + +## Step 1: Add hackerspray.json in the configuration + +On your Startup.cs: + +var builder = new ConfigurationBuilder() + .SetBasePath(env.ContentRootPath) + .AddJsonFile("appsettings.json", optional: true, reloadOnChange: true) +Add this line--> .AddJsonFile("hackerspray.json", optional: true, reloadOnChange: true) + .AddJsonFile($"appsettings.{env.EnvironmentName}.json", optional: true); + + +## Step 2: Add the Hacker Spray service in Startup.cs + +public void ConfigureServices(IServiceCollection services) +{ + . + . + . + . + services.AddHackerSpray(Configuration.GetSection("HackerSpray")); +} + + +## Step 3: Add HackerSpray middleware in Startup.service + +Add app.UseXForwardedFor(); and app.UseHackerSpray(); right after UseStaticFiles() and before UseMvc(); + +public void Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory) +{ + . + . + . + + app.UseStaticFiles(); + + app.UseXForwardedFor(); + app.UseHackerSpray(); + + . + . + . + + app.UseMvc(routes => + { + routes.MapRoute( + name: "default", + template: "{controller=Home}/{action=Index}/{id?}"); + }); + +} + +## Step 4: Configure hackerspray.json + +{ + "HackerSpray": { + "Redis": "127.0.0.1", + "Prefix": "AuthTest-Core:", + "Keys": [ + "POST /Account/Login 100 00:10:00 key+origin", + "GET /Account/Login 100 00:10:00 key+origin", + "GET /Home/ 10000 00:10:00 key+origin" + ] + } +} \ No newline at end of file diff --git a/nuget/netcore/tools/install.ps1 b/nuget/netcore/tools/install.ps1 new file mode 100644 index 0000000..5be0d84 --- /dev/null +++ b/nuget/netcore/tools/install.ps1 @@ -0,0 +1,13 @@ +param($installPath, $toolsPath, $package, $project) +Write-Host $installPath +Write-Host $toolsPath +Write-Host $project +Write-Host $package + +$path = [System.IO.Path] +$projectPath = $path::GetDirectoryName($project.FileName) +Copy-File $path::Combine($installPath, "readme.txt") $projectPath + + +$readmefile = $path::Combine($projectPath, "\readme.txt") +$DTE.ExecuteCommand("File.OpenFile", $readmefile) \ No newline at end of file