Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Escape From New York
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
Tom J Nowell
November 01, 2015
Technology
0
760
Escape From New York
A talk on escaping and security in WordPress and PHP
Tom J Nowell
November 01, 2015
Tweet
Share
More Decks by Tom J Nowell
See All by Tom J Nowell
Using Blocks Outside The Editor
tarendai
0
1.1k
Composer_and_WordPress__1_.pdf
tarendai
0
92
REST APIs for Absolute Beginners
tarendai
0
1k
VVV 2
tarendai
0
810
WordCamp Europe 2016 - Handling Anxiety
tarendai
1
510
WP The Right Way
tarendai
0
1.1k
Code Deodorant 2014
tarendai
1
760
Adv WP CLI
tarendai
0
740
WP CLI
tarendai
0
700
Other Decks in Technology
See All in Technology
CDK対応したAWS DevOps Agentを試そう_20260201
masakiokuda
1
340
広告の効果検証を題材にした因果推論の精度検証について
zozotech
PRO
0
190
Context Engineeringが企業で不可欠になる理由
hirosatogamo
PRO
3
620
Bedrock PolicyでAmazon Bedrock Guardrails利用を強制してみた
yuu551
0
240
会社紹介資料 / Sansan Company Profile
sansan33
PRO
15
400k
Introduction to Sansan, inc / Sansan Global Development Center, Inc.
sansan33
PRO
0
3k
小さく始めるBCP ― 多プロダクト環境で始める最初の一歩
kekke_n
1
450
OCI Database Management サービス詳細
oracle4engineer
PRO
1
7.4k
Agent Skils
dip_tech
PRO
0
120
Bill One急成長の舞台裏 開発組織が直面した失敗と教訓
sansantech
PRO
2
380
20260204_Midosuji_Tech
takuyay0ne
1
160
【Oracle Cloud ウェビナー】[Oracle AI Database + AWS] Oracle Database@AWSで広がるクラウドの新たな選択肢とAI時代のデータ戦略
oracle4engineer
PRO
2
170
Featured
See All Featured
Become a Pro
speakerdeck
PRO
31
5.8k
Navigating Weather and Climate Data
rabernat
0
110
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
333
22k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
234
17k
How to build an LLM SEO readiness audit: a practical framework
nmsamuel
1
650
How to Think Like a Performance Engineer
csswizardry
28
2.4k
The Spectacular Lies of Maps
axbom
PRO
1
520
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
46
2.7k
Java REST API Framework Comparison - PWX 2021
mraible
34
9.1k
Producing Creativity
orderedlist
PRO
348
40k
The Straight Up "How To Draw Better" Workshop
denniskardys
239
140k
コードの90%をAIが書く世界で何が待っているのか / What awaits us in a world where 90% of the code is written by AI
rkaga
60
42k
Transcript
Escape From New York Tom J Nowell
Validation Sanitisation Escaping
Validation: Is this what it claims to be?
Sanitisation: Lets clean up this input
Escaping: Making output safe
WordPress.com VIP VIP Wrangler - @tarendai
'; DROP TABLE votes'
Search Results For: <?php echo $_GET[‘s’]; ?>
Search Results For: <?php echo $_GET [‘s’]; ?>
<b>Test</b>
<b>Test</b>
<script>alert(“hey”);</script>
Search Results For: <?php echo esc_html( $_GET[‘s’] ); ?>
Search Results For: <?php echo esc_html( $_GET[‘s’] ); ?>
How to Escape
Sanitize early Escape Late Escape Often
No Data is Safe
<script src='//peniscorp.com/topkek.js'> </script>
Escape Everything..?
echo $var; echo esc_html( $var );
class=”<?php echo $css; ?>” class=”<?php echo esc_attr( $css ); ?>”
href=”<?php echo $url; ?>” href=”<?php echo esc_url( $url ); ?>”
wp_kses & wp_kses_post
echo apply_filters( ‘the_content’ wp_kses_post( $content ) );
tomjn.com/escaping
WordPress.com VIP VIP Wrangler - @tarendai
automattic.com/work-with-us/vip-wrangler/
Questions? Tom J Nowell - WordPress.com VIP @tarendai - tomjn.com