Spring Security基本身份验证在基本Apache2代理后面不起作用

时间:2019-08-08 15:36:00

标签: apache spring-boot spring-security proxy

我有一个运行http://example.com:8181并嵌入了tomcat的Springboot应用程序。网络上未打开端口8181,因此我需要使用apache2向http://example.com/api-docs/association代理http://example.com:8181。这是基本的VirtualHost代理配置。

ProxyPreserveHost on
ProxyPass /api-docs/association http://localhost:8181/
ProxyPassReverse /api-docs/association http://localhost:8181/

Spring Security基本身份验证在此简单的代理配置下不起作用。但是,我可以成功curl本地主机:8181并使用凭据。

我对HTTP基本身份验证不熟悉,所以您能解释一下设置代理后哪些机制会失败吗?然后,应将哪些指令添加到VirtualHost配置中?

0 个答案:

没有答案