我们有一个Kubernetes集群,其中运行了一些财务软件- Strands。当我们尝试访问前端的某个页面时,来自前端的请求将被发送到Kubernetes pod,该pod将处理该请求。
Pod运行Tomcat,我们看到请求被拒绝,并显示以下消息:
2022-10-31T10:30:46,133 INFO [UserSessionFilter.java:153] : URI :/bfm-web/config/get.action
2022-10-31T10:30:46,133 INFO [UserSessionFilter.java:154] : Remote Host :10.240.0.103
2022-10-31T10:30:46,133 INFO [UserSessionFilter.java:155] : Remote Port :41898
2022-10-31T10:30:54,295 INFO [UserSessionFilter.java:152] : Request not allowed. Just return a 403 status
2022-10-31T10:30:54,296 INFO [UserSessionFilter.java:153] : URI :/bfm-web/config/get.action
2022-10-31T10:30:54,296 INFO [UserSessionFilter.java:154] : Remote Host :10.240.0.229
2022-10-31T10:30:54,296 INFO [UserSessionFilter.java:155] : Remote Port :57206
我不熟悉Tomcat或Java,也不知道该去哪里找。我试着检查web.xml文件中的一些过滤器,但可以找到任何线索。这是否与Kubernetes的一些授权设置有关?
让我知道什么信息,我可以与您分享,以帮助,这里有一些其他的日志,也后端使用PostgreSQL数据库的用户数据,但它似乎工作得很好:
2022-10-27T11:16:20,751 INFO [{omitted_due_to_sec_reasons}HttpHeaderUserSessionFilter.java:71] : The header name [user.header.name] has been set to HTTP_STRANDS_USER
上面的这个对我来说很有趣,因为它似乎是一个自定义的过滤器,它设置过滤器接受特定的标题(我故意省略了一些公司信息)。有人知道我在哪里可以找到这些过滤器吗?
10.240.0.103 - - [28/Oct/2022:14:02:33 +0000] "GET /bfm-web/config/get.action HTTP/1.1" 403 707
10.240.0.103 - - [31/Oct/2022:10:12:01 +0000] "GET /bfm-web/config/get.action HTTP/1.1" 403 743
10.240.0.103 - - [31/Oct/2022:10:24:31 +0000] "GET /bfm-web/config/get.action HTTP/1.1" 403 743
10.240.0.103 - - [31/Oct/2022:10:24:36 +0000] "GET /bfm-web/config/get.action HTTP/1.1" 403 743
10.240.0.103 - - [31/Oct/2022:10:30:46 +0000] "GET /bfm-web/config/get.action HTTP/1.1" 403 743
10.240.0.229 - - [31/Oct/2022:10:30:54 +0000] "GET /bfm-web/config/get.action HTTP/1.1" 403 743
及其他:
31-Oct-2022 10:12:01.856 INFO [http-nio-8080-exec-10] org.apache.catalina.core.ApplicationContext.log Request not allowed. Just return a 403 status. URI :: /bfm-web/config/get.action
31-Oct-2022 10:24:31.966 INFO [http-nio-8080-exec-2] org.apache.catalina.core.ApplicationContext.log Request not allowed. Just return a 403 status. URI :: /bfm-web/config/get.action
31-Oct-2022 10:24:36.951 INFO [http-nio-8080-exec-3] org.apache.catalina.core.ApplicationContext.log Request not allowed. Just return a 403 status. URI :: /bfm-web/config/get.action
31-Oct-2022 10:30:46.133 INFO [http-nio-8080-exec-5] org.apache.catalina.core.ApplicationContext.log Request not allowed. Just return a 403 status. URI :: /bfm-web/config/get.action
31-Oct-2022 10:30:54.297 INFO [http-nio-8080-exec-6] org.apache.catalina.core.ApplicationContext.log Request not allowed. Just return a 403 status. URI :: /bfm-web/config/get.action
1条答案
按热度按时间ocebsuys1#
该问题与缺少“enable-underscars-in-header:“true”“。添加它并重新启动pod就变魔术了。