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
Vuls v0.23.0-beta Windows Support@Vuls祭り#7
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
MaineK00n
February 24, 2023
9.9k
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Vuls v0.23.0-beta Windows Support@Vuls祭り#7
MaineK00n
February 24, 2023
More Decks by MaineK00n
See All by MaineK00n
Vuls開発者による小話@Vuls祭り#9
mainek00n
0
530
How_to_Write_and_Distribute_Security_Advisories_OpenSSF_Day_Japan_2023.pdf
mainek00n
0
77
ネットワーク機器における脆弱性検知の取り組みと課題_JANOG52.pdf
mainek00n
0
42
Vuls Major Update - user friendly and new feature custom advisory @ Black Hat MEA 2022
mainek00n
0
31
Vuls and MITRE ATT&CK @ CODE BLUE 2022
mainek00n
0
60
Vuls のアップデート情報と未来 @ Vuls祭り#6
mainek00n
0
190
Vuls2020 at AVTOKYO2020 HIVE
mainek00n
0
150
Featured
See All Featured
エンジニアに許された特別な時間の終わり
watany
107
250k
What’s in a name? Adding method to the madness
productmarketing
PRO
24
4.1k
The SEO identity crisis: Don't let AI make you average
varn
0
480
The Cult of Friendly URLs
andyhume
79
6.9k
BBQ
matthewcrist
89
10k
Impact Scores and Hybrid Strategies: The future of link building
tamaranovitovic
0
300
Data-driven link building: lessons from a $708K investment (BrightonSEO talk)
szymonslowik
1
1.1k
Optimising Largest Contentful Paint
csswizardry
37
3.7k
Claude Code どこまでも/ Claude Code Everywhere
nwiizo
65
56k
How to Get Subject Matter Experts Bought In and Actively Contributing to SEO & PR Initiatives.
livdayseo
0
140
Leading Effective Engineering Teams in the AI Era
addyosmani
9
2k
16th Malabo Montpellier Forum Presentation
akademiya2063
PRO
0
140
Transcript
Vuls v0.23.0-beta Windows Support MaineK00n @ Vuls祭り#7
$whoami MaineK00n • Twitter: @MaineK00n • 所属: フューチャー株式会社 †懺悔†🪦 Windows
support PR の master への Merge は間に合いませんでした…… すいませんでした…… 2
DEMO
自分の環境で動かしてみたい方へ 1. vuls, gost の binary を手に入れよう a. https://github.com/future-architect/vuls/releases/tag/v0.23.0-beta b.
https://github.com/vulsio/gost/releases/tag/v0.4.2 2. gost.exe fetch microsoft 3. config.tomlを書こう 4. vuls.exe scan 5. vuls.exe report 4
DEMO: ローカルスキャン $ cat .\config.toml $ .\vuls.exe scan localhost $
.\vuls.exe report $ .\vuls.exe tui 5
DEMO: リモートスキャン # sshd $ ssh -i C:\Users\nakaoka3503\.ssh\id_rsa
[email protected]
$
.\vuls.exe scan remote $ .\vuls.exe report MEMO: Client: linux vuls → Remote Host: windows; Client: windows vuls → Remote Host: linux みたいなケースも出来るはず 6
DEMO: サーバスキャン $ .\vuls.exe server $ cat systeminfo.txt $ curl.exe
-X POST -H "Content-Type: text/plain" -H "X-Vuls-OS-Family: windows" --data-binary "@systeminfo.txt" http://localhost:5515/vuls | .\jq.exe 7
Windowsにおける検知の話
どんな脆弱性情報を利用してる? 脆弱性情報は MSRC CVRF と BulletinSearch を使っています 更新プログラムの置き換え情報は 上記の2つに加えて,更新プログラムのオフラインスキャンで利用される Wsusscn2.cabの情報も取り入れています
これらの情報からデータフィードを作成しています. GitHub: vulsio/windows-vuln-feed で公開しています! 誤りなど見つけたら,issue いただけると助かります. 9 MSRC CVRF: https://api.msrc.microsoft.com/cvrf/v2.0/swagger/index BulletinSearch: https://download.microsoft.com/download/6/7/3/673E4349-1CA5-40B9-8879-095C72D5B49D/BulletinSearch.xlsx, https://download.microsoft.com/download/6/7/3/673E4349-1CA5-40B9-8879-095C72D5B49D/BulletinSearch2001-2008.xlsx Wsusscn2.cab: https://catalog.s.download.windowsupdate.com/microsoftupdate/v6/wsusscan/wsusscn2.cab vulsio/windows-vuln-feed: https://github.com/vulsio/windows-vuln-feed
gost (go-security-tracker) 10 vulsio/gost: https://github.com/vulsio/gost
方針 CVE-2022-34708 を検知するには…… Products[].Name と Article の情報が あれば検知できそう! 次にOSとKBの情報を求める. MEMO:
Windows 10以前はMonthly Rollup と Security Only の2種類が配布さ れていた Monthly Rollup が未適用でも,Security Only が適用済みなら KBの適用状況は修正済みとなる( ←知らなくてバグった) Windows 10からはrevisionと累積更新の仕組みがメインに 11
Scanner: OS OS Version: 10.0 + Configuration: Workstation ⇒ Windows
10 OS Build: 19044 ⇒ 21H2 System Type ⇒ x64-based ↓ Windows 10 Version 21H2 for x64-based Systems MEMO: registry, Get-Computerinfo など様々な手法がある 12
Scanner: KB systeminfo.exe の Hotfix(s) 部分 累積更新の仕組みを利用して 19044.2364 ⇒ KB5021233
まで適用済み OS Version: 10.0.19044 + applied KB: KB5021233 であれば,19044.2364 以上と 考えられる MEMO: systeminfo.exe の hotfix 部分は表示限界があるらしい Get-Hotfix, Windows Update APIなど様々な手法がある 13
Detector: KBの展開 累積更新の仕組みを利用して 未適用な KB を探す Monthly Rollup なら 直線になりそうなもの
だが,調べてみると複雑なグラフをしてい る MEMO: KB の置き換え情報が途絶えがちなので vulsio/windows-vuln-feed では 置き換え情報を手動で 追記できるようにしている 14 https://vuls.biz/blog/articles/20220313a/
Detector: OS, KBs で Filter データフィードをOSとKBsで走査する 見つかったものが Fixed CVE となる
Unfixed CVE の場合,KBs が記述されない 15
Detector: Microsoft Edge データフィードから Edge 部分を抜粋 プロダクト名が統一されてなかったり, 修正バージョンが FAQs に書いてあるだけ……
Edge を例に出したが,他のプロダクト Officeなど も同様にひどい……( ˃̣̣̣̣̣̣ ω ˂̣̣̣̣̣̣ )オンオン 正直,OS以外でKBを利用しないケースは 非常に難しい感じ 16
お願い # 検証結果募集中! 私は普通に動くWindowsマシンを持っていませんので,検証が不十分な可能性があります. ドキュメントが不十分!動かん!分からん!と思ったら,GitHub IssueやSlackに投げてください. # vulsやgost, vulsio/windows-vuln-feed を使っていて怪しいかも?と思ったら
とりあえず,@MaineK00n に声をかけてもらえれば (Twitter; GitHub Issue; Slack; E-Mail 1. vuls, gostでバグっている(誤検知している,思ったような結果が得られない 2. vulsio/windows-vuln-feedでバグっている(KBの置き換えが途切れている 3. データソースでバグっている(Microsoft に連絡しよう,もっとCVRFが使えるように…… # 将来的には Microsoft製品 や 3rd-Party Software の検知にも挑戦したい Scanner の情報収集能力で不十分なところ 収集結果とデータフィードをどう合致させるか? 3rd-Party Software は CPE で検知? 17