Skip to content

Add basic macOS driver updater implementation - #295

Merged
JusterZhu merged 1 commit into
masterfrom
feature/macos-implementation-issue-294
May 23, 2026
Merged

Add basic macOS driver updater implementation#295
JusterZhu merged 1 commit into
masterfrom
feature/macos-implementation-issue-294

Conversation

@JusterZhu

Copy link
Copy Markdown
Collaborator

Summary

Replace the pure-placeholder macOS updater with a working BaseDriverUpdater subclass.

Changes

MacOsGeneralDrivelution

  • Now inherits BaseDriverUpdater (was throwing PlatformNotSupportedException on every method)
  • InstallCoreAsync: .kext (kextload + kextcache), .dext (systemextensionsctl), .pkg (installer)
  • RollbackAsync: restores backed-up kext files to /Library/Extensions/ and reloads via kextload
  • Driver discovery: finds .kext, .dext, .pkg files, parses CFBundleVersion from Info.plist
  • sudo check pipeline step

MacOSDriverValidator

  • Hash validation: delegates to HashValidator (file I/O, works on all platforms)
  • Signature validation: uses codesign tool with -v / --deep verification
  • Compatibility: delegates to CompatibilityChecker

MacOSDriverBackup

  • Pure .NET file copy/restore/delete (no macOS-specific APIs)
  • Supports both file and directory (kext bundle) backup

Factory

  • DrivelutionFactory.Create now returns a working MacOsGeneralDrivelution on macOS
  • IsPlatformSupported() returns true for macOS

Limitations

  • .kext requires SIP disabled on Apple Silicon (Apple deprecation)
  • .dext requires user approval in System Preferences

Closes #294

- MacOsGeneralDrivelution now inherits BaseDriverUpdater (was pure throw placeholder)
- InstallCoreAsync: supports .kext (kextload), .dext (systemextensionsctl), .pkg (installer)
- MacOSDriverValidator: hash via HashValidator, signature via codesign tool, compatibility via CompatibilityChecker
- MacOSDriverBackup: file-level copy/restore/delete using pure .NET I/O
- RollbackAsync: restores backed-up kext files via kextload
- DrivelutionFactory: macOS now creates working instance instead of throwing
- IsPlatformSupported: macOS now returns true

Closes #294
Copilot AI review requested due to automatic review settings May 23, 2026 11:16
@JusterZhu
JusterZhu merged commit 52934de into master May 23, 2026
1 check failed
@JusterZhu
JusterZhu deleted the feature/macos-implementation-issue-294 branch May 23, 2026 11:17
@JusterZhu
JusterZhu removed the request for review from Copilot May 23, 2026 11:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add basic macOS driver updater implementation

1 participant