Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
macOS におけるエンドポイントセキュリティの取り組み
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
Kyohei Mizumoto
September 28, 2021
Technology
300
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
macOS におけるエンドポイントセキュリティの取り組み
Infra Study 2nd #5「低レイヤーの世界への誘い」のLT登壇資料です。
https://forkwell.connpass.com/event/222932/
Kyohei Mizumoto
September 28, 2021
More Decks by Kyohei Mizumoto
See All by Kyohei Mizumoto
ソフトウェアサプライチェーンの構造的リスクとコンテナ環境の保護
kyohmizu
5
1.4k
最新の脅威動向から考える、コンテナサプライチェーンのリスクと対策
kyohmizu
1
1.1k
コンテナセキュリティの最新事情 ~ 2026年版 ~
kyohmizu
9
4.4k
Black Hat USA 2025 Recap ~ クラウドセキュリティ編 ~
kyohmizu
0
1k
CTFのためのKubernetes入門
kyohmizu
3
1.3k
クラウドネイティブ環境の脅威モデリング
kyohmizu
3
870
コンテナサプライチェーンセキュリティ
kyohmizu
2
570
サイバーセキュリティの最新動向:脅威と対策
kyohmizu
1
480
コンテナセキュリティの基本と脅威への対策
kyohmizu
4
2.4k
Other Decks in Technology
See All in Technology
初対面のメンバーがチームを組み、Claude Codeでゼロからサービスをリリース
mkdev10
1
120
AIに攻撃される前に、AIに攻撃させる
tsuchikazu
0
170
DGX Spark でどこまでハッキングができるのか?
kash1064
0
620
freeeらしさをAIとともに作る / Creating the freee Experience with AI
ymrl
0
220
継続的なAIコスト最適化
bgpat
1
290
ハードウェアコンペでもAI駆動開発が進んでいる話
iotengineer22
1
690
全人類(ほぼ)AWS Organizations の上でAWSを利用している、その世界を知る話
htan
1
130
V8のArray.prototype.flatを最大約20倍速くするまでと、巨大OSSへの大規模コミットの道のり
riyaamemiya
0
260
味覇で作るパスタが美味い - 20261001_yabaubuki.dev
livesense
PRO
0
120
3つのアプローチで目指す チームを強くするAI駆動開発
thkt
0
160
子育てエンジニアの可処分時間が減っても成長を諦めない戦い方
sudoakiy
6
4.5k
DevelopersIO 2026 知識の地図を描く ─ オントロジーとは何か?
ishikawa_satoru
1
1.5k
Featured
See All Featured
AI in Enterprises - Java and Open Source to the Rescue
ivargrimstad
0
1.5k
Exploring the relationship between traditional SERPs and Gen AI search
raygrieselhuber
PRO
4
4.3k
The Pragmatic Product Professional
lauravandoore
37
7.5k
Documentation Writing (for coders)
carmenintech
77
5.6k
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
31
3.4k
How to build an LLM SEO readiness audit: a practical framework
nmsamuel
2
940
Visual Storytelling: How to be a Superhuman Communicator
reverentgeek
2
710
DevOps and Value Stream Thinking: Enabling flow, efficiency and business value
helenjbeal
2
410
AI: The stuff that nobody shows you
jnunemaker
PRO
10
1.1k
The browser strikes back
jonoalderson
0
1.8k
Believing is Seeing
oripsolob
1
240
State of Search Keynote: SEO is Dead Long Live SEO
ryanjones
0
310
Transcript
株式会社スリーシェイク macOS における エンドポイントセキュリティの取り組み
Copyrights©3-shake Inc. All Rights Reserved. 2 whoami 株式会社スリーシェイク Sreake事業部 業務内容
- SRE - AWS, GCP, terraform, kubernetes, etc... - CSIRT - セキュリティイベント対応 - 脆弱性評価 - サイバー演習、トレーニング実施 - イベント - 3-shake SRE Tech Talk 運営 コミュニティ活動 - CloudNative Days Tokyo 実⾏委員 ⽔元 恭平 (@kyohmizu)
About 3-Shake
Copyrights©3-shake Inc. All Rights Reserved. 4 About 3-Shake SRE ⽀援
/ 技術⽀援 サービス Sreake セキュリティ脆弱性診断 サービス Sreake Security クラウド型 ETL / データ パイプライン サービス Reckoner ハイスキル フリーランス 紹介サービス Relance Reckoner はクラウド型 ETL / データパイプライン サービ スです。 データベース・ストレージ・ アプリケーションなど、あら ゆるデータを統合・連携する ことで、データを活⽤したビ ジネス変⾰に貢献します。 Sreake Security は経験豊富 なセキュリティ専⾨家が貴社 の課題に合わせたセキュリテ ィ対策を⽀援するサービスで す。 Sreake は⾦融・医療・動画配 信・AI・ゲームなど技術⼒が 求められる領域で豊富な経験 を持つ SRE が集まったチーム による技術⽀援サービスです。 戦略策定から設計・構築・運 ⽤、SaaS 提供まで、幅広い 領域をサポートします。 Relance は、プロの現役エン ジニア集団が最適なエンジニ アを紹介するフリーランス エ ンジニア紹介サービスです。 技術⽀援や、 1on1 での定期 フォローなど、参画後も⾼い パフォーマンスを維持し続け られる体制を提供しています。
Copyrights©3-shake Inc. All Rights Reserved. 5 Sreake のエンジニアによる技術⽀援 技術戦略から設計、構築、運⽤までワンストップ⽀援する 技術⽀援サービス
技術戦略 コンサルティング システム 設計 構築 / 実装 ⽀援 アセスメント (パフォーマンス / セキュリティ) 運用支援 Multi Cloud や Cloud Native な先進的技術及び⼤規模なサービス運⽤に強みを持つエンジニアによる 技術⽀援 ベンダー的な役割ではなく「お客様の チームメンバー」という⽴ち位置で最新技術の提案から運⽤⽀援ま でをトータルご⽀援
Copyrights©3-shake Inc. All Rights Reserved. 6 Sreake SRE 導⼊ /
定着化⽀援 Enterprise を中⼼に様々な業種/業界で SRE を実践してきたナレッジを活かした SRE チームの導⼊及び定着化を⾏います お客様の組織に適合した SRE の導⼊を⽀援 SRE の組成/SRE ⽂化の定着化の為の⽀援
Copyrights©3-shake Inc. All Rights Reserved. 7 バグバウンティ の運⽤代⾏始めました 世界初︕「intigriti」社と提携、バグバウンティ運⽤代⾏サービス 「Bugty」をリリース
欧州を代表するバグバウンティプラットフォーム「intigriti」と世界で初めて提携。 SRE総合⽀援など⾼い技術⼒を持ったスリーシェイクのセキュリティエンジニアが、専⾨的な トリアージ・英語でのコミュニケーションなど運⽤を代⾏。 セキュリティ領域の専⾨家がいない、社内のリソースをかけられない企業もバグバウンティプ ログラムを展開できます。
macOS のエンドポイントセキュリティ
Copyrights©3-shake Inc. All Rights Reserved. 9 System Extensions と Endpoint
Security Framework System Extensions - ソフトウェアがKernelレベルのアクセスを必要とせずに、OSの機能を拡張できるようにしたもの - デバイスドライバ、ネットワーク、エンドポイントセキュリティ - 以前は Kernel Extensions が使⽤されていたが、安全性の観点から現在はサポート外 Endpoint Security Framework - システムイベントを監視するAPIのクライアント実装 - イベントタイプ - AUTH (Authorization) - NOTIFY https://knight.sc/reverse%20engineering/2019/08/24/system-extension-internals.html
Copyrights©3-shake Inc. All Rights Reserved. 10 モチベーション 既存のエンドポイントセキュリティでは対策しきれない部分をカバー - EDR製品は詳細な設定はできない
- 多層防御の1つとして取り⼊れる - セキュリティ要件の厳しい端末への導⼊ - Production リリース⽤の共⽤端末 - 組織のセキュリティポリシーに合わせたカスタマイズ - 特定のコマンド、ファイル操作の禁⽌など macOS 端末に対するより強固なセキュリティを実現
Copyrights©3-shake Inc. All Rights Reserved. 11 Endpoint Security Framework の関数定義
es_new_client_result_t es_new_client(es_client_t * _Nullable * _Nonnull client, es_handler_block_t _Nonnull handler); → 新規クライアント作成 es_return_t es_subscribe(es_client_t * _Nonnull client, const es_event_type_t * _Nonnull events, uint32_t event_count); → クライアントに受信するシステムイベントを登録 es_respond_result_t es_respond_auth_result(es_client_t * _Nonnull client, const es_message_t * _Nonnull message, es_auth_result_t result, bool cache); → ALLOW or DENY を設定 es_respond_result_t es_respond_flags_result(es_client_t * _Nonnull client, const es_message_t * _Nonnull message, uint32_t authorized_flags, bool cache); → フラグ値を設定(例︓FREAD = 0x00000001) 初期化 AUTHイベントへのレスポンス
Copyrights©3-shake Inc. All Rights Reserved. 12 メッセージ構造体 typedef struct {
uint32_t version; struct timespec time; uint64_t mach_time; uint64_t deadline; es_process_t * _Nonnull process; uint64_t seq_num; es_action_type_t action_type; union { es_event_id_t auth; es_result_t notify; } action; es_event_type_t event_type; es_events_t event; es_thread_t * _Nullable thread; uint64_t global_seq_num; uint64_t opaque[]; } es_message_t; // 一部抜粋、順不同 typedef enum { ES_EVENT_TYPE_AUTH_EXEC , ES_EVENT_TYPE_AUTH_OPEN , ES_EVENT_TYPE_AUTH_CREATE ... } es_event_type_t; // イベントタイプから適切なイベントを選択 typedef union { es_event_exec_t exec; es_event_open_t open; es_event_create_t create; ... } es_events_t;
Copyrights©3-shake Inc. All Rights Reserved. 13 サンプルコード(⼀部簡略化) static void handle_event(es_client_t
*client, const es_message_t *msg) { switch (msg->event_type) { case ES_EVENT_TYPE_AUTH_EXEC: handle_exec(client, msg); break; default: if (msg->action_type == ES_ACTION_TYPE_AUTH) { es_respond_auth_result(client, msg, ES_AUTH_RESULT_ALLOW, true); } break; } } static void handle_exec(es_client_t *client, const es_message_t *msg) { if (strcmp(msg->event.exec.target->signing_id.data, "com.apple.nc") == 0) { es_respond_auth_result(client, msg, ES_AUTH_RESULT_DENY, true); } else { es_respond_auth_result(client, msg, ES_AUTH_RESULT_ALLOW, true); } }
Copyrights©3-shake Inc. All Rights Reserved. 14 サンプル実⾏ $ systemextensionsctl list
1 extension(s) --- com.apple.system_extension.endpoint_security enabled active teamID bundleID (version) name [state] * * 262WUXV477 com.example.apple-samplecode.SampleEndpointApp262WUXV477.Extension (1.0/1) Extension [activated enabled] $ nc -l 9093 [1] 51623 killed nc -l 9093 ← netcatコマンドの実行を停止 $ nc -h [1] 51642 killed nc -h $ cp /usr/bin/nc ./testnc $ ./testnc -l 9999 [1] 51898 killed ./testnc -l 9999 ← バイナリをコピーしても実行できない
Copyrights©3-shake Inc. All Rights Reserved. 15 今回はここまで 今⽇話せなかったこと - System
Extensions の開発環境 - Apple Developer Program, Endpoint Security Entitlement の申請 - 実⾏に必要なOSの設定変更 - デバッグ、トラブルシュートの⽅法(システムログやクラッシュレポート) - より実践的なアプローチ - MITRE ATT&CK フレームワークを⽤いた操作制限の設定 - 組織のポリシーを実装に落とし込む - EDR, SIEM 等のセキュリティ製品との連携 - NOTIFY で適切なログを出⼒するなど
Copyrights©3-shake Inc. All Rights Reserved. 16 参考 https://developer.apple.com/system-extensions/ https://developer.apple.com/documentation/systemextensions https://developer.apple.com/documentation/endpointsecurity
https://developer.apple.com/documentation/endpointsecurity/monitoring_system_events_with_endpoi nt_security https://knight.sc/reverse%20engineering/2019/08/24/system-extension-internals.html https://attack.mitre.org/ https://github.com/redcanaryco/atomic-red-team/blob/master/atomics/Indexes/Indexes- Markdown/macos-index.md
Copyrights©3-shake Inc. All Rights Reserved. 17 ⼀緒に働きませんか?