JAVA技术交流QQ群:170933152

最近做智慧城市项目,太恶心了。。。各种不会,个人负责权限验证中心服务,。。。唉,慢慢研究吧。。

报错信息

<MethodNotAllowed>
<error>method_not_allowed</error>
<error_description>Request method 'GET' not supported</error_description>
</MethodNotAllowed>

39是单引号

原因

默认只支持post

解决方法

  1. 下载安装postman工具(或其他post工具)
    使用post调用

  2. 代码增加get的方法
@Configuration
public class OAuthSecurityConfig extends AuthorizationServerConfigurerAdapter {
...@Overridepublic void configure(AuthorizationServerEndpointsConfigurer endpoints) throws Exception {...endpoints.allowedTokenEndpointRequestMethods(HttpMethod.GET, HttpMethod.POST);// add get method...endpoints.tokenServices(tokenServices);}
...
}

security工作笔记006---oauth2(spring security)报错method_not_allowed(Request method 'GET' not supported)解决相关推荐

  1. navicat连接pgsql报错:authentication method 10 not supported

    navicat连接pgsql报错:authentication method 10 not supported 解决方案:找到pgsql的安装目录下的pg_hba.conf文件 用文本编辑器打开后做如 ...

  2. security框架工作笔记001--- Shiro和Spring Security对比_智慧城市项目中选型用Spring Security

    JAVA技术交流QQ群:170933152 Shiro简介 Apache Shiro是Java的一个安全框架.目前,使用Apache Shiro的人越来越多,因为它相当简单,对比Spring Secu ...

  3. spring单元测试报错:Failed to load ApplicationContext 的解决方法

    使用idea 配置单元测试之后,配置完spring的注解@junit 和@runer 之后 一直报错. 最后发现是默认使用jdk1.8引起的,使用jdk1.7即可. 转载于:https://www.c ...

  4. SpringCloud工作笔记061---springBoot maven 打包jar报错_serverEndpointExporter

    JAVA技术交流QQ群:170933152 代码可以正常运行,websocket也是正常工作,但打包成jar就会报如下错误 Error starting ApplicationContext. To ...

  5. Spring MVC报错:The request sent by the client was syntactically incorrect ()

    springmvc数据绑定是一个很好的东西,在数据绑定的时候一定要主意Controller方法中的参数名和jsp页面里的参数名字是否一致或者按照绑定的规范来写,如果不一致,可能会报如下错误:  The ...

  6. 【SpringBoot的坑】Restful请求报错Request method 'POST' not supported,HiddenHttpMethodFilter无法将POST转换为PUT原因分析

    直接上结论: 因为 SpringBoot 版本原因,在我目前使用的 2.2.4 版本中,需要在springapplication.xml文件中 添加配置: spring.mvc.hiddenmetho ...

  7. Spring Security 源码分析:Spring Security 授权过程

    Spring Security是一个能够为基于Spring的企业应用系统提供声明式的安全访问控制解决方案的安全框架.它提供了一组可以在Spring应用上下文中配置的Bean,充分利用了Spring I ...

  8. 解决Spring Boot报错Mapped Statements collection already contains value for...Error while adding the mapp

    解决Spring Boot报错Mapped Statements collection already contains value for...Error while adding the mapp ...

  9. spring 笔记2:Spring MVC : Did not find handler method for 问题的解决

    spring 笔记2:Spring MVC : Did not find handler method for 问题的解决 参考文章: (1)spring 笔记2:Spring MVC : Did n ...

最新文章

  1. Tungsten Fabric SDN — 与 Bare Metal 的集成架构
  2. java浏览器实验报告_关于java实验报告模板
  3. [待解决]报错的脚本
  4. 组态王6.55安装教程
  5. 【Floyed】小萨的烦恼(ssl 1624)
  6. 随想录(插件的重要思想)
  7. windows资源监控
  8. windows 上安装 python3.7 和 pip 并配置虚拟环境
  9. 小冰与老东家微软达成战略合作,并宣布数亿元Pre-A轮融资,将全面开展商业化
  10. 量子纠缠2——CHSH不等式
  11. Winform 实现无边框窗体移动功能
  12. s查看oracle空间分配,Oracle查看表空间使用率(包括临时表空间)
  13. Oracle 锁表查询语句及解锁
  14. Self-Supervised Vision Transformers with DINO-代码研读
  15. css缩2个字,首行缩排2字元怎么设定 css
  16. 如何做一个一键吸空投箱的效果
  17. 《前端》localStorage 和 sessionStorage-将数据存入(取出)缓存的方法-2020年10月6日
  18. 51nod 2075 图书管理员
  19. 喜讯科技——桥梁防船撞预警系统
  20. 【线上分享】全球多媒体视频内容保护最佳实践

热门文章

  1. 十个Java基础面试题(附答案)
  2. Windows下运行Redis-网盘链接-简单粗暴-亲测有用
  3. 【数据结构算法】一:线性表
  4. OpenCV移植到ARM-Linux(Exynos4412)全过程
  5. 纪录安装tensorflow的又一次的坑
  6. 语音识别——触发字检测
  7. 快速定位NodeJs线上问题 - 之火焰图篇
  8. 从0移植uboot (二) _启动流程分析
  9. 电子邮件传输算法-Base64
  10. 数据中心操作人员:艰难地在针对VM构建的基础设施上运行容器