SlideShare a Scribd company logo
Introduction to Web Security
What is Web Security?
Why Web Security?
Top 10 PHP application vulnerabilities 2016
Information Leakage
app environment, user specific data
‱ Restrict PHP information leakage
‱ Configuration files
– Configuration files should be in php not .ini, xml, etc
– Secure App config variables by storing on server
‱ Separate your back up files from root directory
HTTP/1.x 200 OK
Date: Sun, 21 Aug 2016 16:08:15 GMT
Server: Apache
X-Powered-By: PHP/5.5.26
...
Man-in-the-Middle Attack
A B
SSL
How does HTTPS works?
This presume
User Accessing Secure Site
Requesting Secure
SSL connection from
Website Host.
Website Records Found.
Going to the Host Web Server.
Check DNS for IP address to
find Web host
Host responds with
valid SSL certificate.
Secure connection is
established to transfer data
WebHost.
Injection Attacks
‱ Cross Site Scripting - XSS
‱ SQL Injection
‱ Code Injection
‱ Command Injection
‱ Log Injection
‱ XML Injection
SQL Truncation Exploit
Compromise user login
‱ SELECT * FROM user WHERE username='admin ’
‱ Username = ‘admin x’
‱ $userdata = null;
if (isPasswordCorrect($username, $password)) {
$userdata = getUserDataByLogin($username); ... }
SELECT username FROM users WHERE username = ? AND
passhash = ?
SELECT * FROM users WHERE username = ?
Solution:
– Mysql strict mode
– Unique constraint column
But what if you find you have been
hacked
‱ Don’t panic
‱ Check logs (error /access)
‱ Check suspicious file names
‱ Check cron jobs
‱ search source code for keywords like: eval,
base64_decode, wget, curl
‱ take DB backup & search for keywords like
“iframe, script,
”
‱ Prepare yourself to reinstall your entire server
How to Prevent
‱ Check OWASP
‱ Use STRONG Password hash
‱ Error Reporting
– Prodcution – OFF
– Development / Other – ON
‱ Stay up-to-date
– Framework
– OS
– 3rd party libraries
– Read about new threats and best practice changes
‱ Try to run vulnerabilities scanner
Thank You
https://www.linkedin.com/in/jeyasel
vi
@jeyaselvir

More Related Content

PPTX
Spa Secure Coding Guide
PPTX
Web Exploitation Security
PPTX
Group18_Awesome4some:Proxy server.ppt
PDF
HTTPS: What, Why and How (SmashingConf Freiburg, Sep 2015)
PPTX
FI-WARE Account and OAuth solution
PPTX
PPTX
HTTPS at Sydney Alt.Net User Group
PPT
Proxy Servers
Spa Secure Coding Guide
Web Exploitation Security
Group18_Awesome4some:Proxy server.ppt
HTTPS: What, Why and How (SmashingConf Freiburg, Sep 2015)
FI-WARE Account and OAuth solution
HTTPS at Sydney Alt.Net User Group
Proxy Servers

What's hot (20)

PPT
Firewall with proxy server.
PPT
Proxy Servers & Firewalls
PPTX
Adding Identity Management and Access Control to your Application
PPTX
Demystifying REST
PDF
Design and Analyze Secure Networked Systems - 3
PDF
Hack proof your ASP NET Applications
PPTX
Web Cache Poisoning
PPT
Proxy server
PPTX
Apache mod security 3.1
PPTX
DDD Melbourne 2014 security in ASP.Net Web API 2
PPT
Php security
PPTX
Securing Single Page Applications with Token Based Authentication
PPTX
Adding Identity Management and Access Control to your Application, Authorization
PPT
Cache poisoning
PPTX
Demystfying secure certs
PPT
Proxy Servers
PPTX
Cm2 secure code_training_1day_data_protection
PPTX
Cm8 secure code_training_1day_security libraries
PDF
10 tips to improve your website security
PDF
How to Secure Your WordPress Site
 
Firewall with proxy server.
Proxy Servers & Firewalls
Adding Identity Management and Access Control to your Application
Demystifying REST
Design and Analyze Secure Networked Systems - 3
Hack proof your ASP NET Applications
Web Cache Poisoning
Proxy server
Apache mod security 3.1
DDD Melbourne 2014 security in ASP.Net Web API 2
Php security
Securing Single Page Applications with Token Based Authentication
Adding Identity Management and Access Control to your Application, Authorization
Cache poisoning
Demystfying secure certs
Proxy Servers
Cm2 secure code_training_1day_data_protection
Cm8 secure code_training_1day_security libraries
10 tips to improve your website security
How to Secure Your WordPress Site
 
Ad

Viewers also liked (20)

ODP
Top 10 Web Security Vulnerabilities
PDF
Web Security 101
PPTX
Web Security
PPTX
Web Security
PDF
Web Security - Introduction v.1.3
PDF
Top 10 Web App Security Risks
KEY
ONE Conference: Vulnerabilities in Web Applications
PDF
Security and Privacy on the Web in 2016
PDF
Nullcon Jailbreak CTF 2012,Walkthrough by Team Loosers
PDF
Remote File Inclusion (RFI) Vulnerabilities 101
PPT
Top Ten Proactive Web Security Controls v5
PDF
Web Security
PPT
Php & Web Security - PHPXperts 2009
KEY
Introduction to web security @ confess 2012
PPT
Security in Web 2.0, Social Web and Cloud
PDF
Web Security
PDF
Cisco Study: State of Web Security
PDF
Evolution Of Web Security
PDF
How to Prevent RFI and LFI Attacks
PDF
Local File Inclusion to Remote Code Execution
Top 10 Web Security Vulnerabilities
Web Security 101
Web Security
Web Security
Web Security - Introduction v.1.3
Top 10 Web App Security Risks
ONE Conference: Vulnerabilities in Web Applications
Security and Privacy on the Web in 2016
Nullcon Jailbreak CTF 2012,Walkthrough by Team Loosers
Remote File Inclusion (RFI) Vulnerabilities 101
Top Ten Proactive Web Security Controls v5
Web Security
Php & Web Security - PHPXperts 2009
Introduction to web security @ confess 2012
Security in Web 2.0, Social Web and Cloud
Web Security
Cisco Study: State of Web Security
Evolution Of Web Security
How to Prevent RFI and LFI Attacks
Local File Inclusion to Remote Code Execution
Ad

Similar to Introduction to Web security (20)

PPTX
Lesson 6 web based attacks
PPT
IIS-training-document-internal-users.ppt
PPT
IIS internet information service NSA.ppt
PDF
How to Harden the Security of Your .NET Website
 
PPTX
Add a web server
PDF
Essential Security Practices for Modern Web Developers.pdf
PPT
Pentesting web applications
PDF
Going Beyond Cross Domain Boundaries (jQuery Bulgaria)
PPTX
hardenning Operating System Server Berbasis Linux
PPTX
Application and Server Security
PDF
Windows Hosting Documentation
PDF
AOEconf17: Application Security
 
PDF
AOEconf17: Application Security - Bastian Ike
 
PDF
OWASP Portland - OWASP Top 10 For JavaScript Developers
PDF
Building Client-Side Attacks with HTML5 Features
PPTX
Basics of web technologies
PDF
BeEF_EUSecWest-2012_Michele-Orru
PPT
Identifying Web Servers: A First-look Into the Future of Web Server Fingerpri...
PDF
Krzysztof Kotowicz - Hacking HTML5
Lesson 6 web based attacks
IIS-training-document-internal-users.ppt
IIS internet information service NSA.ppt
How to Harden the Security of Your .NET Website
 
Add a web server
Essential Security Practices for Modern Web Developers.pdf
Pentesting web applications
Going Beyond Cross Domain Boundaries (jQuery Bulgaria)
hardenning Operating System Server Berbasis Linux
Application and Server Security
Windows Hosting Documentation
AOEconf17: Application Security
 
AOEconf17: Application Security - Bastian Ike
 
OWASP Portland - OWASP Top 10 For JavaScript Developers
Building Client-Side Attacks with HTML5 Features
Basics of web technologies
BeEF_EUSecWest-2012_Michele-Orru
Identifying Web Servers: A First-look Into the Future of Web Server Fingerpri...
Krzysztof Kotowicz - Hacking HTML5

Recently uploaded (20)

PPTX
history of c programming in notes for students .pptx
PPTX
CHAPTER 12 - CYBER SECURITY AND FUTURE SKILLS (1) (1).pptx
PDF
How to Choose the Right IT Partner for Your Business in Malaysia
PDF
top salesforce developer skills in 2025.pdf
PDF
Raksha Bandhan Grocery Pricing Trends in India 2025.pdf
PDF
Internet Downloader Manager (IDM) Crack 6.42 Build 42 Updates Latest 2025
PDF
Navsoft: AI-Powered Business Solutions & Custom Software Development
PDF
Design an Analysis of Algorithms II-SECS-1021-03
PDF
Upgrade and Innovation Strategies for SAP ERP Customers
PDF
Addressing The Cult of Project Management Tools-Why Disconnected Work is Hold...
PDF
Why TechBuilder is the Future of Pickup and Delivery App Development (1).pdf
PPTX
ai tools demonstartion for schools and inter college
PDF
System and Network Administration Chapter 2
PPTX
Introduction to Artificial Intelligence
PPTX
Odoo POS Development Services by CandidRoot Solutions
PDF
Internet Downloader Manager (IDM) Crack 6.42 Build 41
PDF
Flood Susceptibility Mapping Using Image-Based 2D-CNN Deep Learnin. Overview ...
PPTX
Operating system designcfffgfgggggggvggggggggg
PDF
System and Network Administraation Chapter 3
PDF
AI in Product Development-omnex systems
history of c programming in notes for students .pptx
CHAPTER 12 - CYBER SECURITY AND FUTURE SKILLS (1) (1).pptx
How to Choose the Right IT Partner for Your Business in Malaysia
top salesforce developer skills in 2025.pdf
Raksha Bandhan Grocery Pricing Trends in India 2025.pdf
Internet Downloader Manager (IDM) Crack 6.42 Build 42 Updates Latest 2025
Navsoft: AI-Powered Business Solutions & Custom Software Development
Design an Analysis of Algorithms II-SECS-1021-03
Upgrade and Innovation Strategies for SAP ERP Customers
Addressing The Cult of Project Management Tools-Why Disconnected Work is Hold...
Why TechBuilder is the Future of Pickup and Delivery App Development (1).pdf
ai tools demonstartion for schools and inter college
System and Network Administration Chapter 2
Introduction to Artificial Intelligence
Odoo POS Development Services by CandidRoot Solutions
Internet Downloader Manager (IDM) Crack 6.42 Build 41
Flood Susceptibility Mapping Using Image-Based 2D-CNN Deep Learnin. Overview ...
Operating system designcfffgfgggggggvggggggggg
System and Network Administraation Chapter 3
AI in Product Development-omnex systems

Introduction to Web security

  • 2. What is Web Security? Why Web Security?
  • 3. Top 10 PHP application vulnerabilities 2016
  • 4. Information Leakage app environment, user specific data ‱ Restrict PHP information leakage ‱ Configuration files – Configuration files should be in php not .ini, xml, etc – Secure App config variables by storing on server ‱ Separate your back up files from root directory HTTP/1.x 200 OK Date: Sun, 21 Aug 2016 16:08:15 GMT Server: Apache X-Powered-By: PHP/5.5.26 ...
  • 6. SSL How does HTTPS works? This presume User Accessing Secure Site Requesting Secure SSL connection from Website Host. Website Records Found. Going to the Host Web Server. Check DNS for IP address to find Web host Host responds with valid SSL certificate. Secure connection is established to transfer data WebHost.
  • 7. Injection Attacks ‱ Cross Site Scripting - XSS ‱ SQL Injection ‱ Code Injection ‱ Command Injection ‱ Log Injection ‱ XML Injection
  • 8. SQL Truncation Exploit Compromise user login ‱ SELECT * FROM user WHERE username='admin ’ ‱ Username = ‘admin x’ ‱ $userdata = null; if (isPasswordCorrect($username, $password)) { $userdata = getUserDataByLogin($username); ... } SELECT username FROM users WHERE username = ? AND passhash = ? SELECT * FROM users WHERE username = ? Solution: – Mysql strict mode – Unique constraint column
  • 9. But what if you find you have been hacked ‱ Don’t panic ‱ Check logs (error /access) ‱ Check suspicious file names ‱ Check cron jobs ‱ search source code for keywords like: eval, base64_decode, wget, curl ‱ take DB backup & search for keywords like “iframe, script,
” ‱ Prepare yourself to reinstall your entire server
  • 10. How to Prevent ‱ Check OWASP ‱ Use STRONG Password hash ‱ Error Reporting – Prodcution – OFF – Development / Other – ON ‱ Stay up-to-date – Framework – OS – 3rd party libraries – Read about new threats and best practice changes ‱ Try to run vulnerabilities scanner