Commit 98265edb authored by Gabriel Moreau's avatar Gabriel Moreau
Browse files

Add Tweak UninstallkasperskyConsole and add ViewKasperskyProduct

parent 56727908
......@@ -109,21 +109,38 @@ Function TweakUninstallKasperskyEndpoint { # RESINFO
} Else {
Write-Host "Kaspersky Endpoint is not installed on this computer"
}
}
################################################################
# Suppress Kaspersky Console software
# Uninstall
Function TweakUninstallKasperskyConsole { # RESINFO
Write-Output "Uninstall software Kaspersky Console..."
# Remove Kaspersky Console, French GUID = {5D35D57A-30B9-493B-819F-C6C2181A0A1A}
$KesConsole = Get-WmiObject win32_product | Where { $_.Name -like "*Console*Kaspersky Security Center*" }
If ($KesConsole.IdentifyingNumber) {
Write-Output "Suppress Console Kaspersky Security Center..."
Start-Process "msiexec.exe" -ArgumentList "/X $($KesConsole.IdentifyingNumber) /qn" -Wait -NoNewWindow
Write-Host "Uninstall finish"
} Else {
Write-Host "Kaspersky Console is not installed on this computer"
}
}
################################################################
# View all Kaspersky Product
# View
Function TweakViewKasperskyProduct { # RESINFO
Write-Output "View all Kaspersky products..."
# Warning if another Kaspersky is still installed on the computer
Get-WmiObject win32_product | Where { $_.Name -like "*Kaspersky*" } | ForEach-Object {
Write-Host "Warning: the product $($_.IdentifyingNumber) is still installed: $($_.Name)"
Write-Host "Note: Product $($_.IdentifyingNumber) is installed: $($_.Name)"
}
}
# Install
#Function TweakInstallKasperskyEndpoint { # RESINFO
# Write-Output "Install software Kaspersky Endpoint protection..."
# Write-Output "Error: Empty function defined only for check"
# Write-Output "Error: use your deploiement software in order to install Kasperky Endpoint"
# Exit
#}
################################################################
###### Export Functions
......
......@@ -8,6 +8,8 @@ If needed, a specific tweak function must be written for security reasons.
New presets/rules:
* 2022/05/09 - `ViewKasperskyProduct` -> View all the Kaspersky product
* 2022/05/09 - `UninstallKasperskyConsole` -> Remove the Kaspersky Console
* 2022/03/16 - `UninstallKasperskyEndpoint` ([see more](dists/uninstall-kaspersky/)) - use Custom configuration module
* 2022/03/16 - `SetTargetRelease`/`UnsetTargetRelease` -> For fix the target Feature Update version ([see more](https://admx.help/?Category=Windows_10_2016&Policy=Microsoft.Policies.WindowsUpdate::TargetReleaseVersion))
* 2022/03/02 - `EnableClearPageFile`/`DisableClearPageFile` -> Clean PAGEFILE.SYS at shutdown
......
......@@ -253,5 +253,5 @@ RemoveFaxPrinter # AddFaxPrinter
# SysMessage
### Tweaks that needs to be classified ###
# UninstallKasperskyEndpoint
# UninstallKasperskyEndpoint # UninstallKasperskyConsole # ViewKasperskyProduct
# SetTargetRelease # UnsetTargetRelease # ViewTargetRelease
InstallKasperskyEndpoint
InstallKasperskyConsole
......@@ -8,6 +8,12 @@ However, removing such software is not easy because an antivirus
program always protects itself against viruses,
so the easy uninstallation...
**Warning**: There is another tweak, `UninstallKasperskyConsole`,
which allows you to remove the Kaspersky Console software.
This one is not uninstalled via the present scripts.
However, it is easy to adapt it or to make another equivalent
to also remove this console.
## Quick and Standalone version
There is an independent SWMB version of this tweak to make the
......
......@@ -21,5 +21,11 @@ SWMB_Init
# Unloads the tweak if it starts with the exclamation mark (!)
SWMB_AddOrRemoveTweak "UninstallKasperskyEndpoint"
# Remove the comment if you want to uninstall the Kaspersky console
# SWMB_AddOrRemoveTweak "UninstallKasperskyConsole"
# View all Kaspersky product
SWMB_AddOrRemoveTweak "ViewKasperskyProduct"
# Execute all loaded tweaks (presets)
SWMB_RunTweaks
......@@ -10,4 +10,4 @@ If (!(Test-Path -LiteralPath ".\Custom-VarOverload.psm1") -And !(Test-Path -Lite
}
# Launch SWMB
. "${Env:ProgramFiles}\SWMB\swmb.ps1" -exp UninstallKasperskyEndpoint
. "${Env:ProgramFiles}\SWMB\swmb.ps1" -exp UninstallKasperskyEndpoint ViewKasperskyProduct
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment