Skip to content

Latest commit

 

History

History
278 lines (197 loc) · 21.3 KB

File metadata and controls

278 lines (197 loc) · 21.3 KB

Changelog

All notable changes to Context Menu Doctor are documented here.


[2.11.0] — 2026-02-07

Added

  • Comprehensive HTML Report (option 10). Complete rewrite: now includes system info header (OS, PS, admin, version), summary dashboard (total/third-party/risk/cloud/disabled/diagnostic issues), cloud service status section with recommendations, full handler inventory with expandable CLSID/DLL/registry detail rows, and Extended Diagnostics summary (icon overlays, network drives, thumbnail cache, ShellNew count, Offline Files, Explorer health, system RAM, AV, static verb dead entries).
  • Get-CloudProblems helper function. Extracted cloud-service-stopped detection into reusable function used by startup summary, handler table, and report.
  • V (Verify Signatures) MS/third-party tagging. Per-DLL progress now shows MS tag for Microsoft handlers, signer name after each check, and summary breaks down signed count by Microsoft vs third-party.

Fixed

  • Startup "problems found" count mismatch. Count now includes both risk-based problems AND cloud-service-stopped handlers, matching what Show-HandlerTable -ProblemsOnly displays. Previously the count could differ from the table contents.

[2.10.1] — 2026-02-07

Fixed

  • Menu border alignment. Rewrote Get-VisualExtra with targeted emoji width compensation: ⚡ (+1, wide BMP), ✅ (+1, wide BMP), 🏷 (−1, narrow SMP). Fixes misaligned right borders on rows 5F, 6, 7, O, header title bar, and opening logo. All 13 two-column rows, 4 full-width rows, header, and logo verified at exactly 84 columns.

[2.10.0] — 2026-02-07

Added

  • Cascading Menu Depth Audit (CM). Scans 8 shell verb roots for context menu entries that create flyout cascading submenus via SubCommands, ExtendedSubCommandsKey, or nested shell subkeys. Detects depth levels (1-level vs 2+ deep nesting), counts child items per cascade, validates CommandStore references for dead sub-commands, checks nested command paths for missing executables. Reports total cascading entries, sub-items, deep nesting warnings, and dead sub-commands with color-coded severity.

Fixed

  • ShellNew Manager performance. Replaced Get-ChildItem -Path 'Registry::HKEY_CLASSES_ROOT' (which created full key objects for ALL 20,000+ HKCR entries and hung) with two-phase approach: Phase 1 probes ~100 known file extensions directly (<100ms), Phase 2 uses .NET GetSubKeyNames() for any stragglers. 10-50x faster.

Changed

  • Menu layout: Option 9 (Re-scan) moved under SCAN & VIEW section. Right column reorganized: blank after 5F, then 6/7/8/8A contiguous, then blank, then P/O/V grouped. Option 11 relabeled to "Restart Explorer". TOOLS section split into two rows to prevent overflow.
  • Function count: 43 (was 42).

[2.9.0] — 2026-02-07

Added

  • Context Menu Appearance & Style (W). Expanded from Win11-only toggle to comprehensive appearance tool with 5 settings: (1) Win11 Classic/Modern toggle, (2) Menu popup delay via MenuShowDelay (0-1000ms with presets), (3) Menu animation toggle (fade/slide via UserPreferencesMask bit manipulation), (4) Dark/Light app theme toggle (controls context menu colors), (5) Transparency toggle (acrylic/blur effects). Shows all current settings color-coded with explanations.
  • Diagnostic 11 — Static Verb Entries. Scans 5 shell roots (*\shell, Directory\shell, Directory\Background\shell, Folder\shell, Drive\shell) for context menu verb commands pointing to missing executables. Dead verbs cause delays as Windows tries to verify each .exe on right-click.
  • Diagnostic 12 — 'Open With' Dead Entries. Audits HKCR\Applications for entries referencing uninstalled applications. Dead entries clutter the "Open with" submenu and add registry read overhead.
  • Diagnostic 13 — Explorer Process Health. Checks Explorer.exe for: memory usage (>800MB = warning), handle count (>5000 = warning), uptime (>1 week = info), not-responding state. Recommends Explorer restart when issues detected.
  • CopyHookHandlers scanning. Added Directory\shellex\CopyHookHandlers and Folder\shellex\CopyHookHandlers to secondary scan paths. These intercept file copy/move/delete and can cause Explorer freezes.

Changed

  • Extended diagnostics now runs 13 checks (was 10).
  • Menu label for W changed from "Win11 Menu" to "🎨 Style" to reflect expanded functionality.

[2.8.0] — 2026-02-07

Added

  • Menu redesign: merged CLOUD FIX, BACKUP, and TOOLS sections. Cloud restart options moved out of two-column area into dedicated merged rows. BACKUP section collapsed from 3 rows to 1 merged row. Right column freed up for O (Overlays), 9 (Re-scan), V (Signatures). Cleaner visual hierarchy.
  • Cloud Others sub-menu (C). Detects and offers restart for 6 additional cloud sync services: iCloud Drive, Box Drive, Nextcloud, pCloud, MEGA, Synology Drive. Shows installed/running status, launches dead backends, or force-restarts healthy ones.
  • Windows 11 classic context menu toggle (W). Sets/removes {86ca1aa0-34aa-4e8b-a509-50c905bae2a2}\InprocServer32 to bypass 'Show more options'. Detects current state, shows explanation, no admin needed (HKCU only). Prompts for Explorer restart after toggle.
  • ShellNew manager (SN). Scans all HKCR file extensions for ShellNew subkeys. Lists all right-click → "New" submenu entries with extension, friendly name, and creation method (NullFile/Template/Command/Data). Color-codes common types (green) vs potential bloat (yellow). Disable renames key to ShellNew-ContextMenuDoctor (reversible). Active/disabled counts shown.
  • Context menu response timer (RT). Loads all active third-party handler DLLs via COM instantiation — identical to what Explorer does on right-click. Shows per-handler time with color coding (green <100ms, yellow <500ms, red >500ms). Bar chart of top 5 slowest. Saves history to timer-history.json for before/after comparison — shows improvement or regression vs previous measurement.

[2.7.1] — 2026-02-07

Fixed

  • Box width corrected from 98═ to 84═ inner. The 98═ borders were far wider than content (LW=34/RW=35=69 chars), leaving 29 chars of dead space per line. Reduced to 84═ inner with LW=41/RW=42 columns (+7 per column from original). All 32 full-width borders + 2 column dividers + 40 hardcoded content lines updated.
  • Cloud detection broadened. Option 3 now matches cloud handlers by handler name, DLL path, company, AND description via regex patterns (was 5 exact handler names only). Catches Google Drive variants regardless of exact handler name registration.
  • Emoji visual width compensation (Get-VisualExtra). BMP emoji chars (⚡⏱⚠✅✓✗) render 2-wide in terminal but .Length=1. New script-level function compensates in: banner PadRight, menu header, info bar, Write-MenuRow, Write-MenuFull.
  • Info bar closed with . Was open-ended (no right border), visually overflowing past box edge. Now tracks segment lengths with emoji compensation and closes properly.

[2.7.0] — 2026-02-07

Added

  • OneDrive restart option (OD). Health check & restart — same pattern as Google DriveFS (G). Detects dead/hung OneDrive, shows process state (count, memory, age, responding), kills all processes, relaunches from detected install path.
  • Dropbox restart option (DB). Health check & restart for Dropbox. Same functionality as G and OD.
  • Known offenders expanded to 25+ entries. Added: FileSyncShell, OneDriveContextMenu, SkyDriveShell (OneDrive), iCloudExt, iCloudDriveShell (iCloud), BoxShellExt (Box Drive), NextcloudExt (Nextcloud).
  • Cloud detection patterns expanded to 6 services. Option 3 now detects dead backends for: Google Drive, Dropbox, OneDrive, iCloud, Box Drive, Nextcloud.

Changed

  • Menu width extended +7 per column. Left column: 41→48, Right column: 42→49, Inner width: 84→98. All static borders widened to 102 chars (98═ inner) across all sub-screens. Info bar dynamically pads to match.

[2.6.2] — 2026-02-07

Fixed

  • Cloud detection in option 3 now uses broad pattern matching. Previously matched only 5 exact handler names, missing Google Drive variants. Now matches handler name, DLL path, company, AND description via regex patterns. Covers Google Drive (3 process names), Dropbox, OneDrive (including SkyDrive legacy), and iCloud.
  • Menu info bar closed with . Was open-ended, visually overflowing past the right border. Now tracks segment lengths with emoji compensation and closes properly.
  • Emoji visual width compensation. New Get-VisualExtra function (script-level) calculates BMP chars that render 2 columns wide in terminal but have .Length=1. Applied to: banner PadRight, menu header, info bar, Write-MenuRow, and Write-MenuFull.

Changed

  • Get-VisualExtra extracted to script-level function (was nested in Show-MainMenu). Now 36 functions total.

[2.6.1] — 2026-02-07

Fixed

  • All box borders standardized to 74 chars (70═ inner) matching banner/menu width. Previously sub-screens (benchmark, binary search, diagnostics, admin warning, first-run backup, etc.) used 72 chars (68═). Now consistent everywhere.
  • Benchmark timing accuracy. Stopwatch now runs INSIDE the Start-Job scriptblock, measuring only COM [Activator]::CreateInstance() time. Previously measured full job lifecycle including PowerShell process spawn overhead (~1-2s per handler), dramatically inflating reported times.
  • Signature verify details moved to D press. Summary now shows only signed/unsigned counts. Company grouping with handler lists AND per-DLL details (paths, signers, status) all appear only when pressing D. Previously company names appeared before the D prompt.

[2.6.0] — 2026-02-07

Added

  • Two-column menu with emojis and color gradients. Left column: SCAN & VIEW (DarkCyan) + DIAGNOSE (Magenta). Right column: FIX (DarkYellow) + BACKUP (Green). TOOLS (10/11/0) merged into single-column footer row.
  • Option 6 lists disabled handlers before prompting for enable number — shows handler #, name, context type, and description (matching option 8 UX).
  • Signature verification compact summary. Signed DLLs grouped by signer company with handler list. Full per-DLL details (path, signer CN, status) only on pressing D.
  • Benchmark info box explains cold vs warm DLL load times (OS file cache, 2-10x difference after reboot).

Changed

  • Menu width matched to banner (74 chars total = 2 indent + ╔ + 70 inner + ╗).
  • Banner uses dynamic .PadRight() for version-safe alignment.
  • Menu uses ╠═══╦═══╣ column divider with emojis restored per item.

[2.5.0] — 2025-02-07

Added

  • Option V (Verify Signatures) now shows all signed DLLs grouped by signer company, not just the unsigned ones. Each signer shows a count and handler list.
  • Option 3 (Problems Only) now detects cloud service issues. Checks if Google DriveFS, Dropbox, or OneDrive handlers exist but their process isn't running — a guaranteed source of right-click hangs. Also includes Microsoft BROKEN handlers and disabled-by-us handlers in the results.
  • Persistent header in main menu showing OS, PowerShell version, admin status, handler count, broken count, and disabled count — always visible above the menu.

Fixed

  • Disabled handlers vanishing from the list. Scan checked for valid GUID-format CLSID before checking disabled state — blanked entries were silently skipped. Now checks disabled state first, uses saved OriginalCLSID from state file for display.
  • Re-enable failing with "key or CLSID not found." Fallback path constructed Registry::$regPath\... but $regPath already had the prefix — double prefix never exists.
  • All box borders standardized to 72 columns. 83+ border lines fixed across banner, scan, benchmark, binary search, disable-all test, extended diagnostics, cloud warning, DriveFS, and overlay manager boxes. Emojis removed from inside bordered lines (variable terminal width). Dynamic content uses .PadRight() for runtime alignment.

Changed

  • Disabled handlers show in list with OFF status in magenta, dimmed line, and hint: "use option 6 to re-enable, or 8/8A to undo."
  • Menu redesigned to two-column layout. Scan & View + Fix in left/right columns, Diagnose + Backup & Tools below. Saves 12 vertical lines.
  • Banner uses dynamic .PadRight() instead of fixed spacing — version string changes won't break alignment.
  • Menu refined: Two-column layout with double-border matching banner width (74 cols). Emojis and color gradients restored per section (DarkCyan scan, Magenta diagnose, DarkYellow fix, Green backup). TOOLS row (10 HTML report, 11 Restart Explorer, 0 Exit) merged into single-column footer row. BACKUP section (K, L, 9) stays in right column.
  • Option 6 (Enable handler) now lists all disabled handlers with their # and description before prompting for input, matching the UX of option 8.
  • Option V (Verify signatures) summary-first: Compact colorful results show immediately (unsigned flagged in red, signed grouped by short signer name with handler list). Full per-DLL details (path, signer CN, status) only shown on pressing D.

[2.4.1] — 2025-02-07

Fixed

  • DriveFS diagnostic crashed on thread count — Process.Threads is a ProcessThreadCollection, not a number. Now correctly sums .Threads.Count per process.
  • CscService (Offline Files) check was confusingly placed under the Antivirus diagnostic section. Moved to its own subsection "8b. Offline Files Service."
  • ShellNew scan now shows progress — "Checking 98 known extensions..." with dots every 20 extensions.
  • Version numbers were out of sync across the file header (synopsis said v2.2.0, .NOTES said v2.0.0). All three locations now match.

Changed

  • Removed AI attribution from file header.
  • Updated feature list in script description to reflect current capabilities.
  • Added clarifying comment above #Requires -Version 3.0 (PowerShell minimum, not script version).

Added

  • LICENSE file with dual-license terms (free personal, paid commercial).

[2.4.0] — 2025-02-07

Added

  • Session-scoped undo (options 8 / 8A). Every disable now records a SessionId (timestamp + random suffix). Option 8 only undoes handlers disabled in the current run. Option 8A undoes all sessions. If nothing was disabled this session, shows previous sessions and directs to 8A.
  • Google DriveFS Health Check & Restart (option G). Detects hung, not-responding, and high-memory DriveFS processes. Kills all GoogleDriveFS/GoogleDriveSync processes, finds the executable, relaunches, and retests responsiveness.
  • DriveFS responsiveness test. Background job with 5-second timeout runs Get-ChildItem on the virtual drive. Returns OK, SLOW, or HUNG.
  • Process-based service detection. When disabling a handler, the tool now checks if the related process (GoogleDriveFS, Dropbox) is running — not just Windows services. Warns if the process is missing (handler will hang) or running (will lose integration features).
  • DriveFS deep diagnostic in extended diagnostics (section 6b) — hung detection, memory leak check, thread count, minifilter driver detection.

Fixed

  • ShellNew scan — fourth and final fix. Previous attempts all triggered HKCR enumeration (wildcard search, Get-ChildItem, reg query). Now directly probes ~100 known extensions with Test-Path. Total runtime under 100ms regardless of HKCR size.

[2.3.0] — 2025-02-06

Added

  • In-program backup restore (option L). Lists full backups and handler backups with timestamps. R = restore full backup (imports all .reg files), H = restore handler backup, F = open backup folder.
  • Force-disable Microsoft handlers (option 5F). Maps handlers to Windows services (CscService, LanmanServer). Checks service status, warns about feature loss, requires typing "FORCE" to confirm.
  • Icon Overlay Manager (option O). Windows limits to 15 icon overlays — excess overlays cause slow folder loads. Lists all overlays with priority order, allows disabling extras.
  • Antivirus real-time scan diagnostic — detects Windows Defender exclusion paths and third-party AV products (Norton, McAfee, Kaspersky, Bitdefender, etc.).
  • Offline Files (CscService) diagnostic — detects stopped-but-not-disabled CscService causing folder property sheet hangs.
  • Extended diagnostics expanded to 10 checks (up from 9).
  • Default view now shows third-party only (option 1). Use option 2 for all handlers.

Fixed

  • ShellNew HKCR enumeration hang (third occurrence of the same root cause). Switched from Get-ChildItem to reg query text output with regex filtering.
  • Backup list parser error — colons in backup directory names were breaking PowerShell variable expansion.

[2.2.0] — 2025-02-05

Added

  • Registry ownership takeover. Enables SeTakeOwnershipPrivilege via P/Invoke, takes ownership of TrustedInstaller-owned registry keys, grants Administrators full control. Required for force-disabling some Microsoft handlers.
  • Key rename disable method (option 5R). Renames the handler's registry key with a -DISABLED suffix instead of just blanking the CLSID. Survives application re-registration since the app writes to the original key name which no longer exists.
  • Persistence detection (option P). Scans scheduled tasks, Run/RunOnce keys, Windows services, and COM AppID entries for sources that automatically re-register a handler's CLSID. Shows PowerShell commands to disable each persistence source.
  • Auto persistence check runs after every disable operation.
  • Benchmark output now explains that STA COM threading means handlers load sequentially — the total benchmark time equals the actual right-click delay.

[2.1.0] — 2025-02-04

Added

  • Extended Diagnostics (option X). Nine additional checks beyond shell extensions: icon overlays (15 limit), network drive mapping, thumbnail cache, ShellNew entries, Quick Access pinned items, cloud connectivity, DNS speed, system performance, proxy/firewall.
  • Cloud service TCP connectivity test with 3-second timeout. Tests Google Drive, OneDrive, Dropbox, Adobe Creative Cloud, iCloud, and Box endpoints. Detects unreachable servers that add 21-30 second TCP timeouts.
  • DNS resolution speed check.
  • Proxy and firewall detection.
  • Disk free space and SSD/HDD detection.

[2.0.0] — 2025-02-03

Added

  • Auto-elevate to Administrator. Detects non-admin at startup, offers to re-launch with elevation. Clear ACCESS DENIED messages with re-launch instructions.
  • Disable-All Quick Test (option T). Temporarily disables all third-party handlers, user tests right-click, then re-enables everything. Confirms whether handlers are the cause before making any permanent changes.
  • Benchmark ALL including Microsoft (option BA).
  • Batch Signature Check (option V). Authenticode verification for all handler DLLs. Flags unsigned or tampered files.

[1.3.0] — 2025-01-28

Added

  • COM instantiation benchmark engine. Times each handler's DLL load via CoCreateInstance in a runspace with configurable timeout. Shows milliseconds per handler and total.
  • Binary Search Diagnostic (option S). Automated guided hunt — disables half the handlers, user tests, tool narrows down. Approximately 5 rounds to pinpoint the exact culprit. Context-aware filtering by File/Folder/Desktop target.
  • Auto-restore guarantee via finally block — all handlers restored even on Ctrl+C or script abort.

[1.2.2] — 2025-01-25

Added

  • Context Type column in handler list — shows whether the handler applies to Files, Folders, Desktop, or Drives (parsed from registry path).

[1.2.1] — 2025-01-24

Added

  • Live progress dots during scan so the user can see it's working.
  • DLL path shown as sub-line for all third-party handlers in list view.
  • Version numbering ($Script:Version) for tracking file copies.

Fixed

  • Detail view crash caused by nested array flattening. @(@("Name","val") @("CLSID","val2")) produces a flat array of strings, not an array of pairs. Fixed with unary comma operator.

[1.1] — 2025-01-22

Fixed

  • Scan hanging for 5+ minutes. The -Path parameter on HKCR\* was treated as a wildcard glob, causing PowerShell to enumerate all 20,000+ HKCR keys before filtering. Switched to -LiteralPath everywhere.
  • Scan taking 60-150 seconds. Get-AuthenticodeSignature performs online CRL/OCSP revocation checks at 2-5 seconds per DLL. Deferred to on-demand detail view. Scan now uses VersionInfo.CompanyName and system path heuristics.

[1.0] — 2025-01-20

Added

  • Initial release.
  • Scans 10+ registry locations for context menu shell extension handlers.
  • CLSID to DLL resolution with path verification.
  • Known offenders database (17 entries).
  • Risk scoring: BROKEN, HIGH, MEDIUM, UNKNOWN, LOW, OK, SAFE.
  • Microsoft vs third-party detection (company name + system path heuristics).
  • Interactive menu: scan, view, disable, enable, auto-fix, undo-all.
  • Disable method: blank CLSID value (instant, reversible) with JSON state tracking.
  • Individual .reg backup per handler on disable.
  • Full registry backup on first run.
  • HTML report export with color-coded risk table.
  • Windows 7, 10, 11 compatible (PowerShell 3.0+).