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
Content Security Policy 101 - Lightning Talk
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Christoph Rumpel
April 24, 2018
Technology
130
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Content Security Policy 101 - Lightning Talk
This is a 5min talk version of Content Security Policy 101 talk.
Christoph Rumpel
April 24, 2018
More Decks by Christoph Rumpel
See All by Christoph Rumpel
How To Manage 5000+ Tests Efficiently
christophrumpel
0
140
Christoph Dreams Of Simple Code (Laravel Vienna Meetup)
christophrumpel
0
200
Why Refactoring Is The Best Tool To Write Better Code
christophrumpel
0
610
Debugging with PhpStorm & XDebug
christophrumpel
0
300
The final Laravel Service Container talk (Laracon Online)
christophrumpel
1
820
NomadPHP - The Laravel Core - Demystify The Beast
christophrumpel
0
180
Laravel Factories Reloaded (Laracon Online)
christophrumpel
1
340
The Beauty of Laravel's Notification System (Laracon EU Amsterdam)
christophrumpel
0
280
The Laravel Core - Demystify The Beast (New York)
christophrumpel
0
240
Other Decks in Technology
See All in Technology
データベース研修【MIXI 26新卒技術研修】
mixi_engineers
PRO
1
670
セキュリティ研修【MIXI 26新卒技術研修】
mixi_engineers
PRO
31
25k
数値で見る Microsoft MVP 〜Spec Kit と GitHub Copilot Agent で作るデータ可視化ダッシュボード〜
yutakaosada
0
170
VPCセキュリティ対応の最新事情
nagisa53
1
350
plamo-3-translateの開発
pfn
PRO
0
150
論語・武士道・産業革命から見る かわるもの、かわらないもの
ichimichi
8
1.6k
SRENEXT_2026_Chairs__Talks_in_Tamachi.sre.pdf
srenext
1
170
ウォーターフォール開発案件のPMとしてAI活用を模索している話
hatahata021
2
200
ソフトウェアアーキテクチャ研修【MIXI 26新卒技術研修】
mixi_engineers
PRO
2
990
「待ち時間」の消滅と「自我消耗」の加速:生成AI時代のエンジニアを救うメンタル・リソース管理
poropinai1966
0
320
現場との対話から始める “作る前に問い直す”業務改善
mochico50
2
340
AI時代におけるエンジニアの新たな役割──FDEとクオリアの探求/登壇資料(戸井田 裕貴)
hacobu
PRO
0
660
Featured
See All Featured
Visualization
eitanlees
152
17k
Bridging the Design Gap: How Collaborative Modelling removes blockers to flow between stakeholders and teams @FastFlow conf
baasie
0
620
Leo the Paperboy
mayatellez
8
1.9k
Why Our Code Smells
bkeepers
PRO
340
58k
Designing Experiences People Love
moore
143
24k
Leveraging LLMs for student feedback in introductory data science courses - posit::conf(2025)
minecr
1
330
Building a A Zero-Code AI SEO Workflow
portentint
PRO
0
640
Collaborative Software Design: How to facilitate domain modelling decisions
baasie
1
270
Testing 201, or: Great Expectations
jmmastey
46
8.2k
Keith and Marios Guide to Fast Websites
keithpitt
413
23k
How to Get Subject Matter Experts Bought In and Actively Contributing to SEO & PR Initiatives.
livdayseo
0
160
Designing for Performance
lara
611
70k
Transcript
Hello webclerks :)
Content Security Policy 101
Content Security Policy 101 Can Christoph do 40 slides in
5 minutes?
ABOUT ME
CHRISTOPH RUMPEL Web Developer PHP / Laravel Chatbots Talks @christophrumpel
christoph-rumpel.com
SECURITY IS HARD
SSL Input Handling Updates Packages Extension CSRF NONCES Weak Typing
Error Handling Storing Credentials Server Access SQL Prepared Statements Passwords Brute Force Attacks
Adobe Playstation Network Cloudflare FAMOUS LEAKS
How can we protect our sites when even big companies
can't?
Step by step
CONTENT SECURITY POLICY
CSP lets you define trusted resources.
Content-Security-Policy: policies
Content-Security-Policy: img-src *; script-src 'self'; Policies EXAMPLE
img-src *; script-src 'self'; DIRECTIVES
img-src *; script-src 'self'; LOCATIONS
img-src *; script-src 'self'; TRANSLATED Images are allowed to be
loaded from any resource
img-src *; script-src 'self'; TRANSLATED Scripts are allowed to be
loaded from the current site's origin only
img-src script-src DIRECTIVES
img-src script-src style-src font-src media-src form-action ...
* 'self' LOCATIONS
* 'self' domain.example.com *.example.com 'none' ...
CSP christoph-rumpel.com
BROWSER SUPPORT
BROWSER SUPPORT
INTEGRATIONS
SERVER CONFIGURATION Apache
SERVER CONFIGURATION Nginx
LARAVEL MIDDLEWARE
WP Content Security Policy Plugin - Screenshot Policies PLUGINS
MUCH MORE
HASHES AND NONCES
REPORTING
Content Security Policy 101 Laravel Response Caching And CSP CSP,
Hash-Algorithm, and Turbolinks Quick CSP Reference Guide MDN web docs CSP Level 2 W3C Recommendation CSP Level 3 Working Draft RESOURCES
THANKS
QUESTIONS?
THANKS AGAIN