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
Plugin Security
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Brad Parbs
July 26, 2014
Technology
3
150
Plugin Security
Brad Parbs
July 26, 2014
Tweet
Share
More Decks by Brad Parbs
See All by Brad Parbs
Learn to Love the Terminal
bradp
0
700
Extremely Powerful Local WordPress Development with Vagrant and Friends
bradp
1
180
Extremely Powerful Local WordPress Development with Vagrant and Friends - WordCamp Grand Rapids 2014
bradp
1
320
Web414 - Writing Clean, Clear, & Semantic Markup with HTML5
bradp
0
410
WordCamp Baltimore - Let's Get Sassy!
bradp
2
510
Starter Themes for Appleton WordPress Meetup
bradp
1
190
#WCGR - Getting SASSy
bradp
4
290
#WCPVD - Getting SASSy
bradp
2
290
WordCamp Chicago 2013 - Template Hiearchy
bradp
1
170
Other Decks in Technology
See All in Technology
会社紹介資料 / Sansan Company Profile
sansan33
PRO
16
410k
社内レビューは機能しているのか
matsuba
0
160
AI実装による「レビューボトルネック」を解消する仕様駆動開発(SDD)/ ai-sdd-review-bottleneck
rakus_dev
0
160
OSC仙台プレ勉強会 AlmaLinuxとは
koedoyoshida
0
190
【Λ(らむだ)】最近のアプデ情報 / RPALT20260318
lambda
0
120
【Oracle Cloud ウェビナー】【入門編】はじめてのOracle AI Data Platform - AIのためのデータ準備&自社用AIエージェントをワンストップで実現
oracle4engineer
PRO
1
180
WebアクセシビリティをCI/CDで担保する ― axe DevTools × Playwright C#実践ガイド
tomokusaba
2
190
Goのerror型がシンプルであることの恩恵について理解する
yamatai1212
1
260
Bill One 開発エンジニア 紹介資料
sansan33
PRO
5
18k
OCHaCafe S11 #2 コンテナ時代の次の一手:Wasm 最前線
oracle4engineer
PRO
2
150
ガバメントクラウドにおけるAWSの長期継続割引について
takeda_h
2
5.4k
Lambda Web AdapterでLambdaをWEBフレームワーク利用する
sahou909
0
180
Featured
See All Featured
Money Talks: Using Revenue to Get Sh*t Done
nikkihalliwell
0
180
Unsuck your backbone
ammeep
672
58k
Balancing Empowerment & Direction
lara
5
950
Reflections from 52 weeks, 52 projects
jeffersonlam
356
21k
The Hidden Cost of Media on the Web [PixelPalooza 2025]
tammyeverts
2
250
Public Speaking Without Barfing On Your Shoes - THAT 2023
reverentgeek
1
340
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
21
1.4k
Imperfection Machines: The Place of Print at Facebook
scottboms
269
14k
StorybookのUI Testing Handbookを読んだ
zakiyama
31
6.6k
Intergalactic Javascript Robots from Outer Space
tanoku
273
27k
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
16
1.9k
Discover your Explorer Soul
emna__ayadi
2
1.1k
Transcript
Security for Your Plugins
I’m Brad Parbs.
Nathan, you should watch Band of Brothers.
Let’s talk about what sucks in WordPress.
None
None
“20% of the 50 most popular WordPress plugins are vulnerable
to common Web attacks. This amounts to nearly 8 million downloads of vulnerable plugins.” Checkmarx, an application security company
Things that happen when your stuff isn’t secure.
None
How do we make sure this doesn’t happen?
Always develop with debugging ON
define( 'WP_DEBUG', true ); define( 'WP_DEBUG_DISPLAY', false );
define( 'WP_DEBUG_LOG', true ); define( 'SCRIPT_DEBUG', true ); define( 'WP_CACHE', false );
Sanitize all the things
intval(); absint();
wp_kses();
sanitize_title();
sanitize_email() sanitize_file_name() sanitize_html_class() sanitize_key() sanitize_meta()
sanitize_mime_type() sanitize_option() sanitize_sql_orderby() sanitize_post_field() sanitize_text_field() sanitize_title() sanitize_title_for_query() sanitize_title_with_dashes() sanitize_user()
Escape all the things
esc_html();
esc_textarea();
esc_attr();
esc_url();
http://codex.wordpress.org/Data_Validation
Database Queries
$wpdb-‐>insert();
$wpdb-‐>update();
$wpdb-‐>prepare();
Nonces
wp_nonce_url();
wp_nonce_field();
wp_create_nonce();
check_admin_referer();
wp_verify_nonce();
Remote Data
CURL is bad.
For real, CURL is bad.
wp_remote_get();
wp_remote_post();
wp_remote_request();
Check capabilities & roles
current_user_can();
Use native functions
A story about TimThumb
Questions?
None