c# - Web Config Transform / MSBuild - Rename config property based on date when deploying -


i have old web forms (.net 4) app uses forms authentication.

we have set web.config transforms each environment. use web deploy make our deployments.

however, have discovered deploying updates causes errors on logged in sessions because application restarted forms authentication cookie still valid app doesn't force logout stays in broken state until either auth cookie times out or user clears cookies.

the solution rename cookie before deploying invalidates current session cookies , forces log out on sessions.

so authcookie set this:

<authentication mode="forms">   <forms name="crunch201707280939" timeout="60" loginurl="~/login/login.aspx" protection="all" path="/" slidingexpiration="true" /> </authentication> 

which cookie name plus datetime.

what want automate renaming cookie based on date whenever app published either during web.config transform or using msbuild.

anyone know how this?


Comments

Popular posts from this blog

php - Vagrant up error - Uncaught Reflection Exception: Class DOMDocument does not exist -

vue.js - Create hooks for automated testing -

Add new key value to json node in java -