LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices

Reply
 
Search this Thread
Old 10-26-2009, 11:11 AM   #1
keithrennie
LQ Newbie
 
Registered: Sep 2007
Posts: 2

Rep: Reputation: 0
How to delete protected Windows executable files via Linux?


I use Ubuntu 9.04 exclusively on my own machines, but I have a couple of flash drives that got infected by some corrupt windows executable (*.exe) files, probably by somebody's trojan (they are Cruzer 4GB so came with installed fancy programs that I dont need but didnt remove and Windows keeps installing unwanted ini files and other trash every time I use them in somebody elses machine or in an internet cafe). I deleted quite a few files, but some are stubborn.
$ sudo chmod +w-X doesnt seem to work. How do I unprotect and remove them? The filesystem is vFAT.

I suspect the files were created by some kind of a trojan as my work requires my flash to be pretty promiscuous.
When I 've backed up all the good files I need, I'd be happy to reformat the flash drives as straight vanilla data storage and retrieval, provided I can still use them on a variety of machines running MS windows as well as on my Linux machines. Any guidance on reformatting?
 
Old 10-26-2009, 12:14 PM   #2
TB0ne
Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 14,769

Rep: Reputation: 2614Reputation: 2614Reputation: 2614Reputation: 2614Reputation: 2614Reputation: 2614Reputation: 2614Reputation: 2614Reputation: 2614Reputation: 2614Reputation: 2614
Quote:
Originally Posted by keithrennie View Post
I use Ubuntu 9.04 exclusively on my own machines, but I have a couple of flash drives that got infected by some corrupt windows executable (*.exe) files, probably by somebody's trojan (they are Cruzer 4GB so came with installed fancy programs that I dont need but didnt remove and Windows keeps installing unwanted ini files and other trash every time I use them in somebody elses machine or in an internet cafe). I deleted quite a few files, but some are stubborn.
$ sudo chmod +w-X doesnt seem to work. How do I unprotect and remove them? The filesystem is vFAT.
Cruzer?? Not the U3 junk, is it? Because if so, the ONLY way to get rid of it is to use the U3 uninstaller, which you have to download from their website, which is Windows only. Otherwise, NOTHING will get rid of it.

If you mean other stuff than the U3 software, you could do a "sudo chmod -R 777 *" on that device, and see what you can delete then, but that may not work either. A reformat may be the best and quickest option.

Quote:
I suspect the files were created by some kind of a trojan as my work requires my flash to be pretty promiscuous.
When I 've backed up all the good files I need, I'd be happy to reformat the flash drives as straight vanilla data storage and retrieval, provided I can still use them on a variety of machines running MS windows as well as on my Linux machines. Any guidance on reformatting?
Should be easily done. The device is probably /dev/sd* (a guess would be /dev/sdb, since your HDD is probably /dev/sda, but check first). So, unmount the stick first, but leave it plugged in. Then, run "sudo fdisk /dev/sdb" (obviously, replace the sdb with your device name). Delete the partition(s) on it, and create a new one....the fdisk help is simple to follow. After that, you can do "sudo mkfs -t vfat /dev/sdb1". That should create you a 'portable' Windows/Linux stick, ready to go.
 
Old 10-29-2009, 07:24 PM   #3
keithrennie
LQ Newbie
 
Registered: Sep 2007
Posts: 2

Original Poster
Rep: Reputation: 0
Smile

Thanks. It was U3 junk. I backed up and reformatted, and used the partition editor (gparted) instead of the command line. It seems to work pretty well.
 
  


Reply

Tags
executable, remove, windows


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
can i delete windows files from linux in ntfs partition sting1220 Linux - Newbie 1 12-23-2007 12:08 AM
Copying Protected Files from Windows XP Salty9 Linux - Security 4 06-05-2007 05:52 PM
Can I delete Windows made files on Linux? Janistego427 Linux - Newbie 9 05-21-2006 11:44 PM
Cannot Delete files on Linux file share drive with Windows tendonut Linux - Networking 4 01-23-2006 11:43 AM
executable files in linux and windows... GEJOE DANIEL Programming 7 01-12-2006 01:59 PM


All times are GMT -5. The time now is 03:30 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration