最新の Windows 10 でのドライバー開発の基礎から
署名、Windows Update 配布までを一通り解説
IoT ALGYAN 運営委員
– Windows Development
Microsoft MVP
M V P
(当時、日本で2人 世界で20人弱)
MVP Global Summit 2006
今まで作った数:約300?
Windows, Linux, NETMF, FreeBSD, RTOS…
Windows 7 Sensor &
Location Platform
ツッコミ歓迎!
OS モジュール
• ファンクションドライバー
バスドライバー、フィルター
ドライバーの例は
GitHub Toaster サンプル参照
Universal Driver
WDM
WDF
UMDF2
KMDF
Windows Driver Model
Windows Driver Frameworks
いずれか
選択
Kernel Mode Driver Framework
User Mode Driver
Framework Version 2
UMDF2
KMDF
Kernel Mode Driver Framework
User Mode Driver
Framework Version 2
限定DDI等
の制約
ユーザーモード
カーネルモード
x64
WDM
UMDF 2.x
KMDF
UMDF 1.x
x86
ARM32
ARM64
ユニバーサル
ドライバー
Vistaの衝撃
Windows 98 のUSBが元
• ドライバー開発専用のモデル(アーキテクチャ)
NTはMicro Kernel
Open Source
実体はOSモジュールを切り出してドキュメント公開しただけ
同じアプリに
同一API を提供
アプリケーションは
ドライバーモデルを意識しない
例外有り:特定ドライバーは特定モデルでだけ記述可能
• ソースコードの互換性有り
デバッグ時に有用
• ドライバーバイナリー
• INF
• セキュリティカタログ
• INFとセキュリティカタログは必須
• PnP
• Devcon.exe
• txtsetup.oem
• インストール済パッケージ・フォルダー
• インストール・ログ
• Microsoft OS Descriptor
• .NET Frameworkの進化
★DOS APIとの決別
COM番号の心配不要
Windows.Devices.Adc Windows.Devices.I2c Windows.Devices.Scanners
Windows.Devices.AllJoyn Windows.Devices.Input Windows.Devices.Sensors
Windows.Devices.Background Windows.Devices.Lights Windows.Devices.SerialCommunication
Windows.Devices.Bluetooth Windows.Devices.Midi Windows.Devices.SmartCards
Windows.Devices.Custom Windows.Devices.Perception Windows.Devices.Sms
Windows.Devices.Display Windows.Devices.PointOfService Windows.Devices.Spi
Windows.Devices.Enumeration Windows.Devices.Portable Windows.Devices.Usb
Windows.Devices.Geolocation Windows.Devices.Power Windows.Devices.WiFi
Windows.Devices.Gpio Windows.Devices.Printers Windows.Devices.WiFiDirect
Windows.Devices.Haptics Windows.Devices.Pwm
Windows.Devices.HumanInterfaceDevice Windows.Devices.Radios
.NET Framework 4.8
• Windows 7
• Windows 8.1
• Windows Vista
SHA1→SHA256
Windows 10 Desktop カーネルは全ての
WDM,WDFドライバーが動作するが
IoT Coreなどではユニバーサルドライバーのみ
カーネルモードドライバーの環境事例
Target マシン-1 Target マシン-2
Host マシン-1
インターネット
セキュリティ
ファイアウォール
社内またはグループ内の
他のネットワーク環境
• ウィルスチェックやセキュリティ は特に
余計なソフトウェアやデバイスは一切入れない
SDK, WDKは常に最新版だけを使用
Visual Studioは最新版に更新
Windows Driver Kit (WinDBG などを含む)
サポート切れOS用ドライバー
の開発は最後の環境で
EV 証明書(会社登記、4~12万円)
1年間だけ有効
ドライバー署名用は
2021年7月終了
構成証明書署名 (Attestation signing)
EV 証明書(会社登記、4~12万円)一年間
英語版
PC 数台を使用して
数日から一週間かかるテスト
The Microsoft Public License (MS-PL)
2015に変更
• 特許請求の無効化
• 利用時は全ての著作権、特許、商標、および帰属
表示を保持
• ソースコード形式で頒布時、LICENSE表示を維持
ドライバーのコード分析
SAL
CATファイル設定時刻
これが正しくないとビルドエラー
• ドライバーパッケージ
構成証明書署名
https://docs.microsoft.com/windows-hardware/drivers/dashboard/register-for-the-hardware-program
https://github.com/Microsoft/Windows-driver-samples
• Wizard/Template でスケルトンドライバーがすぐ開発可能
• KMDF ドライバーをテンプレートで作成し、設定とビルド
• ファイル内容とプロパティを確認して下さい
• UMDF ドライバーをテンプレートで作成し、設定とビルド
• ファイル内容とプロパティを確認して下さい
ありがとうございました。

Windows 10 driver development