My OwaspHeaders.Core middleware hit version 126.96.36.199 recently. The new version uses a new way to set it's configuration: the builder pattern. So I thought I'd write a little about how the builder pattern works and how it is used by ASP NET Core and my middleware.
I decided to take one of my open source projects (OwaspHeaders.Core - https://github.com/GaProgMan/OwaspHeaders.Core) and update the code a little. It had previously used a json for configuration, but after this stream it used the Builder Pattern
Today’s header image was created by Roberto Catarinicchia at Unsplash Caveat Just a quick note before we begin. A caveat
In this post we'll take a previously built custom middleware and finalise the configuration options to it. We'll complete the JSON file which represents the config, and ensure that it's being read and the values are applied to the middleware setup.
In this post we'll take a previously built custom middleware and add configuration options to it. We'll load our config options for the middleware from a JSON file present in the consuming application, and apply it to the middleare