profile

Hi, I’m a creator

How to enable CORS in ASP.NET Core and eBook updates

Published 11 months ago • 1 min read

Hello there,

Hope you are doing good.

Distributed architecture is a norm these days. The Front-end, Back-end and the Database tiers are separated into independent deployments to be able to scale as required.

This means that the Front-end and the Back-end run in different servers and generally own different domain names. This leads to a situation where the Front-end requests are naturally blocked by the Back-end framework due to a general policy called CORS.

This week I want to share with you how we enable CORS and handle this scenario using the built-in libraries with an illustrating example. We will also see what a Pre-flight request is, How we can allow all/block all requests by varying the CORS rules.

You can find the link here - https://referbruv.com/blog/setting-up-and-configuring-cors-in-an-aspnet-core-api/

I hope this article will be useful to you.

Please do like on Facebook, we are nearing 2000 likes and your like means a lot. Please do follow on Twitter, I do regularly post my latest updates over there.

My latest ebook - "How to Build a Containerized Angular .NET 6 App with Docker" is nearing its completion. I am so happy and satisfied about how it is turning out to be.

I will come back with more updates and the release date soon. Please do follow me on the Social Channels I mentioned above to stay updated.

Have a great week.

Cheers

Ram

Hi, I’m a creator

Read more from Hi, I’m a creator

Hello there, Hope you are doing good. Token based Authentication is one of the most popular and widely used authentication and identity management systems used across the world. It is simple, easy to integrate and makes user experience better. Applications can decouple User Identity and Authentication layer to an externalized Authorization Server layer and delegate authentication to this server. You will only enter credentials at a centralized Identity Provider site and the application...

9 months ago • 2 min read

Hello there, Hope you are doing good. I wanted to share some interesting news to you. You want to add authentication to secure your resources, authorize access, implement CORS policies, enforce HTTPS, or even cache responses – you will add the respective built-in libraries to the web application. These are all exposed by the ASP.NET Core framework as Middleware – pieces of code blocks that are responsible for a single functionality. Announcing my new digital product - "How to work with...

9 months ago • 1 min read

Hello there, Hope you are doing good. This week, I want to introduce you to the 3 caching patterns that we generally use to implement Caching in our applications. We choose a caching pattern that best fits our application based on its behavior, business requirements and tolerance. The following are the 3 popular patterns used for caching in microservices. Cache-Aside The cache is lazy loaded with data only when needed and is not available in the cache. The microservice decides if the data...

10 months ago • 1 min read
Share this post