랜섬웨어(ransomware)와 aws 클라우드 보안 - 신용녀 (aws 솔루션즈아키텍트) ::...

52
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. 신용녀 솔루션아키텍트 2017.7.27 랜섬웨어와 클라우드 보안

Upload: amazon-web-services-korea

Post on 29-Jan-2018

1.306 views

Category:

Technology


0 download

TRANSCRIPT

©  2017,  Amazon  Web  Services,  Inc.  or  its  Affiliates.  All  rights  reserved.

신용녀 솔루션아키텍트

2017.7.27

랜섬웨어와 클라우드 보안

강연 중 질문하는 법

자신이 질문한 내역이 표시되며, 전체 공개로 답변된 내용은 검은색,

질문자 본인에게만 공개로 답변된 내용은 붉은 색으로 돌아옵니다.

본 세션의 주요 주제

••••

2011년 1년 동안 발견된악성코드

2017년 1분기 발견된악성코드

전체 악성코드는 8억 +

2017년 하루에 발견되는신/변종 악성코드

<출처:Ahnlab>

21만

2000만

8억 +

구분2015년 2016년

1분기 2분기 3분기 4분기 합계 1분기 2분기 3분기 4분기 합계

랜섬웨어민원접수

0 127 58 585 770 176 353 197 712 1438

15-­16년 랜섬웨어 피해 민원접수 현황

<출처:한국인터넷 진흥원>

Ransom(몸값) + Ware(제품)의 합성어사용자의 컴퓨터 화면을 잠그거나문서등을 암호화 후 사용자에게해독용 프로그램을 전송해 준다며금전을 요구이메일, SNS,  웹하드, 웹사이트방문등으로 감염

<출처:한국인터넷 진흥원>

랜섬웨어가 기존의 악성코드와 가장 큰 차이점은 수많은 변종이 지속적으로 개발모든 랜섬웨어에 대한 샘플을 수집하기 어려울 정도로 변종이 발생하고 있기에 대응이 어려움세계적으로 유포가 발생한 랜섬웨어의 진화 과정을 나타냄

<출처:Ahnlab>

<출처:한국인터넷 진흥원>

<출처:한국인터넷 진흥원>

<출처:한국인터넷 진흥원>

<출처:한국인터넷 진흥원>

• Wanna Cry의 경우 원본 파일 외에 별도로 암호화 파일을 생성한 후 삭제하였기때문에 데이터 복구 소프트웨어로도 복원이 가능한 경우도 존재

• 디스크에 여유공간이 충분해야 하며, C:\Users\ 하위 폴더는 권한 문제로 데이터복구 소프트웨어로 복원 불가

탐색기 확장자 숨김 설정Code  InjectionProcess  HollowingSleeping

빠른 확산암호화자동실행복원 지점 삭제

Cryptoransomware변종증가업그레이드해커/공급자/지불대행

우리가 다 아는 이야기….

<출처:한국인터넷 진흥원>

Wanna Cry

• Malware  /  Ransomware• 176개 파일 타입을 암호화

• 27개 언어

• $300  Ransom• 7일 Timer

• Affects  Microsoft  Windows

SMB 취약점 공식 패치

쉐도우브로커, NSA의 이터널블루(EternalBlue) 익스플로잇 공개

해당 취약점 악용해 유포된 국내외 “워너크라이(워너크립트, 워너디크립

트, 워너크립토라고도 불림)”라는 랜섬웨어 감염 사례 보고

kill  switch  동작

3.14

4.14

5.12

5.13

Wanna Cry 진행

Official Security Bulletin• AWS is aware of the WannaCry ransomware (also known as WCry,

WanaCrypt0r 2.0 and Wanna Decryptor) that leverages issues in multiple versions of Microsoft Windows SMB Server. By default, this software operates on UDP ports 137 & 138, and TCP ports 139 & 445. It provides remote systems with file and print sharing services. On March 14, 2017, Microsoft released a critical security update for Microsoft Windows SMB Server, which mitigates this issue.

• https://aws.amazon.com/security/security-bulletins/AWS-2017-006/

• Subscribe to the RSS feed!

Official Security Bulletin• AWS customers using the AWS-provided Windows AMIs from the

2017.04.12 release, or that have enabled automatic updates are not affected. We encourage customers using an older AMI or who do not have automatic updates enabled to install the security update.

• https://aws.amazon.com/security/security-bulletins/AWS-2017-006/

Official Security Bulletin

책임 공유 모델

AWS 기본 서비스

컴퓨팅 스토리지 데이터베이스 네트워킹

AWS 글로벌인프라 리전

가용 영역

엣지 로케이션

클라이언트 측 데이터 암호화및 데이터 무결성 인증

서버 측 암호화(파일 시스템 or 데이터)

네트워크 트래픽 보호(암호화/무결성/자격 증명)

플랫폼, 어플리케이션, 신원 및 접근 제어(IAM)

운영체제, 네트워크, 방화벽 설정

고객 어플리케이션 및 컨텐츠

Cus

tom

ers

AWS서비스

파트너솔루션

AWS와 고객이 보안을 함께 완성할 책임이 있습니다.

Abuse reporthttps://aws.amazon.com/ko/premiumsupport/knowledge-­center/report-­aws-­abuse/

EternalBlue해커집단 쉐도우브로커는 NSA가 이용했던 여러 공격 툴을 공개

• EternalBlue는 인증없이 Window 7 및 Window Server 2008을 공격하는데 사용할 수 있는 유일한 프로그램• 대상 컴퓨터에 악성 DLL을 원격으로 주입하기 위한 플로그인 DoublePulsar를 사용• EternalBlue로 공격 후 Empire로 악성 DLL을 만들어 DoublePulsar로 DLL인젝션을 하여 세션을 획득

감염 경로많은 랜섬웨어가 메일 첨부 파일이나 홈페이지 방문 할 때 감염되는데 반해WannaCryptor 랜섬웨어는 MS17-010 (Microsoft Windows SMBv2 원격코드실행취약점)을 통해 감염 되며 윈도우 2017년 3월 보안 업데이트가 적용되지 않은시스템에서은 별도의 동작 없이도 감염

자신의 로컬 IP대역의 D클래스 대역을 (xxx.xxx.xxx.1~255) 을 스캔하여 SMB 프로토콜패킷을 반복하여 전송

공격 대상?

취약점 종류Windows SMB 원격 코드 실행 취약성(CVE-2017-0143) Windows SMB 원격 코드 실행 취약성(CVE-2017-0144) Windows SMB 원격 코드 실행 취약성(CVE-2017-0145) Windows SMB 원격 코드 실행 취약성(CVE-2017-0146) Windows SMB 정보 유출 취약성 (CVE-2017-0147) Windows SMB 원격 코드 실행 취약성(CVE-2017-0148)

영향 받는 버전Windows 10 (취약점을 갖고 있으나, WannaCryptor의 공격대상은 아님) Windows 8.1 Windows RT 8.1 Windows 7Windows Server 2016 Windows Server 2012 R2 Windows server 2008 R2 SP1 SP2

윈도우 2017년 3월 보안 업데이트가 적용되지 않은 시스템은 대부분해당

상세 분석

인터넷이 안되는 등의 이유로 해당 사이트 접속이 안되면 악성코드와 관련된파일을 생성하고 파일 암호가 진행

<출처:Ahnlab>

• 악성코드가 실행되면 특정URL에 접속을 시도해 성공하면 악성코드는 종료• 악성코드 발견 당시 해당 도메인은 존재하지 않아 한 분석가가 도메인을 구매해

랜섬웨어의 전파를 차단(Kill Switch)

암호화 방식

<출처:Ahnlab>

Taskche.exe파일을 이용해 암호화 모듈인 t.wnry파일을 복호화하고 이를자신의 메모리에 로드하여 암호화를 진행

First…if there is a security incident..

• If you have an urgent security concern please cut a SEV-2 ticket to:

• "AWS / IT Security / Security Issue" and / or email Page AWS IT Security Primary Team

• Our security team would prefer to have a ticket cut than you think it is not important to them.

How could customers have been prepared?

Prevent  – Patching  with  EC2  Systems  ManagerPatch  Manager  is  an  automated  tool  that  helps  you  simplify  your  operating  system  patching  process,  including  selecting  the  patches  you  want  to  deploy,  the  timing  for  patch  roll-­outs,  controlling  instance  reboots,  and  many  other  tasks.  

Patch Manager

• Express  custom  patch  policies  as  patch  baselinese.g.,  apply  critical  patches  on  day  1  but  wait  7  days  for  non-­critical  patches

• Perform  patching  during  scheduled  maintenance  windows

• Eliminates  manual  intervention  and  reduces  time-­to-­deploy  for  critical  updates  and  zero-­day  vulnerabilities

• Built-­in  patch  compliance  reporting

Roll  out  Windows  OS  patches  using  custom-­defined  rules  and  pre-­scheduled  maintenance  windows  

Patch Management for Windows

Patch Baselines – Approval Rules

Patch Group 수정

ex  )  Patch  Management  for  Windows  

In  each  instancesIn  a  patch  baseline

ex  )  Patch  Management  for  Windows  

ex  )  Patch  Management  for  Windows  In  a  maintenance  window

ex  )  Patch  Management  for  Windows  

Search  Window  instances  need  to  be  updated

Prevent  – Security  Group  Inbound

Prevent  – Security  Group  Outbound

Prevent  – Security  Group  (CIS  Benchmark)4.4  Ensure  the  default  security  group  of  every  VPC  restricts  all  traffic

For  each  default  security  group,  perform  the  following:  1. Select  the  default  security  group  2. Click  the  Inbound  Rules  tab3. Ensure  no  rule  exist4. Click  the  Outbound  Rules tab5. Ensure  no  rules  exist

https://d0.awsstatic.com/whitepapers/compliance/AWS_CIS_Foundations_Benchmark.pdf

https://github.com/awslabs/aws-­security-­benchmark/tree/master/aws_cis_foundation_framework

Prevent  – Security  Group  (CIS  Benchmark)

Source  IP

Destination  IP

Source  port

Destination  port

Protocol Packets

Bytes Start/end  time

Accept  or  reject

Detect with VPC Flow Logs

Detect with VPC Flow Logs

Easy  to  setup,  will  identify  compromised  hosts  in  your  environment:

http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/flow-­logs.html#flow-­logs-­cw-­alarm-­example

[version,  account,  eni,  source,  destination,  srcport,  destport=”445",  protocol="6",  packets,  bytes,  windowstart,  windowend,  action="REJECT",  flowlogstatus]

AWS Inspector• Agent 기반 - 어플리케이션 보안 수준 진단• 보안 진단 결과 – 가이드 제공• API를 통한 자동화• Rule Package

• CVE (common vulnerabilities and exposures) – 수천개 항목• Network security best practices • Authentication best practices • Operating system security best practices • Application security best practices

Detect (& Prevent) with Third Parties

• Host Intrusion Detection Preventions (HIDS)

• Agent-based solution scales as instances scale

• Agent can be monitoring and controlled centrally

• Access to unencrypted data and process and user context

Host-based Security Host-based Security

Central Monitoringand Control

• 630247214269 eni-0123456a 10.0.1.221 10.76.2.101 27039 445 6 5 268 1466491141 1466491200 REJECT OK

?Web

InstanceWeb  

Instance

443  IN  |  3128  OUT 443  IN  |  3128  OUT

Respond with Automation

SnapshotWebInstance

Instance  AnomalyDetected

Amazon  EBSAmazon  EBS

MemDump

WebInstance

Forensics

Application VPC Cleanroom VPC

Share  SnapshotCreate  New  Volume  

443  IN  |  3128  OUT n/a  IN  |  n/a  OUT

질문에 대한 답변 드립니다.

발표자료/녹화영상 제공합니다.http://bit.ly/awskr-webinar

더 나은 세미나를 위해여러분의 의견을 남겨 주세요!