IBM TechXchange Korean CyberSecurity User Group (한국 사이버보안 사용자 그룹)

IBM TechXchange Korean CyberSecurity User Group (한국 사이버보안 사용자 그룹)

This online user group is intended for IBM Security product users in Korea to communicate with IBM experts, share advice and best practices with peers and stay up to date regarding product enhancements, regional user group meetings, webinars, how-to blogs and other helpful materials.

 View Only

IT의 쉐도우를 이용한 워너크라이 대응사례

By Gwibin Im posted Tue January 10, 2023 08:37 PM

  

당신의 IT의 그림자에 숨어있는 것을 조심하세요. / Beware of What Is Lurking in the Shadows of Your IT

포괄적인 사건 대응이라는 것은, 사이버 공위협이 모든 보안의 제품들을 통과할 것이라고 가정하면서 대응계획을 계속을 세우고 테스트를 하는 것을 이야기 합니다.

보안도구를 지나쳐 들어오는 위협의 요소의 한 사례는 쉐도우 IT인데 이것은 기업이 꼭 준비를 해야만 하는 것 입니다. 쉐도우 IT는 기업이 IT 또는 보안 지식 또는 권한이 없는 상태에서 운영되고 있는 하드웨어와 소프트웨어를 사용을 의미 합니다.

IBM 보안 X-Force 팀은 전 세계적으로 보안 사건에 대응해 오는 과정에서, 이러한 사건들로 부터 어떻게 사이버 공격자들이 기업에 권한을 얻어 그들의 공격을 수행할 수 있는지에 대한 소중한 노하우을 얻었습니다.

이 블로그에서, 우리는 공격이 일어나날 때 공격자들이 쉐도우 IT를 활용해서 기업을 공격하는 3가지 사건과 쉐도우 IT가 단순한 보안위협에서 실제 사이버 공격으로 바뀌는 과정을 이야기 하고자 합니다.

  Comprehensive incident preparedness requires building out and testing response plans that consider the possibility that threats will bypass all security protections. An example of a threat vector that can bypass security protections is “shadow IT” and it is one that organizations must prepare for. Shadow IT is the use of any hardware or software operating within an enterprise without the knowledge or permission of IT or Security.  
  IBM Security X-Force responds to security incidents across the globe, and from those incidents, X-Force gains valuable insights into how adversaries can gain access to organizations to carry out their attacks. In this blog, we will highlight three incidents where Shadow IT was leveraged during the attack to help organizations realize how Shadow IT can quickly transform from a threat to an incident.

몇가지 악성 시스템에 대한 워너크라이 공격 / WannaCry About Some Rogue Systems

X-Force 팀은 네트워크 기반의 엔드포인트 경고에 대한 위협에 대해 고객을 지원한 적이 있는데, 네트워크 안에서 앤드포인트가 의심스러운 도메인으로 연결하려는 시도 였습니다.X-Force 팀은 고객의 시설 들 중에, 윈도우 7이 패치되지 않았던 알지 못하였던 작은 시스템 하나에서 일어난 보안경고를 추적하게 되었습니다. 이 시스템들은 아예 보안팀의 시야 밖에서 운영이 되고 있었으며, 기업의 보안 툴 안에서 보호되지 않았습니다. X-Force 조사 과정에서, 이것은 악성 윈도우 시스템 중에 하나가 워너크라이 드로퍼를 다운받았으며 실행이 되자마자 iuqerfsodp9ifjaposdfjhgosurijfaewrwergwea[.]com. 에 연결하려는 시도를 하였다는 것을 알게 되었습니다.

처음의 연결시도된 이후 "Microsoft Security Center 2.0"라는 이름의 서비스가생성 되었으며. 이 서비스는 2개의 임베디드된 리소스를 로드하였습니다. EternalBlue 이름의 MS17-010 탈취를 사용해서 만들어진 SMB를 통해 워너크라이 랜섬웨어를 퍼트리는 속도를 높였습니다. X-Force는 이러한 행동이 기존에 기록으로 잘 남겨져 있던 워너크라이 감염 및 전파와 비슷한 양상을 보인다고 이야기 합니다.

  X-Force responded to an incident where a client had received a network-based alert for an endpoint within their network attempting to connect to a malicious domain. X-Force was able to trace the alert back to a small unknown deployment of unpatched Windows 7 systems within one of their facilities. These systems were operating completely outside the purview of the security team and were not protected by any of the organization’s security tooling.   
  Through X-Force’s investigation, it was determined that one of the rogue Windows systems downloaded a WannaCry dropper (mssecsvc.exe) and upon execution attempted to make a connection to iuqerfsodp9ifjaposdfjhgosurijfaewrwergwea[.]com. After the initial connection attempt, a new service was created named “Microsoft Security Center 2.0.” Following the creation of the Microsoft Security Center 2.0 service, the service loaded two embedded resources responsible for facilitating the spread of the WannaCry ransomware through SMB by making use of the MS17-010 exploit named “EternalBlue.” X-Force noted that this behavior is in complete alignment with the standard WannaCry infection and spread that has been well-documented.

X-Force 는 윈도우 7 시스템에 남아있는 것들을 분석하여, 워너크라이 감염이 예상처럼 SMB를 통해 퍼졌다는 것을 확신하였습니다. 이 시스템은 SMB 커넥션에 개방이 되어 있었기 때문에, 정보탈취에 대해 매우 취약하였습니다. 이 SMB 커넥션은 기존에 사용하고 있던 프린트 기능을 쉽게 사용하기 위해서, 서로간에 파일을 전달할 수 있게 사용되었습니다. X-Force 사고대응팀은 워너크라이 실행파일이 상당한 시간동안 IT 업무의 밖에서 운영되오고 있던 시스템들에서, 여러 해 동안 만들어지고 있었다는 것을 발견하였습니다

이 사례에서 알 수 있는 것은, 이후에도 기업은 낮은 가능성이지만 감염과 추가적인 전파위협이 계속 존재하는 상황에 있었다는 것 입니다. X-Force는 공격자들이 시스템에 양방향으로 접근할 수 있는 권한을 얻는 것 보여줄 만한 어떠한 활동도 발견하지 못하였습니다. 하지만 활동이 발견되지는 않았으나, 오랜 시간동안 기업은 악성 시스템을 발견하지 못하였고 이는 기업들이 시스템이 남아서 또 다른 정보탈취를 하거나, 시설의 네트워크가 연결된 다른 쪽으로 내부이동하는 것의 가능성을 보여주었습니다.

  X-Force analyzed the remainder of the Windows 7 systems in the rogue deployment and determined the WannaCry infection was able to spread via SMB as expected. The systems were vulnerable to the exploit because they also had open SMB connections, which enabled them to pass files between each other to facilitate the printing function for which they were used. X-Force Incident Response (IR) observed the creation of the WannaCry executables had been created over several years, indicating the systems had been running outside the scope of IT management for a significant amount of time.  
  In this case, the risk to the organization remained rather low since the infection and follow-on spread were opportunistic, and X-Force uncovered no activity that indicated an adversary gained interactive access to the systems. However, the length of time that the rogue systems were able to remain undetected by the organization shows that had an adversary been able to gain access to the rogue systems, the potential for further exploitation and lateral movement into other parts of the facility’s network was possible.

범죄자들은 이미 열려있는 문으로 들어갈 수 있다면, 굳이 침투하려 할까요? / Why Break in When You Can Walk Through an Open Door

X-Force가 여러 다른 보안사건을 다루는 중에, 고객은 사이버 보안팀이 그들의 내부 마이크로소프트 엑티브 디렉토리에서 무차별적인 악성공격을 발견했다는 내용을 안내해 주었습니다. 고객은 이 공격과 관련해서, 승인이 이루어진 것을 발견하지 못하였는데, 이상하게 계정이 잠긴다는 불만을 접수받기 시작했습니다. 그들은 공격의 출처가 무엇인지를 결정할 수는 없었습니다.

내부 상황으로, 고객의 보안팀은 인도우 이벤트 로그 안에 저장되어 기본 인증이벤트의 데이터를 활용하였을 것 입니다. Event ID 4625 의 케이스인데, 소스네트워크주소 또는 워크스테이션이름속성으로 된 인증 시도의 소스를 추적하였을 것 입니다. 그러나 이 케이스에서, 보안팀은 Event ID 4625와 관련된 어떠한 이벤트 로그를 발견할 수 없었습니다.

  During a different engagement, X-Force was notified by a client that their security team had detected a brute force attack against their internal Microsoft Active Directory. The client had not detected any successful authentications associated with the attack but was beginning to receive complaints of account lockout. They were unable to determine the source of the attack.
  In normal circumstances, the client’s security team would leverage the data available within the default authentication events stored within the Windows Event Log — in this case, Event ID 4625 — to track the source of the authentication attempt by either the Source Network Address or Workstation Name attribute. However, in this case, the security team was unable to locate any event logs associated with the ID 4625.

X-Force는 도메인 컨트롤러에서 나온 로그를 조사했고 외부 앤드포인트가 케르베로스를 거쳐 NT 랜 매니저 프로토컬을 사용하여 인증을 시도하고 있음을 보여주는 공통 로깅 패턴을 발견하였습니다. 이 시나리오에서 도메인 컨트롤러는 유저들들의 로그인을 막았던 ID 4740의 이벤트에 이후에, ID 4776 이벤트와 관련된 연속적인 이벤트의 로그를 남겼습니다.

이벤트 ID 4776은 도메인 컨트롤러가 케르베르소의 NTLM을 사용하는 계정 신분정보를 확인하려고 시도할 때 기록이 되었습니다. 4776은 NTLM을 서버와 윈도우 워크스테이로 활용하는 로컬 SAM 인증에서 기록을 남겼으며 이는 기본 신분정보 원리 입니다.

  X-Force investigated the logs from the domain controller and identified a common logging pattern indicating an external endpoint was attempting to authenticate using the NT LAN Manager (NTLM) protocol over Kerberos. In this scenario, the domain controller will log consecutive events associated with event ID 4776 followed by an event ID 4740 indicating that the user has been locked out.  
  Event ID 4776 is logged when a domain controller tries to validate the account credentials using NTLM over Kerberos. 4776s are also logged for local SAM authentication for Windows workstations and servers as NTLM is the default authentication mechanism.

고객의 IT와 보안팀에 의하면, 4776에서 보여진 소스 워크스테이션은 그들의 도메인 일부가 아니었으며, 어떠한 앤드포인트도 자사의 네트워크 및 자산관리 툴에 등록되어 있지 않았습니다.

인증하려는 시도의 출처를 추적하기 위해서, X-Force팀은 고객들에게 도메인 컨트롤러에 있는 고객이 넷로그온 디버깅 로그를 볼 것을 이야기 하였습니다. 넷로그온 디버깅 로그는 C:\Windows\debug\netlogon.log 에 저장되었고, 인증시도과 관련된 공격의 목표가 된 기기들의 이름이 되었을 것이라고 이야기 했습니다. X-Force 는 고객에게 목표대상이 된 기계들에서 나온 복구된 넷로그 디버그 로그를 제공해 줄 것을 요청하였으나, 고객의 보안과 IT팀은 그들의 도메인 안에 있던 유효한 앤드포인트로 되어있의 시스템의 어떠한 기록도 가지고 있지 않았습니다.

  According to the client’s IT and security team, the source workstation referenced in 4776 events was not a member of their domain and they had no endpoints registered with that name in any of their network or asset management tools.
  To track down the source of the authentication attempts, X-Force instructed the client to enable Netlogon debugging logs on their domain controllers. Netlogon debugging logs are stored in C:\Windows\debug\netlogon.log and will capture the name of the target machine involved in the authentication attempt. X-Force requested the client provide the logs from the target machine recovered from the Netlogon debug logs, however, the client’s security and IT teams did not have any records of the target system being a valid endpoint within their domain.




 

유효 앤드포인트와 원격에 대한 분석은 X-Force 가 공격의 대상이 된 시스템의 AWS account에 남아있었던 기록을 확인하게 해 주었습니다. 위협에 대한 방지와 조치를 한 후에 X-Force팀은 고객의 IT 팀과 함께 공격의 원인이 인터넷이 접속할 수 있는 윈도우 서버에 있다는 것을 확인하였습니다.고객의 내부 엑티브 디렉토리의 도메인과 통신을 할 수 있는 유효한 네트워크와 연결이 가능한 AWS 계정안에 서버가 설치되었습니다.

AWS 안에 있는 윈도우 서버는 일시적인 것으로, MFA 또는 복잡한 비밀번호 같이 기업의 보안 툴이 설치되지 않아 있었습니다. 서버는 절대 폐기가 되지 않았고, 적들이 RDP를 활용해서 서버에 접근권한을 얻었으며, 이는 고객의 내부 네트워크에 접속할 수 있게 하였습니다.

다행히도, 적들이 추측해서 찾아내려는 비밀번호 시도를 발견하였고, 적들의 내부 이동이 이루어지 기 전에 Force 팀에 연락을 하여 이 해킹사건에 대해 조치를 취하였습니다. 그러나 악성 EC2 인스턴스는 원격의 적들이 모든 보안팀의 경계보안 통제를 뚤고, 가상의 보이지 않는 네트워크 안에 들어와 있었습니다. 이는 내부 보안 툴로는 발견되지 않는 것 이었습니다.

Further analysis of the available endpoint and network telemetry allowed X-Force to pinpoint that the target system reference in the debug logs resided within the client’s AWS account. Following containment and remediation of the threat, X-Force worked with the client’s IT team to determine that root cause of the attack was an Internet-accessible Windows server. The server was deployed within the client’s AWS account with the appropriate networking capabilities to communicate to the client’s internal Active Directory domain.  
  The Windows server in AWS was meant to be deployed temporarily and was not deployed with any of the organization’s security tooling or best practices, such as MFA or password complexity. The server was never decommissioned, and an opportunistic adversary gained access to the server using RDP, which ultimately provided access to the client’s internal network.
  Fortunately, the client was able to detect the password guessing attempts and contact X-Force to contain and remediate the incident before the adversary was able to move laterally. However, the rogue EC2 instance enabled a remote adversary to bypass all the security team’s perimeter security controls and exist on the network in a virtual blind spot — undetected by the internal security tooling.

This post was written with contributions from Joseph Lozowski.

https://securityintelligence.com/posts/beware-lurking-shadows-it/

0 comments
5 views

Permalink