|
| 1 | +<# |
| 2 | +.SYNOPSIS |
| 3 | + A GUI-based utility to forcefully stop, delete, and clean up the Adobe Genuine Service. |
| 4 | +.DESCRIPTION |
| 5 | + This script now actively hunts and terminates known Adobe background processes before attempting to delete service files. |
| 6 | +.NOTES |
| 7 | + Version: 1.2.0.0 |
| 8 | + Author: Zachary Whiteman & Google Gemini AI |
| 9 | + Changes: |
| 10 | + - Added a pre-emptive strike against common Adobe background processes (e.g., CoreSync, CCXProcess). |
| 11 | +#> |
| 12 | + |
| 13 | +#================================================================================ |
| 14 | +# SCRIPT INITIALIZATION AND DEPENDENCY CHECK |
| 15 | +#================================================================================ |
| 16 | + |
| 17 | +# Self-elevate the script to run as Administrator |
| 18 | +if (-NOT ([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole]::Administrator)) { |
| 19 | + Start-Process PowerShell -Verb RunAs -ArgumentList ("-NoProfile -ExecutionPolicy Bypass -File `"{0}`"" -f $MyInvocation.MyCommand.Path) |
| 20 | + exit |
| 21 | +} |
| 22 | + |
| 23 | +# Load necessary .NET assemblies for the GUI |
| 24 | +Add-Type -AssemblyName System.Windows.Forms |
| 25 | +Add-Type -AssemblyName System.Drawing |
| 26 | + |
| 27 | +# Enable visual styles to make the GUI match the system theme |
| 28 | +[System.Windows.Forms.Application]::EnableVisualStyles() |
| 29 | + |
| 30 | +#================================================================================ |
| 31 | +# GUI CREATION |
| 32 | +#================================================================================ |
| 33 | + |
| 34 | +# Main Form |
| 35 | +$mainForm = New-Object System.Windows.Forms.Form |
| 36 | +$mainForm.Text = "Adobe Genuine Service Remover v1.2" |
| 37 | +$mainForm.Size = New-Object System.Drawing.Size(420, 250) |
| 38 | +$mainForm.StartPosition = "CenterScreen" |
| 39 | +$mainForm.FormBorderStyle = 'FixedSingle' |
| 40 | +$mainForm.MaximizeBox = $false |
| 41 | + |
| 42 | +# Status Label |
| 43 | +$statusLabel = New-Object System.Windows.Forms.Label |
| 44 | +$statusLabel.Location = New-Object System.Drawing.Point(10, 10) |
| 45 | +$statusLabel.Size = New-Object System.Drawing.Size(380, 20) |
| 46 | +$statusLabel.Text = "Status: Ready for process termination..." |
| 47 | +$mainForm.Controls.Add($statusLabel) |
| 48 | + |
| 49 | +# Output Text Box (for detailed logs) |
| 50 | +$outputBox = New-Object System.Windows.Forms.TextBox |
| 51 | +$outputBox.Location = New-Object System.Drawing.Point(10, 40) |
| 52 | +$outputBox.Size = New-Object System.Drawing.Size(380, 120) |
| 53 | +$outputBox.Multiline = $true |
| 54 | +$outputBox.ScrollBars = "Vertical" |
| 55 | +$outputBox.ReadOnly = $true |
| 56 | +$mainForm.Controls.Add($outputBox) |
| 57 | + |
| 58 | +# Removal Button |
| 59 | +$removeButton = New-Object System.Windows.Forms.Button |
| 60 | +$removeButton.Location = New-Object System.Drawing.Point(140, 170) |
| 61 | +$removeButton.Size = New-Object System.Drawing.Size(120, 30) |
| 62 | +$removeButton.Text = "Kill & Nuke" |
| 63 | +$mainForm.Controls.Add($removeButton) |
| 64 | + |
| 65 | +# Function to update the log |
| 66 | +function Write-Log { |
| 67 | + param($message) |
| 68 | + $timestamp = Get-Date -Format "HH:mm:ss" |
| 69 | + $outputBox.AppendText("[$timestamp] $message`r`n") |
| 70 | + $outputBox.SelectionStart = $outputBox.Text.Length |
| 71 | + $outputBox.ScrollToCaret() |
| 72 | + $mainForm.Update() |
| 73 | +} |
| 74 | + |
| 75 | +#================================================================================ |
| 76 | +# CORE LOGIC |
| 77 | +#================================================================================ |
| 78 | + |
| 79 | +$removeButton.Add_Click({ |
| 80 | + $removeButton.Enabled = $false |
| 81 | + $statusLabel.Text = "Status: In progress..." |
| 82 | + |
| 83 | + try { |
| 84 | + # --- PRE-EMPTIVE STRIKE on known Adobe background processes --- |
| 85 | + $knownProcesses = @("AdobeIPCBroker", "CCXProcess", "CCLibrary", "CoreSync", "AGMService", "AdobeCollabSync", "AdobeGCClient", "Adobe Genuine Helper", "Adobe Genuine Launcher", "AGSService", "AGCInvokerUtility", "agshelper",) |
| 86 | + Write-Log "Hunting for known Adobe background processes..." |
| 87 | + foreach ($procName in $knownProcesses) { |
| 88 | + $process = Get-Process -Name $procName -ErrorAction SilentlyContinue |
| 89 | + if ($process) { |
| 90 | + Write-Log "Found process '$procName'. Terminating..." |
| 91 | + Stop-Process -Name $procName -Force |
| 92 | + Write-Log "Process '$procName' terminated." |
| 93 | + } |
| 94 | + } |
| 95 | + Write-Log "Process hunt complete." |
| 96 | + |
| 97 | + # --- Service Deletion (will fail if already gone, which is OK) --- |
| 98 | + $serviceNames = @("AdobeIPCBroker", "CCXProcess", "CCLibrary", "CoreSync", "AGMService", "AdobeCollabSync", "AdobeGCClient", "Adobe Genuine Helper", "Adobe Genuine Launcher", "AGSService", "AGCInvokerUtility", "agshelper",) |
| 99 | + foreach ($serviceName in $serviceNames) { |
| 100 | + Write-Log "Checking for service: $serviceName..." |
| 101 | + if (Get-Service -Name $serviceName -ErrorAction SilentlyContinue) { |
| 102 | + Write-Log "Attempting to delete service '$serviceName'..." |
| 103 | + sc.exe delete $serviceName | Out-Null |
| 104 | + Write-Log "Delete command sent for service '$serviceName'." |
| 105 | + } else { |
| 106 | + Write-Log "Service '$serviceName' not found or already deleted." |
| 107 | + } |
| 108 | + } |
| 109 | + |
| 110 | + # --- File Deletion --- |
| 111 | + $targetDir = "$env:ProgramFiles(x86)\Common Files\Adobe\AdobeGCClient" |
| 112 | + Write-Log "Checking for directory: $targetDir" |
| 113 | + if (Test-Path $targetDir) { |
| 114 | + Write-Log "Directory found. Attempting to remove..." |
| 115 | + try { |
| 116 | + Remove-Item -Path $targetDir -Recurse -Force -ErrorAction Stop |
| 117 | + Write-Log "SUCCESS: Directory successfully removed." |
| 118 | + } catch { |
| 119 | + Write-Log "ERROR: Failed to remove directory. $_.Exception.Message" |
| 120 | + } |
| 121 | + } else { |
| 122 | + Write-Log "Directory not found. Nothing to remove." |
| 123 | + } |
| 124 | + |
| 125 | + $statusLabel.Text = "Status: Removal process completed!" |
| 126 | + Write-Log "------------------------------------" |
| 127 | + Write-Log "Process finished." |
| 128 | + |
| 129 | + } catch { |
| 130 | + $statusLabel.Text = "Status: A critical error occurred!" |
| 131 | + Write-Log "ERROR: $($_.Exception.Message)" |
| 132 | + } finally { |
| 133 | + $removeButton.Enabled = $true |
| 134 | + } |
| 135 | +}) |
| 136 | + |
| 137 | +#================================================================================ |
| 138 | +# SHOW THE GUI |
| 139 | +#================================================================================ |
| 140 | + |
| 141 | +[void]$mainForm.ShowDialog() |
0 commit comments