appsettings.json gets IntelliSense

As announced by Microsoft recently, we can use IntelliSense with appsettings.json files. What are appsettings.json files? Common settings of the application are generally stored in appsetting.json files. These files are separated on the basis of environments. For example, the settings for production environment are stored in appsettings.production.json and the settings for acceptance environment are stored … Continue reading appsettings.json gets IntelliSense

First look at InferSharp: A C# version of Facebook’s Infer You might have heard about Infer which is a tool to detect bugs in Java and C/C++/Objective-C code before it ships. Infer belongs to Facebook and it is a static analysis tool to produce a list of potential bugs such as null pointer exceptions, resource leaks, annotation reachability, missing lock guards, and concurrency race conditions … Continue reading First look at InferSharp: A C# version of Facebook’s Infer

Machine Learning And Human Learning

The funny thing about machine learning is that it closely seems to mimic human-learning algorithms which when studied closely(by a human:), could help him to learn even more, and that could eventually enable them to make better machine-learning algorithms and on and on…~ Sushant Singh Rajput. I always wonder how erudite was he! Nonetheless, although … Continue reading Machine Learning And Human Learning

How does the built-in dependency injection work on ASP.NET Core?

PC: Introduction Dependency Injection (DI) is a pattern that can help developers decouple the different pieces of their applications. DI provides a mechanism for the construction of dependency graphs independent of the class definitions. NET Core supports the DI software design pattern, which is a technique for achieving Inversion of Control (IoC, the “D” on the … Continue reading How does the built-in dependency injection work on ASP.NET Core?

Event Sourcing in .NET Core – part 1: A gentle introduction

Event sourcing, aka “the great myth”. I’ve been thinking about writing a series of articles about this for a while, and now it’s time to put my hands back on the keyboard. I thought that with all this bull**it pandemic at least I could have had more time to write on this blog but it … Continue reading Event Sourcing in .NET Core – part 1: A gentle introduction

A First Look At Azure Synapse Analytics

Reading through the article will reveal that Synapse Analytics is set to be the new end to end analytics solution in Microsoft Azure. Having said that, in this article, we will dive into it hands-on. Let’s take a first look at Synapse Analytics. Accordingly, we will see how to load data into the Synapse. Step1: … Continue reading A First Look At Azure Synapse Analytics

Whatsapp alert service by World Health Organization(WHO) for COVID-19(Corona virus)

This post is different than regular technical posts but at this situation we should help each other by spreading the technology which may help us. I came across a post on Twitter by which I got to know about a watsapp alert service powered by World health organization: I tried it out by following this … Continue reading Whatsapp alert service by World Health Organization(WHO) for COVID-19(Corona virus)

Skip Identity server login page for Azure AD(Auto login)

source: Medium In this article, we will see how we can skip Identity server 4 login page if we have integrated Azure AD with identity server 4. First let me explain the problem and then I will explain the solution for the same. Problem: We use Identity server 4 for authentication and we have integrated … Continue reading Skip Identity server login page for Azure AD(Auto login)

Create Certificates for IdentityServer4 signing using .NET Core

Nice article

Software Engineering

This article shows how to create certificates for an IdentityServer4 application to use for signing and token validation. The certificates are created using the CertificateManager nuget package. Both RSA and ECDsa certificates can be used for signing in IdentityServer4.

Code:Certificates for IdentityServer4 signing using .NET Core

Creating the Certificates in .NET Core

A simple .NET Core console application is used to create the certificates. This type of application can run on most of the standard operating systems. Create a new console application and add the package CertificateManager. The package Microsoft.Extensions.DependencyInjection is also required to initialize the package.

Creating a RSA certificate

A self signed RSA certificate can be created using the CertificateManager NewRsaSelfSignedCertificate method. The key size must be at least 2048. The following example also adds TLS server and client authentication OID extensions, so that the certificate could also be used for client authentication.

Creating a…

View original post 172 more words

Globally Require Authenticated Users By Default Using Fallback Policies in ASP.NET Core

Nice article

Scott Sauber


You can use Fallback Policies in ASP.NET Core 3.0+ to require an Authenticated User by default. Conceptually, you can think of this as adding an [Authorize] attribute by default to every single Controller and Razor Page ONLY WHEN no other attribute is specified on a Controller or Razor Page (like [AllowAnonymous] or [Authorize(PolicyName="PolicyName")]).  See lines 9-11 below.

// Other Startup code omitted
// Register other policies here
// Other service registrations omitted
view raw
hosted with ❤ by GitHub

A Quick Lap Around the [Authorize] and [AllowAnonymous] Attributes

In ASP.NET Core (and even previously in ASP.NET), we’ve had the ability to add a [Authorize] attribute to a resource (such as a Controller or Razor Page)…

View original post 1,025 more words