Securing 2M+ accounts & $15B+ in assets, protected & secure·B5 Secure™ — per data-element authorization for .NET platforms

The trial source package

The trial source package

B5 Secure · Never Trust

Beyond the data models, migrations, repositories and dependency-injection components B5 Secure needs, the premium source package also implements common workflows — account management (register, login, two-factor, forgot password, account settings, IP-firewall management, email verification), user management (add / remove / suspend, permissions), administration (impersonation, transfer), security-event notifications and production-ready error handling — as source, with best practices (async, managers, DI, error handling), without writing a line of code.

A trial of the premium package lets you evaluate these capabilities. The sections below set you up with a sample project.

Trial packages aren’t currently available for .NET Framework libraries (MVC5 / Web API); the ASP.NET Core trial gives an equivalent evaluation. Need .NET Framework? Contact us.

Prerequisites

  • Register on the dashboard to install a trial source package (free); a dashboard account is needed to use the B5 Secure tools.
  • A compatible Visual Studio (VS2019+ with ASP.NET Core 3.1 recommended; VS2017 also works).

Choose a platform

The walkthrough is identical in shape across platforms; follow the one you build on.

ASP.NET Core Web API

Create the project

In Visual Studio, open Create a new project, choose C# and the ASP.NET Core Empty template, name it, target .NET Core 3.1 (or later) and create.

Install the B5 Secure library package

Install the B5SecurityKit.NetCore NuGet package, which provides full B5 Secure capabilities on ASP.NET Core Web API. See The Security Pipeline for the multi-stage workflow it adds.

C#
install-package B5SecurityKit.NetCore

Install the source package into the project

Install the trial source package for ASP.NET Core Web API. Follow these steps to install a source package; on the installer, select the ASP.NET Core Web API platform and the Trial package, then provide application configuration.

Being a trial, a major portion of the source is delivered as a demo binary (DLL) in a lib folder, alongside the editable source items added to your project.

Create the database

The trial package ships EF migrations and T-SQL scripts. Verify DefaultConnection in appsettings.json, then in the Package Manager Console run:

C#
update-database -Context DemoDbContext

If update-database isn’t recognized, restart Visual Studio and reopen the solution (see the tools troubleshooting section). On success you’ll see “Applying migration…” ending in “Done.”

Application configuration

The package adds settings under the app section of appsettings.json. The email settings below aren’t populated by default and are required for email-verification and forgot-password flows:

C#
"app": {
...
"MailId": "you@example.com",
"MailPassword": "password",
"MailProvider": "Gmail",
// "MailHost","MailPort","MailUseSSL","MailFrom"
...
}

These feed the Mailer component. MailProvider accepts MailGun, SendGrid, Gmail, Outlook, Yahoo or Custom; use MailFrom when the from-address differs from MailId, and Custom (with MailHost) for services like Amazon SES.

Run it

Press F5. Sign up a new user, or sign in as the super-admin (the username you set during install, password admin) and try flows like account settings.

ASP.NET Core MVC

Create the project

In Visual Studio, open Create a new project, choose C# and the ASP.NET Core Empty template, name it, target .NET Core 3.1 (or later) and create.

Install the B5 Secure library package

Install the B5SecurityKit.NetCore NuGet package, which provides full B5 Secure capabilities on ASP.NET Core MVC. See The Security Pipeline for the multi-stage workflow it adds.

C#
install-package B5SecurityKit.NetCore

Install the source package into the project

Install the trial source package for ASP.NET Core MVC. Follow these steps to install a source package; on the installer, select the ASP.NET Core MVC platform and the Trial package, then provide application configuration.

Being a trial, a major portion of the source is delivered as a demo binary (DLL) in a lib folder, alongside the editable source items added to your project.

Install the node dependencies

The Trial ASP.NET Core MVC source package has script dependencies (bootstrap, jQuery, jTable) configured as NPM packages. Install them per the tools guide.

Create the database

The trial package ships EF migrations and T-SQL scripts. Verify DefaultConnection in appsettings.json, then in the Package Manager Console run:

C#
update-database -Context DemoDbContext

If update-database isn’t recognized, restart Visual Studio and reopen the solution (see the tools troubleshooting section). On success you’ll see “Applying migration…” ending in “Done.”

Application configuration

The package adds settings under the app section of appsettings.json. The email settings below aren’t populated by default and are required for email-verification and forgot-password flows:

C#
"app": {
...
"MailId": "you@example.com",
"MailPassword": "password",
"MailProvider": "Gmail",
// "MailHost","MailPort","MailUseSSL","MailFrom"
...
}

These feed the Mailer component. MailProvider accepts MailGun, SendGrid, Gmail, Outlook, Yahoo or Custom; use MailFrom when the from-address differs from MailId, and Custom (with MailHost) for services like Amazon SES.

Run it

Press F5. Sign up a new user, or sign in as the super-admin (the username you set during install, password admin) and try flows like account settings.

ServiceStack

Create the project

In Visual Studio, open Create a new project, choose C# and the ASP.NET Core Empty template, name it, target .NET Core 3.1 (or later) and create.

Install the B5 Secure library package

Install the B5SecurityKit.ServiceStack NuGet package, which provides full B5 Secure capabilities on ServiceStack. See The Security Pipeline for the multi-stage workflow it adds.

C#
install-package B5SecurityKit.ServiceStack

Install the source package into the project

Install the trial source package for ServiceStack. Follow these steps to install a source package; on the installer, select the ServiceStack platform and the Trial package, then provide application configuration.

Being a trial, a major portion of the source is delivered as a demo binary (DLL) in a lib folder, alongside the editable source items added to your project.

Create the database

The trial package ships EF migrations and T-SQL scripts. Verify DefaultConnection in appsettings.json, then in the Package Manager Console run:

C#
update-database -Context DemoDbContext

If update-database isn’t recognized, restart Visual Studio and reopen the solution (see the tools troubleshooting section). On success you’ll see “Applying migration…” ending in “Done.”

Application configuration

The package adds settings under the app section of appsettings.json. The email settings below aren’t populated by default and are required for email-verification and forgot-password flows:

C#
"app": {
...
"MailId": "you@example.com",
"MailPassword": "password",
"MailProvider": "Gmail",
// "MailHost","MailPort","MailUseSSL","MailFrom"
...
}

These feed the Mailer component. MailProvider accepts MailGun, SendGrid, Gmail, Outlook, Yahoo or Custom; use MailFrom when the from-address differs from MailId, and Custom (with MailHost) for services like Amazon SES.

Run it

Press F5. Sign up a new user, or sign in as the super-admin (the username you set during install, password admin) and try flows like account settings.

Developer Relations

Talk to a human.

Get architecture guidance, Test Mode access, integration review, or help choosing the right B5 identity and authorization pattern.

Scroll to Top