(imported topic written by SystemAdmin)
If anyone can help port this to OS X and Linux, it would be much appreciated. Also, it would be nice to be able to deliver Prey location reporting directly into a BigFix/TEM analysis, and this should be possible since it is open source.
WARNING: you may violate local laws depending on your use of the software without knowledge of the owner & user of the computer
More info here: http://preyproject.com/.
Install Prey Fixlet
Target OS:
Windows (works on Linux & Mac OS as well)
Purpose:
load a tool silently to help recover stolen laptops or WiFi capable desktops
Command Line:
prey-win-batch-install.bat
your_api_key
Relevance 1:
// Windows OS
(name of it = “Win2000” OR name of it = “WinXP” OR name of it = “WinXP-2003” OR (name of it = “WinVista” AND product type of it = nt workstation product type AND NOT x64 of it) OR (name of it = “WinVista” AND product type of it = nt workstation product type AND x64 of it) OR (name of it = “Win7” AND NOT x64 of it) OR (name of it = “Win7” AND x64 of it) OR name of it = “WinXPe”) of operating system​
Relevance 2:
// .Net 2.0 or higher
“2.0” as version <= maximum of ((following texts of firsts “v” of names of keys whose(name of it as string as lowercase contains “v”) of key “HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\NET Framework Setup\NDP” of native registry) as version)​
Relevance 3:
// Prey not already installed
not exists key “HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\CronService” whose (value “DisplayName” of it as string as lowercase contains “Cron Service for Prey” as lowercase) of native registry
Relevance 4:
Remove this relevance to install on Non-WiFi device
// WiFi on machine (prey also works with GPS, but I’m not sure how to detect the presence of GPS)
// Prey will work on a computer that does not have WiFi, but with reduced location finding ability
exists connections whose (name of it as string as lowercase contains “Wireless” as lowercase) of network
Action:
action parameter query “PreyAPI” with description “Please enter your Prey API key found here: http://panel.preyproject.com/profile”
// Download Prey
download Prey: Laptop Tracking & Data security. Find & Protect lost devices.
continue if {(size of it = 5650143 AND sha1 of it = “1fb703d3962db76a8b059529b011f3398a79f889”) of file “prey-0.5.3-win.exe” of folder “__Download”}
// Download Prey silent install Windows BAT script
download Prey: Laptop Tracking & Data security. Find & Protect lost devices.
continue if {(size of it = 2479 AND sha1 of it = “12a00bbbd5b239af185fb9f105728851590e53ee”) of file “prey-win-batch-install.bat” of folder “__Download”}
delete prey-win-batch-install.bat
delete prey-0.5.3-win.exe
copy __Download\prey-win-batch-install.bat prey-win-batch-install.bat
copy __Download\prey-0.5.3-win.exe prey-0.5.3-win.exe
delete __Download\prey-win-batch-install.bat
delete __Download\prey-0.5.3-win.exe
//Need to remove the “PAUSE” from the next to last line of prey-win-batch-install.bat​, otherwise the execution will never end.
delete __appendfile
appendfile {concatenation “%0a%0d” of lines whose (it as lowercase does not start with “PAUSE” as lowercase) of file “prey-win-batch-install.bat”}
delete prey-win-batch-install.bat
copy __appendfile prey-win-batch-install.bat
waithidden {pathname of system folder & “\cmd.exe”} /Q /C “{(pathname of client folder of current site) & “\prey-win-batch-install.bat”}” {parameter “PreyAPI” of action}
delete prey-win-batch-install.bat
delete prey-0.5.3-win.exe​
​
References:
http://support.preyproject.com/kb/installation/how-to-deploy-prey-in-batch-mode-windows​
http://support.preyproject.com/kb/modules-issues/geo-module-doesnt-work
http://www.microsoft.com/download/en/details.aspx?displaylang=en&id=2098​