Beispiel #1
0
        public async Task <ActionResult> AadRopcLogin(AadRopcLoginModel model)
        {
            IAADAuthService authenticationService = new AADAuthService(Startup.AadTokenEndpoint, Startup.AadClientId, Startup.AadAudience);
            AadAuthResult   authenticationResult  = await authenticationService.AuthorizeAsync(model.Username, model.Password, new[] { "openid" });

            model.Result = authenticationResult;
            return(View(model));
        }
Beispiel #2
0
        public ActionResult AadRopcLogin(string userName)
        {
            var model = new AadRopcLoginModel()
            {
                Username = userName
            };

            return(View(model));
        }