屏蔽Full authentication is required to access this resource
2018-03-05 14:49
1351 查看
springboot环境下,用postman调试接口,一直正常,今天突然出现以下错误:
{
"timestamp": "2018-03-05 14:43:45",
"status": 401,
"error": "Unauthorized",
"message": "Full authentication is required to access this resource",
"path": "/apptplatform/login"
}
上网搜一下解决方法,有人提出在配置中添加以下配置:
#忽略权限拦截
management:
security:
enabled: false并导入以下maven依赖(项目此前并没有此依赖)
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-actuator</artifactId>
</dependency>很可惜,问题依然存在。
由于项目的参与人员不多,问了下大家,有人添加了springboot的cloud依赖:
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-oauth2</artifactId>
</dependency>最后解决方法,如下图配置security:
basic:
enabled: false可以关闭springboot的安全验证。
此功能只是在配置上关闭安全验证,项目以后还是要打开此验证的。
查了下maven,oauth2这个包,本身依赖了security的包
{
"timestamp": "2018-03-05 14:43:45",
"status": 401,
"error": "Unauthorized",
"message": "Full authentication is required to access this resource",
"path": "/apptplatform/login"
}
上网搜一下解决方法,有人提出在配置中添加以下配置:
#忽略权限拦截
management:
security:
enabled: false并导入以下maven依赖(项目此前并没有此依赖)
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-actuator</artifactId>
</dependency>很可惜,问题依然存在。
由于项目的参与人员不多,问了下大家,有人添加了springboot的cloud依赖:
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-oauth2</artifactId>
</dependency>最后解决方法,如下图配置security:
basic:
enabled: false可以关闭springboot的安全验证。
此功能只是在配置上关闭安全验证,项目以后还是要打开此验证的。
查了下maven,oauth2这个包,本身依赖了security的包
相关文章推荐
- Full authentication is required to access this resource
- spring boot actuator 查看监控信息时报401错误 Full authentication is required to access this resource
- Full authentication is required to access this resource
- denied: requested access to the resource is denied : docker
- smtpClient发邮件错误:不允许使用邮箱名称。 服务器响应为: You are not authorized to send mail, authentication is required
- 使用chrome调试ajax加载本地文件的时候出现Failed to load resource: Origin null is not allowed by Access-Control-Allow
- Androidstudio启动模拟器失败Intel HAXM is required to run this AVD,VT-x is disabled in BIOS;
- smtpClient发邮件错误:不允许使用邮箱名称。 服务器响应为: You are not authorized to send mail, authentication is required
- Intel HAXM is required to run this AVD. VT-x is disabled in BIOS.
- The type Resource is not accessible due to restriction on required library
- Host is not allowed to connect to this MySQL server 和 access denied for user 'root'@'localhost' 解决办法
- SharePoint 爬网错误:Access is denied. Check that the Default Content Access Account has access to this content && 本机无法访问moss 站点
- AS启动模拟机时关于“Intel HAXM is required to run this AVD,VT-x is disabled in BIOS”问题的解决
- FIX: "There is insufficient system memory in resource pool 'internal' to run this query" error
- centos 6.3 使用 vnc xrdp 远程登陆 不断弹出对话框“ Authentication is required to set the network proxy used for downloading packages ”
- 上传自己的镜像被拒绝denied: requested access to the resource is denied
- asp.net在发送邮件时出现"服务器响应为: You are not authorized to send mail, authentication is required "解决方案
- java 错误:Access restriction: The type Resource is not accessible due to restriction on required library
- Access restriction: The type Resource is not accessible due to restriction on required library
- 启动模拟器 Intel HAXM is required to run this AVD VT-x is disabled in BIOS 问题