0

anyone knows how to disable http methods such as put, delete on the jboss web server 7.0?

RewriteCond %{REQUEST_METHOD} ^(PUT|DELETE|TRACE|OPTIONS)$ [NC] is used for jboss6, but how can do on jboss7

1 Answers1

0

Just add <security-constraint> to web.xml

see for example Whitelist security constraint in web.xml

Jan W
  • 66
  • 4
  • Thank you for your answer, but in your example, the web.xml should be changed, but I want to change the standalone.xml in jboss7 instead of web.xml in project. In JBOSS6, RewriteCond %{REQUEST_METHOD} ^(PUT|DELETE|TRACE|OPTIONS)$ [NC] can be used to change the standalone.xml file, then how about jboss7. it change the web subdomain to undertow – Shrim.fish.K Nov 06 '17 at 07:47
  • I do not know how to disable HTTP methods in subsystem undertow. I wonder why you want to do that. For URIs that cannot be mapped to any application JBoss will return always HTTP 4xx or 5xx. – Jan W Nov 07 '17 at 07:30