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
Drupal ParanoiaでDrupalをより安全に
Search
snize
October 12, 2018
Technology
0
100
Drupal ParanoiaでDrupalをより安全に
Drupal Meetup 羽田 #14 でのスライド
https://drupal-meetup-haneda.connpass.com/event/99066/
snize
October 12, 2018
Tweet
Share
More Decks by snize
See All by snize
Talking with drupal - psyshでの対話型デバッグ
snize
0
42
Other Decks in Technology
See All in Technology
Jitera Company Deck / JP
jitera
0
140
ecspressoの設計思想に至る道 / sekkeinight2025
fujiwara3
8
1.1k
QuickBooks®️ Customer®️ USA Contact Numbers: Complete 2025 Support Guide
qbsupportinfo
0
100
P2P通信の標準化 WebRTCを知ろう
faithandbrave
6
2.3k
AI駆動開発 with MixLeap Study【大阪支部 #3】
lycorptech_jp
PRO
0
180
株式会社島津製作所_研究開発(集団協業と知的生産)の現場を支える、OSS知識基盤システムの導入
akahane92
1
1.1k
Wasmで社内ツールを作って配布しよう
askua
0
110
データ駆動経営の道しるべ:プロダクト開発指標の戦略的活用法
ham0215
2
230
Introduction to Sansan, inc / Sansan Global Development Center, Inc.
sansan33
PRO
0
2.7k
Introduction to Sansan for Engineers / エンジニア向け会社紹介
sansan33
PRO
5
39k
Step Functions First - サーバーレスアーキテクチャの新しいパラダイム
taikis
1
270
QAを早期に巻き込む”って どうやるの? モヤモヤから抜け出す実践知
moritamasami
2
170
Featured
See All Featured
Mobile First: as difficult as doing things right
swwweet
223
9.7k
Principles of Awesome APIs and How to Build Them.
keavy
126
17k
Unsuck your backbone
ammeep
671
58k
Bootstrapping a Software Product
garrettdimon
PRO
307
110k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
53
2.9k
The World Runs on Bad Software
bkeepers
PRO
70
11k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
31
2.4k
Build your cross-platform service in a week with App Engine
jlugia
231
18k
Become a Pro
speakerdeck
PRO
29
5.4k
Being A Developer After 40
akosma
90
590k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
194
16k
Optimising Largest Contentful Paint
csswizardry
37
3.3k
Transcript
あなたのDrupalのディレクトリ構成は安全ですか?
Drupal Paranoiaで Drupalをより安全に 金子 智嗣
[email protected]
の運営メンバ @snize Drupal Meetup
Tokyo
過去の脆弱性 2016年に というモジュールで 脆弱性 が発見された。 Coder SA-CONTRIB-2016-039
webからアクセス可能な場所にあるだけで脆弱性 となった。 The module does not need to be enabled
for this to be exploited. Its presence on the le system and being reachable from the web are su cient.
Demo 一般的DrupalプロジェクトのDocrootを確認 zip版 版(composer) drupal-project
他のWebフレームワークと比較 Symfony Quick Tour: The Architecture Directory Structure - Laravel
- The PHP Framework For Web Artisans CakePHP のフォルダー構成 - 3.6
Drupalと他のComposerなフレームワークとの違い
Drupal Paranoia 不要なファイルを削除し 必要なファイルへのみシンボリックリンクを生成する
なぜこのプラグインを使うか 楽しつつ、脆弱性を生まないようにするため。
Demo 準備します... 1. もとのDocrootを退避 2. composer.json の extra にコードを追加 3.
プラグインをインストール
もとのDocrootを退避 mv web app
composer.jsonを編集 "installer-paths": { "app/core": ["type:drupal-core"], "app/libraries/{$name}": ["type:drupal-library"], "app/modules/contrib/{$name}": ["type:drupal-module"], "app/profiles/contrib/{$name}":
["type:drupal-profile"], "app/themes/contrib/{$name}": ["type:drupal-theme"], "drush/contrib/{$name}": ["type:drupal-drush"] }, "drupal-app-dir": "app", "drupal-web-dir": "web",
プラグインをインストール composer require drupal-composer/drupal- paranoia:~1
変化を見てみる 1. /app 2. /web
まとめ Drupal Paranoiaによって web(docroot) 以下が 必要最小限のファイルに置き換えられ 不用意なアクセスからDrupalを守ることができる。
おまけ Drupal Paranoiaは のプロジェクトのひとつ Core doesn't embrace Composer best practices
OOTB Figure out how to separate php code from assets in modules and in core so that code can be vendored, and assets under the docroot. Drupal Composer Proposal: Composer Support in Core initiative [#2958021] | Drupal.org
以上です、ありがとうございました ( ω ) コンタクト @tomotsugu_kaneko -
[email protected]
次回 2018/11/01
@snize drupal-japan.slack.com Drupal Meetup Tokyo - connpass