Spring Cloud Gateway集成Actuator的安全漏洞和解决方案
https://blog.csdn.net/icansoicrazy/article/details/130227849
正在显示
1 个修改的文件
包含
7 行增加
和
3 行删除
@@ -64,15 +64,19 @@ logging: | @@ -64,15 +64,19 @@ logging: | ||
64 | logback: | 64 | logback: |
65 | appname: gateway-service | 65 | appname: gateway-service |
66 | logdir: ./log | 66 | logdir: ./log |
67 | -# 暴露端点 | 67 | +# 暴露端点安防 |
68 | management: | 68 | management: |
69 | endpoints: | 69 | endpoints: |
70 | web: | 70 | web: |
71 | exposure: | 71 | exposure: |
72 | - include: '*' | 72 | + include: ["health", "info"] # 暴露任何健康检查与信息端点 |
73 | + gateway: | ||
74 | + enabled: false | ||
73 | endpoint: | 75 | endpoint: |
74 | health: | 76 | health: |
75 | - show-details: always | 77 | + enabled: true # 启用健康检查端点 |
78 | + info: | ||
79 | + enabled: true # 启用信息端点 | ||
76 | debug: false | 80 | debug: false |
77 | host: | 81 | host: |
78 | # 部署所在服务器操作系统名称,小写[windows/linux] | 82 | # 部署所在服务器操作系统名称,小写[windows/linux] |
-
请 注册 或 登录 后发表评论