当前位置:网站首页>记一次'非常诡异'的云安全组规则问题排查过程
记一次'非常诡异'的云安全组规则问题排查过程
2022-07-05 15:33:00 【yuanfan2012】
记一次非常诡异的云安全组规则问题排查过程
问题背景:
1、应用服务器:172.16.100.21
2、数据库服务器:172.16.100.22 (SQLServer 1433)
如图所示
(图片可点击放大查看)
一、问题现象
开发工程师反馈:
1、办公区的PC telnet 172.16.100.22 1433 SQLServer端口是通的,用Navicat可以连上数据库
2、但是非常奇怪的是:应用服务器172.16.100.21 上telnet 172.16.100.22 1433却不通,应用服务器联调不成功
(图片可点击放大查看)
二、问题确认与分析
我这边检查发现
1、应用服务器和数据库服务器使用的同一云服务器安全组规则
如下图所示
(图片可点击放大查看)
可以看到安全组规则对外是(0.0.0.0/0)全部开放1433端口
2、我尝试用运维区的服务器也进行端口探测
发现172.16.100.22 1433 SQLServer端口是通的
(图片可点击放大查看)
所以非常纳闷 这时以为问题应该出在数据库服务器上面,是不是数据库服务器自身做了啥限制
检查过172.16.100.22的操作系统防火墙配置,没有做任何限制,防火墙直接关闭的
也询问过开发工程师,数据库层面有没有限制,也说没有做限制
这也太奇怪了吧
三、继续排查
检查数据库服务器上的安全防护软件(HIDS)也没有做限制
与该开发工程师沟通过,联调阶段数据库服务器可以重启,也进行过重启,问题依旧 (虽然重启能解决80%的问题)
问题陷入僵局
四、跳出思维定势,问题瞬间解决
在沟通(battle)的过程中,突然开发工程师的一句话提醒了我:应用服务器对外访问有没有限制?对外?下行规则都放开外部访问的,他说的对外访问是指上行规则?出方向?
是啊,问题有没有可能出在源服务器上,而不应该出在目的服务器上,得转换一下方向
这时我打算去检查一下应用服务器自身操作系统防火墙的出站规则,突然在安全组上行规则(出方向)看到这个小细节
(图片可点击放大查看)
系统判定了一些高危端口,默认将其加入了安全组并禁止。 对于 Windows 云服务器,系统默认限制了几个“上行安全组”规则:
协议 TCP,端口3389,1433,445,135,139;
协议 UDP,端口1434,445,135,137,138。
Windows 云服务器向外发起 远程桌面连接,您需要在安全组中放行规则 tcp 上行 3389 端口;
Windows 云服务器向外发起 SQL Server 连接,您需要在安全组中放行规则 tcp 上行 1433 端口。
瞬间知道原因了 这时加了一条规则解决问题
(图片可点击放大查看)
开发反馈应用服务器:172.16.100.21可以正常连上172.16.100.22 (SQLServer 1433)数据库,问题解决
五、总结
越是诡异的问题越是要跳出思维定势去排查
正常的思路的确是会判定问题出在目的服务器上,而不会觉得源服务器有啥问题
边栏推荐
- Appium automation test foundation - appium basic operation API (I)
- Li Kou today's question -729 My schedule I
- The difference between abstract classes and interfaces
- The computer is busy, and the update is a little slow
- 定义严苛标准,英特尔Evo 3.0正在加速PC产业升级
- Write a go program with vscode in one article
- 写单元测试的时候犯的错
- Cs231n notes (top) - applicable to 0 Foundation
- Noi / 1.3 01: a+b problem
- vlunhub- BoredHackerBlog Moriarty Corp
猜你喜欢

list去重并统计个数

Why should we learn mathematical modeling?

Cs231n notes (medium) -- applicable to 0 Foundation

The visual experience has been comprehensively upgraded, and Howell group and Intel Evo 3.0 have jointly accelerated the reform of the PC industry
![21. [STM32] I don't understand the I2C protocol. Dig deep into the sequence diagram to help you write the underlying driver](/img/f4/2c935dd9933f5cd4324c29c41ab221.png)
21. [STM32] I don't understand the I2C protocol. Dig deep into the sequence diagram to help you write the underlying driver

Information collection of penetration test

Data communication foundation - route republication

CODING DevSecOps 助力金融企业跑出数字加速度

List de duplication and count the number

The difference between abstract classes and interfaces
随机推荐
Arduino controls a tiny hexapod 3D printing robot
wxml2canvas
Find the root of the following equation by chord cutting method, f (x) =x^3-5x^2+16x-80=0
vlunhub- BoredHackerBlog Moriarty Corp
Data communication foundation NAT network address translation
OSI seven layer model
MySQL表字段调整
ES6深入—ES6 Generator 函数
CSRF, XSS science popularization and defense
Temporary cramming before DFS examination
How to introduce devsecops into enterprises?
[Netease Yunxin] research and practice of super-resolution technology in the field of real-time audio and video
Vulnhub-Moneybox
MySQL5.7的JSON基本操作
Codasip为RISC-V处理器系列增加Veridify安全启动功能
vant tabbar遮挡内容的解决方式
项目sql中批量update的时候参数类型设置错误
Explanation report of the explosion
Query the latest record in SQL
The OBD deployment mode of oceanbase Community Edition is installed locally