腾讯云
开发者社区
文档
建议反馈
控制台
登录/注册
首页
学习
活动
专区
圈层
工具
MCP广场
文章/答案/技术大牛
搜索
搜索
关闭
发布
文章
问答
(9999+)
视频
沙龙
1
回答
为什么
选择
User.Identity.IsAuthenticated
false
?
、
、
我需要在没有授权属性的情况下创建操作,但我需要在
User.Identity.IsAuthenticated
中获取值。JwtBearerDefaults.AuthenticationScheme; {{ var result = await _signInManager.PasswordSignInAsync(userName, password, <em
浏览 19
提问于2019-05-15
得票数 0
2
回答
用户配置文件对象为空,甚至用户已正确登录?
、
、
此外,
User.Identity.IsAuthenticated
总是返回
false
。 但是,所有这些问题都在导航到另一个页面时得到了解决。
为什么
User.Identity.IsAuthenticated
返回
false
,即使用户正确登录?还有,有没有办法在登录控件的LoggedIn事件中获取用户的配置文件信息?
浏览 2
提问于2010-04-02
得票数 0
回答已采纳
1
回答
User.Identity.IsAuthenticated
总是返回
false
、
、
、
User.Identity.IsAuthenticated
) return new ChallengeResult(provider, this); ExternalLoginData
浏览 0
提问于2017-08-09
得票数 2
2
回答
认证中的几个误区
、
、
、
、
, password)) FormsAuthentication.SetAuthCookie(userName, true); return View("Desktop"); return View("Login");我的问题是,
为什么
在我使用此行( isAuth,
User.Identity.IsAuthenticated
)设置
浏览 4
提问于2015-04-20
得票数 1
2
回答
会话丢失和Page().
User.Identity.IsAuthenticated
= WebService调用的
false
、
、
、
我的问题是:关于aspx: (在myclass中) Page().S
浏览 4
提问于2011-12-06
得票数 2
1
回答
User.Identity.IsAuthenticated
始终为
false
、
、
、
、
当我用这段代码查看时:// this code always returns
false
{ // this is true but what am I missing here to make above not be
false
浏览 2
提问于2016-01-14
得票数 1
1
回答
User.Identity.Name和
User.Identity.IsAuthenticated
是什么场景?
、
、
、
、
为什么
User.Identity.Name是空字符串,而
User.Identity.IsAuthenticated
false
是在SignInManager.PasswordSignInAsync返回Successmodel.Email, model.Password, model.RememberMe, shouldLockout:
false
//
User.Identity.IsAuthenticat
浏览 2
提问于2015-06-08
得票数 4
回答已采纳
5
回答
User.Identity.IsAuthenticated
在.net核心自定义身份验证中总是错误的
、
、
请任何人检查下面的代码,并让我知道
为什么
我总是错误(
User.Identity.IsAuthenticated
)??我在浏览器上正确地获得了cookie,并且能够从Claim中获得价值,但是"
User.Identity.IsAuthenticated
“总是错误的。ExpiresUtc = DateTime.UtcNow.AddMinutes(20), AllowRefresh =
f
浏览 5
提问于2017-07-23
得票数 22
回答已采纳
1
回答
如何将ASP.NET用户和数据路由到JavaScript?
、
、
isAuthenticated: @User.Identity.IsAuthenticated.ToString().ToLower(), isBankClient: @(
User.Identity.IsAuthenticated
?User.Identity.AcquireUser().BankClientID.HasValue.ToString()
浏览 5
提问于2016-10-31
得票数 4
回答已采纳
2
回答
如果/当使用"Azure会话状态提供程序(redis)“时不需要使用User.Identity.Name/IsAuthenticated?
、
、
、
、
是不是因为我在某些动作中使用了User.Identity.Name或
User.Identity.IsAuthenticated
!我是否必须将User.Identity.Name替换为: //Boolean usern =
User.Identity.IsAuthenticated
= null) else {usern =
false
;} 这是正确的吗,如果
浏览 1
提问于2015-03-15
得票数 3
1
回答
User.Identity.IsAuthenticated
在调用SignInAsync后返回
false
、
、
{ //IsAuthenticated is returns
false
bool isAuthenticated=
User.Identity.IsAuthenticated
; retu
浏览 0
提问于2015-01-08
得票数 0
回答已采纳
2
回答
ASP.NET LoggedIn事件IsAuthenticated =
false
我正在使用带有LoggedIn事件的ASP.NET 4.0登录控件{在函数结束并重定向到Default.aspx之后,如果我添加了
User.Identit
浏览 1
提问于2012-08-28
得票数 0
回答已采纳
1
回答
HttpContext.User.Identity.IsAuthenticated抛出System.NullReferenceException:对象引用未设置为对象实例
、
、
我的代码很简单,比如:public ActionResult Login () if (
User.Identity.IsAuthenticated
) {你能告诉我
为什么
有时它是空的吗?
浏览 4
提问于2014-11-03
得票数 2
回答已采纳
1
回答
RedirectToAction(“索引”、“主页”)是否与返回重定向(“~/home”)相同?
我有两个
选择
:{}if(
User.Identity.IsAuthenticated
"Index", id = UrlParameter.Optional },有人能告诉我我的
选择</
浏览 2
提问于2013-10-12
得票数 1
回答已采纳
3
回答
如何在Web中使用
User.Identity.IsAuthenticated
、
、
User.Identity.IsAuthenticated
总是在我的ASP.NET Web项目中返回
false
。AuthenticationManager.SignIn(new AuthenticationProperties() { }, identity); 登录后,
User.Identity.IsAuthenticated
在ApiController中始终是
false
,而在MVC控制器中则是true。
浏览 8
提问于2014-03-11
得票数 5
回答已采纳
1
回答
在ASP.NET MVC控制器中与授权和未授权用户共享操作
、
目前,我已经注意到,无论如何,在此操作的上下文中,
User.Identity.IsAuthenticated
始终为
false
。下面是我的代码:{ { ViewBag.ShowAuthStuff = true; ViewBag.ShowAuth
浏览 0
提问于2013-04-03
得票数 1
回答已采纳
1
回答
奇怪的MVC4身份验证行为-登录后
User.Identity.IsAuthenticated
为假
、
、
问题是,即使在WebSecurity.Login()返回true之后,
User.Identity.IsAuthenticated
仍然返回
false
,这我不明白
为什么
。model.UserName, model.Password, persistCookie: model.RememberMe)) { //Why this should ever return
false
bool isAuthenticated =
User.Identity.IsAuthenticated</e
浏览 0
提问于2014-03-13
得票数 0
1
回答
登录后
User.Identity.IsAuthenticated
仍为
false
、
但是在我登录后,以下代码并没有像我预期的那样工作: 1)
User.Identity.IsAuthenticated
仍然是假的。因此,索引页面显示“您尚未登录”。即使我已经登录了。return View();} 索引页: @{ } @if (
User.Identity.IsAuthenticated
浏览 81
提问于2019-05-11
得票数 0
回答已采纳
1
回答
窗体身份验证SSO -
为什么
User.Identity.IsAuthenticated
==为
false
、
当我登录到一个站点时,第二个站点上的测试代码具有以下结果:var isAuthentication =
User.Identity.IsAuthenticated
;
浏览 0
提问于2014-01-16
得票数 2
回答已采纳
2
回答
如何检查用户是否在ASP.NET核心中进行了身份验证
、
我知道
User.Identity.IsAuthenticated
必须为true才能检查用户是否通过了身份验证。但是,我不确定这些属性中的哪些属性可以为空。所以我现在有这样的代码: if (User?.
浏览 10
提问于2020-03-03
得票数 2
回答已采纳
点击加载更多
相关
资讯
为什么=false结果是true?
为什么选择容器技术,又为什么选择了kubernetes?
为什么选择python
为什么选择EULO?
为什么选择IT行业?
热门
标签
更多标签
云服务器
ICP备案
对象存储
云点播
实时音视频
活动推荐
运营活动
广告
关闭
领券