dazinator / AspNetCore.LegacyAuthCookieCompat

Provides classes to encrypt / decrypt asp.net 2 / 3.5 / 4 and 4.5 FormsAuthenticationTickets (cookies) without relying on system.web
MIT License
74 stars 18 forks source link

Add FormsProtectionEnum support #34

Closed hisomu closed 1 year ago

hisomu commented 1 year ago

I wanted to say thank you for adding backwards compatibility support to FormAuthentication! It helped me recreate the cookie to support the other old apps.

I have a feature request to add in FormsProtectionEnum, I am currently using Validation protection. For example, here is the old configuration of the security settings: `

`

In the asp.net FormsAuthentication it only encrypts the cookie if the Protection is not Validation: https://github.com/microsoft/referencesource/blob/master/System.Web/Security/FormsAuthentication.cs#L276

hisomu commented 1 year ago

Created a PR for this here: https://github.com/dazinator/AspNetCore.LegacyAuthCookieCompat/pull/35

dazinator commented 1 year ago

thanks @hisomu - have merged the PR