# 5985,5986 - Pentesting OMI {{#include ../banners/hacktricks-training.md}} ### **기본 정보** **OMI**는 Microsoft에서 원격 구성 관리를 위해 설계된 **[오픈 소스](https://github.com/microsoft/omi)** 도구로 제공됩니다. 이는 Azure에서 다음과 같은 서비스를 사용하는 Linux 서버와 특히 관련이 있습니다: - **Azure Automation** - **Azure Automatic Update** - **Azure Operations Management Suite** - **Azure Log Analytics** - **Azure Configuration Management** - **Azure Diagnostics** 이 서비스가 활성화되면 `omiengine` 프로세스가 시작되어 모든 인터페이스에서 루트로 수신 대기합니다. **기본 포트**로 사용되는 것은 **5985** (http) 및 **5986** (https)입니다. ### **[CVE-2021-38647 취약점](https://msrc.microsoft.com/update-guide/vulnerability/CVE-2021-38647)** 9월 16일에 관찰된 바와 같이, 언급된 서비스가 배포된 Azure의 Linux 서버는 OMI의 취약한 버전으로 인해 취약합니다. 이 취약점은 OMI 서버가 `/wsman` 엔드포인트를 통해 메시지를 처리할 때 인증 헤더를 요구하지 않아 클라이언트를 잘못 인증하는 데 있습니다. 공격자는 인증 헤더 없이 "ExecuteShellCommand" SOAP 페이로드를 전송하여 서버가 루트 권한으로 명령을 실행하도록 강제할 수 있습니다. ```xml id 0 ``` 이 CVE에 대한 자세한 정보는 **[여기 확인하세요](https://github.com/horizon3ai/CVE-2021-38647)**. ## 참조 - [https://www.horizon3.ai/omigod-rce-vulnerability-in-multiple-azure-linux-deployments/](https://www.horizon3.ai/omigod-rce-vulnerability-in-multiple-azure-linux-deployments/) - [https://blog.wiz.io/omigod-critical-vulnerabilities-in-omi-azure/](https://blog.wiz.io/omigod-critical-vulnerabilities-in-omi-azure/) {{#include ../banners/hacktricks-training.md}}