https://www.craftedforeveryone.com/adding-your-own-custom-authorize-attribute-to-asp-net-core-2-2-and-above/
Adding your own Custom Authorize Attribute to Asp. Net Core 2.2 and above