Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to detect and remove games from multiple pc

Status
Not open for further replies.

Sina

Technical User
Jan 2, 2001
309
CA
I need to connect to all pc's in my domain and remove the games (you know the managment).

Does anyone know how to connect to the pc and scan for games and if found remove them?

Keep in mind that some users have changed the game file name and even though I scan for names, I may not find the games
Thank much.

 
I'd say this is close to impossible.
Possibilities/Considerations:
1)search through all executable files for game-like attributes(certain c library calls?, graphics intensive, known names of common games(these could all be dangerous)).
2)search through the help files in any directory with an executable to find keywords(game, play(watch out, this may catch the wrong files), etc.).
3)erase the file in a way which cannot be recovered from(wipe the file instead of just unlink it).
4)search through all archive files(.zip, .tar, etc.) for backup copies of the games.
5)you'll have to have superuser access, just in case the permissions are set well.
6)physical copies(aren't most games on CD anyway)

Honestly, i'd say that it would be a much better idea to deal with the employees than it would be to try to delete the files. if someone wants to have a game on their computer, they will.
"If you think you're too small to make a difference, try spending a night in a closed tent with a mosquito."
 
ditto on dealing with the employee and not the executables. The likelyhood of eventually butchering an OS or other legitimate application is very high.


keep the rudder amid ship and beware the odd typo
 
Thanks to all of you for taking the time.

I should have been more specific.

The os is Windows NT.
All I need to do is to connect and remove the game. easy. I have that already. I simply do a dir on the directory and remove anything with (i.e sol.exe and JUST know NT games). This would work fine. However some users have renamed the file from sol.exe to something like myfile.exe. therefore I can not do a dir on the direcotry and scan for sol.exe and minesweeper. Now I Only there was a way to read the properties of files, I would search the drive for any files with size of i.e 4698k and then for those files read the file properties. On NT you can look at the properties of a file and it will tell you the original file name that can not change even if the user changed the file name. If I can read that, then I can safely remove that one file. So the problem is how to read that?
Is there a function in perl that can tell you those properties for a file you can see in NT?

Thank to all of you.
 
yeah, you can get the size of a file easily
[tt]$filesize = -s FILE;[/tt]

there's lots of different properties you can get with that format. consult perldocs for more.
however, that doesn't guarentee you'll be deleting the right files. the size of a program is random, and others may have the exact same size.
what you could do instead is have a copy of the games you want to delete, then compare the contents with the contents of the other executables, line by line(or only view the first kilobyte, or take a random sample, otherwise this could really drag), to check for matches. then make sure that the size is correct, then delete it.
"If you think you're too small to make a difference, try spending a night in a closed tent with a mosquito."
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top