Wildfly 10中的Undertow 4可以添加某种身份验证来限制对静态资源的访问:
示例:
http://localhost/img/my_img.jpg -> will return will return 401 Forbidden
http://localhost/img/my_img.jpg&auth=some_app_key -> will return 200 OK
http://localhost/img/my_img.jpg -> with a valid header parameter will return 200 OK
对于提供静态内容,这是一个很好的例子:How to configure Wildfly to serve static content (like images)?