Installation - jammycakes/badbehavior.net GitHub Wiki
The requirements for Bad Behavior are as follows:
- ASP.NET 3.5 or later on IIS 7 or later.
- As of version 0.2.0, Bad Behavior .NET requires full trust. It may run in medium trust (and future releases will make this an option) but this has not yet been tested.
Bad Behavior .NET can be installed into any Visual Studio-based web application using NuGet. Type the following in the package manager console:
Install-Package BadBehavior.net -Pre
Alternatively, you can install Bad Behavior .NET manually. First copy
the BadBehavior.dll file to your website's /bin directory, then add the
following lines to the <system.web>
section of your web.config file:
<httpHandlers>
<add path="BadBehavior.axd" verb="GET,POST"
type="BadBehavior.BadBehaviorHandler, BadBehavior" />
</httpHandlers>
<httpModules>
<add name="BadBehaviorHttpModule"
type="BadBehavior.BadBehaviorModule, BadBehavior" />
</httpModules>
Add the following lines to the <system.webServer>
section of your
web.config file:
<handlers>
<add name="BadBehavior" path="BadBehavior.axd" verb="GET,POST"
type="BadBehavior.BadBehaviorHandler, BadBehavior" />
</handlers>
<modules runAllManagedModulesForAllRequests="true">
<add name="BadBehaviorHttpModule"
type="BadBehavior.BadBehaviorModule, BadBehavior" />
</modules>
Note: if you already have handlers and modules defined in your web.config file, Bad Behavior should be listed first, otherwise it many not trap some requests.
If you are upgrading from version 0.1.0 or 0.1.1, please note that version 0.2.0 introduces several breaking changes.
In particular, if you have been logging events to SQL Server using the
SQL Server logger, you should delete the BadBehavior_Log
database table
and all the stored procedures created by Bad Behavior .NET (whose names
started with BadBehavior_
).