# author: dance2die
# title: Ghetto SONY Rootkit Revealer~ :)
# date: 01/08/2005 @ 20:05
# comment: LOL, this is quite funny...
function RevealSONYRootkit {
# create a file(in a current dir)
# that starts with "$sys$" which is what SONY used to hide their files.
$private:testFile = ".\`$sys`$test.txt"
trap [System.IO.FileNotFoundException] {
# well something happend so i am guessing that the a rootkit is on the machine..
Write-Host -foregroundColor "red" -backgroundcolor "white" "You might have SONY rootkit installed... I am chickening out..."
if ([System.IO.File]::Exists($private:TestFile)) remove-item $private:testFile
break
}
If (![System.IO.File]::Exists($private:testFile)) {
# i am not using [void] here since new-item will display the file created on console... to make sure that people get to see the result
new-item -type file $private:testFile
} else {
Write-Host -foregroundColor "green" -backgroundcolor "white" "Your system is clean..."
# i don't usually like to have multiple exit points in a function but wth...
return
}
if ([System.IO.File]::Exists($private:testFile)) {
Write-Host -foregroundColor "green" -backgroundcolor "white" "Your system is clean..."
} else {
Write-Host -foregroundColor "red" -backgroundcolor "white" "FATAL:You have a SONY Rootkit installed!!!`nReinstall your Windows!!!"
}
remove-item $private:testFile
}
Experimenting with a different format of blogs...