FormsAuthentication.GetRedirectUrl

FormsAuthentication.GetRedirectUrlで、ログイン成功後に遷移するページへのリダイレクトURLをもらう。

FormsAuthentication.GetRedirectUrl(String, Boolean) メソッド (System.Web.Security) | Microsoft Docs

login.aspxで、

リダイレクトURLがどうなるかみてみる。

もともとmain.aspxにアクセスしようとしてたので、ログインすると
もともとmain.aspxにアクセスしようとしてたので、ログインすると

もともとmain.aspxにアクセスしようとしてたので、ログインすると、

やっぱり、main.aspxへのパスになってた。
やっぱり、main.aspxへのパスになってた。

やっぱり、main.aspxへのパスになってた。

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