Professional Documents
Culture Documents
Debasis Mohanty
• A simple security guy who likes to solve complex security problems using simple methods
• The History:
Historical data shows we continue to see around two decades old security bugs
• The Reason:
Why do we still continue to see one to two decades old security bugs?
• The Solution:
The top two mitigation strategies to consider based on the past learnings
• The Misconception:
The Silver Bullet In Software Security Engineering
Let’s begin with the
history and look at the
State of Software Security
Vulnerabilities
The History:
• Buffer Overflow
As per Wikipedia: https://en.wikipedia.org/wiki/Buffer_overflow
• Buffer overflows were understood and partially publicly documented as early as 1972
• The earliest documented hostile exploitation of a buffer overflow was in 1988 (Morris worm)
• In 1996: Phrack magazine article "Smashing the Stack for Fun and Profit“ by Elias Levy (aka Aleph One)
• Observations:
• The majority of the bug
classes in the list have been
around two decades
• This list relates to bugs
affecting multiple
applications and software.
• The count of bugs across
each year may not necessarily
be accurate.
• However, you get an idea that
these bugs have been around
for a long period
• Conclusion:
Given that these bug classes
have been around for two
decades, it implies that
something is not right with how
the Industry has dealt with these
bugs.
Note: This may not be the most comprehensive list but you get the overall picture.
The Big Question
There are many reasons, but here we will discuss the two most prominent reasons.
The Two Most Prominent Reasons
The most common reason:
This bug is not my
problem; it is someone
else's problem.
The Reasons
The two most prominent reasons are obscured within the way the vast majority of the
Organisation responds to a bug report of the applications and software:
Note: While there are many reasons but here we will discuss the two most prominent reasons
Reason No. 1
Typical Response For A Bug Report
(of the applications and software you support)
• Fix exactly what is reported including any other instances of the same bug
• Fix based on the bugs risk rating but follow the second approach
You fix a reported bug but do not check for any bug You are likely to miss other instances and variants
instances or variants in the same application. of the same bug in the application (if they exist).
You follow the second approach but fix issues with Several historical evidence shows that bugs that
relatively higher risk ratings (e.g. critical/high/medium) but look low hanging or trivial can be combined with
do not fix any lower risk rating issue. other bugs to perform a more practical attack.
If such mitigation strategies resonate with your bug mitigation practices, you are far from making your application
and software resilient against known security bugs.
The Way “The Industry” Respond
Reason No. 2
The flow chart illustrates the most common approach across the industry while dealing with or responding to a bug report.
The Solution
The Solution
Tackling security vulnerabilities going forward based on the learnings from the past
The Solution No. 1
• Class of the bug can be described as the way a particular bug is exploited and/or it’s
resulting impact.
• Nature of the bug primarily relates to the root cause of the bug.
Note: The above list is not comprehensive. Instead, these are few examples provided as a guideline to understand the difference between a bug class and
the bug nature or the root cause.
The approach towards
mitigating and managing
security vulnerabilities
The Way “The Industry” Must Respond
To Any Publicly Reported Bugs
Root Cause Analysis and
Decoding The Nature of a
Bug
Decoding The Nature of a Bug (MS00-083)
CVE-2000-0817 (MS00-083): Buffer overflow in the HTTP protocol parser for Microsoft Network Monitor (Netmon)
allows remote attackers to execute arbitrary commands via malformed data, aka the "Netmon Protocol Parsing"
vulnerability.
Types of parsing
vulnerabilities Decoding The Nature of a Bug
(More Examples)
All these examples imply that any parser can have such security problems.
Recommendations
Based on learnings from the historical bug reports
• Combing Operation (to crack down on known security bugs)
• Treat every security bug report as important regardless of whether it affects your or another company software and dissect the
bug nature to take appropriate mitigation actions.
• Thoroughly go through the historical bug records in the CVE databases (cvedetails.com and cve.mitre.org) or similar vendor
databases, including the exploit databases (exploit-db.com), to identify all kinds of known bugs in your applications.
• Refer to the database for identifying potential risks in your existing application and during future design changes.
Learnings from the way memory corruption bugs have been brought under control
in OS, Web Browsers and OS-Native Apps
Behavioural v/s Non-
Behavioural Mitigation Typical Exploit and Defense In Depth
(Windows Edition)
Targeted Mitigation
(behavioural v/s non-behavioural checks)
Shellcode (Payload)
Shellcode (Payload)
Mark memory pages as non-
DEP / NX
executable
Behavioural v/s Non-
Behavioural Mitigation Targeted Exploit Mitigation
(Windows Edition)
Windows 10 Mitigation Available under exploit protection
Arbitrary code guard (ACG) yes
Block remote images yes
Block untrusted fonts yes
Data Execution Prevention (DEP) yes
Export address filtering (EAF) yes
Force randomization for images (Mandatory ASLR)
NullPage Security Mitigation
yes
yes (Included natively in Windows 10)
• Modern Operating Systems and Web
Randomize memory allocations (Bottom-Up ASLR)
Simulate execution (SimExec)
yes
yes
Browsers focuses on killing all known
Validate API invocation (CallerCheck)
Validate exception chains (SEHOP)
yes
yes
techniques used in an exploit
Validate stack integrity (StackPivot) yes
Certificate trust (configurable certificate pinning) Windows 10 provides enterprise certificate pinning
• In Web-based applications, the widely used mitigation techniques primarily focus on non-
behavioural checks against attacks.
Apache Apache
Kafka Kafka
ML Inference System
ML Model
The Misconception
Timeline 1985 1988 1999 2001 2002 2003 2004 2005 2006 2007 2009 2011 2012 2013 2014 2015 2017 2019 2021
Initial Industry
Waterfall
Adoption
1988: NIST SP 500-153 - Guide to Auditing for Controls and Security
2002: GIAC Paper - Security in the SDLC by Larry G
Security in Waterfall
2004: IEEE Publication: Software Security by G. McGraw
(Secure SDLC)
2004: The OWASP Testing Project v1.0
2006 (May): Microsoft Secure Development Lifecycle by Michael Howard and Steve Lipner
2001 2002 2003 2004 2005 2006 2007 2009 2011 2012 2013 2014 2015 2017 2019 2021
Agile Introduced
2005 (Dec): Secure Software Development Life Cycle Processes by Noopur Davis (Brief mention of Security in Agile)
Security in Agile
2006 (May): Microsoft Secure Development Lifecycle by Michael Howard and Steve Lipner
(Secure SDLC)
2006 (Aug): Department of Homeland Security - Security in the Software Lifecycle
2007 2009 2011 2012 2013 2014 2015 2017 2019 2021
Initial Industry
DevOps Ideation Introduced
Adoption
2012 (Jan): DevOpsSec: Creating the Agile Triangle (Gartner)
2012 (Apr): DevOpsSec Applying DevOps Principles to Security
(DevOpsDays Presentation)
Security in DevOps
2014 (Mar): OWASP Presentation - Continuous
(DevSecOps)
Security Testing in a DevOps World
2015 (Oct): AWS re:Invent - Architecting
for End-to-End Security in the Enterprise
The Misconception:
Security is better with
DevOps
The Paradigm Shift and
The Rise In Misconception
• Over the last few years, there has been a significant rise in the popularity of DevSecOps.
• However, without proper clarity on when to go for DevSecOps, there has also been an
increasing misconception about it.
Next-Gen Cool
Waterfall Agile DevOps ML/AI-Ops Software
(DevOps+ML) Engineering
Lifecycle Name??
Building Security into each software lifecycle = Common-Sense alignment of stage gate security activities
QA Penetration Testing
However, if you are migrating to DevOps because you thought or heard that the entire industry is migrating toward it,
then it is not a rational decision.
The analogy provided
here is meant to create
awareness, not to offend
anyone
The Herd Mentality
(Going with the flow without rational thinking)
There is no such Silver
Bullet in Software Security
Engineering
Building Security into the SDL
is always explicit, not implicit
• Building security into the software engineering lifecycle (Waterfall, Agile or DevOps)
is always explicit, not implicit.
• A fixed set of common-sense security activities exists that remains the same across all
types of development methodologies.
Final Words
• Treat all known security vulnerabilities as a pandemic, especially if they have
been around for over decades.
• No one wants Covid-19 to last for the next 20 years. The same feelings apply to
known security bugs.
• If some organisations here take away the suggestions to eradicate known bugs in
your applications and achieve success in eliminating them, then spread the word
and talk about your success.
• Your organisation's success story on eliminating all known bugs will inspire other
organisations and potentially lead to a global ripple effect.
• Let's reassess the state of known security bugs in about 20 years from now!!!
Questions