FormsAuthentication.FormsCookieName

FormsAuthenticationTicketは、クッキーに保持しておくことで、様々なページの認証で使うのだが、クッキーを識別する名前にはFormsAuthentication.FormsCookieNameを使う。

FormsAuthentication.FormsCookieName プロパティ (System.Web.Security) | Microsoft Docs

login.aspxで、

FormsAuthentication.FormsCookieNameをlabel1に出してみる。

ログインすると
ログインすると

ログインすると、

authdir2
authdir2

authdir2、つまり、

FormsAuthentication.FormsCookieNameとは、web.configのformsタグのname属性にある名前のこと。

Sample/aspnet/FormsAuthentication/FormsCookieName/src/FormsAuthentication at master · bg1bgst333/Sample · GitHub