Solved

Autorun files on USB pen

Posted on 2004-09-16
36,352 Views
Last Modified: 2011-08-18
Hi, I need to figure out how to autorun a file on a USB flash pen drive. Just like you can do with a CD - put it in and it starts running the program - I want to do with the pen drive. I've read that they're not the same and you can't do it. but there are companies who sell the pen drives with autorun software or something, they promote it. i've searched for a long time, can't find anything. maybe i can make the program - the powerpoint file for example - self-execute somehow? any help????? thanks.
0
Question by:chuckp27
    22 Comments
     
    LVL 10

    Accepted Solution

    by:
    USB pen drives are not set up to behave like regular bootable devices, therefore this cannot be done.

    This potentially can be done with the correct device and driver combo-
    http://www.universalsmartdrive.net/upgrade/index.htm
    "Auto-run feature - Just plug the flash drive into the USB port, and instantly start a flash movie, MPEG movie, music composition demo, or business presentation."
    0
     
    LVL 20

    Assisted Solution

    by:DVation191
    RunUSB
    http://home.comcast.net/~rocus/
    or
    Pen Drive AutoRun...
    http://www.microtoolz.com/

    ...will both provide autorun functionality.
     
    natively, autorun won't work in XP. i searched endless for this solution.
    turns out, pen drives just don't tell the OS that it is newly inserted media, and therefore does not have the capicity to autorun on its own.

    I noticed on my own drive that when i had more than about 20 files and/or folders in the root, autoplay (not autorun) would not start. now that I reorganized my drive to fewer files, XP always asks me what i want to do ( I ususally just say to open the folder of course..)
    0
     

    Expert Comment

    by:ericsowa
    1) Set either of these reg key values to dword 0x00000091 (windows xp default):

    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\policies\Explorer
    "NoDriveTypeAutoRun"=dword:00000091

    HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\policies\Explorer
    "NoDriveTypeAutoRun"=dword:00000091

    Which one you use depends on if this behavior is just for your user account or for everyone on the machine.  LOGOFF/LOGON.

    2) Insert the pen drive and open it in explorer.  Create a new text file.  Rename the text file "autorun.inf".  Type or paste something that looks like this:

    [autorun]
    shellexecute="Ismellapromotion.ppt"

    Save.  Put Ismellapromotion.ppt in this folder as well (the drive root as it's sometimes called).  The next time you insert the drive powerpoint will start and open this file.

    note: The shellexecute command only works on win2000 and above. In xp, if removable drives don't see autorun.inf, then it will bring up the autoplay selection menu.  Use the subst command (old msdos, works in xp :) ) to make a folder act like a drive on your system--great way to test autorun scenarios.  Example: SUBST F: C:\TEMP, and of course SUBST /? for more details.
    0
     
    LVL 2

    Expert Comment

    by:adam1213
    If it apears as a drive (e: probably) It should be possible just put the autorun on it like you normaly would.
    When you put it in does it ever say searching for auto run, does not find one and ask you what you want to do if it does it is 100% compatible with normal autoruns like the ones you have on CDs

    If you dont know how to make an autorun either read about it under autoruns or get a program
    I have used Typhoon Software auto run  which will put the stuff in a folder then you just copy it to your usb pen.

    0
     
    LVL 2

    Expert Comment

    by:cofneverlivetotell
    http://www.experts-exchange.com/Storage/Q_20953875.html

    You cant boot from a USB pen, you can from a USB hdd though

    CHeer
    Cof
    0
     

    Expert Comment

    by:ericsowa
    boot: start OS (no contents in RAM) from floppy, cd, hard disk, usb drive, network.
    autoplay: start some program or open files when windows recognizes the presence of a device.
    0
     
    LVL 2

    Expert Comment

    by:adam1213
    cofneverlivetotell, cofneverlivetotell it was not asked if you could boot from it.

    0
     
    LVL 20

    Expert Comment

    by:DVation191
    ericsowa, i wish i had my flash drive with me right now to test that...
    but im almost positive (and googled those keys as well)...those reg keys merely enable autoplay....on all the default devices XP already autoplays.
    the problem is, XP doesn't autoplay flash drives... and good thing if you ask me! imagine the problems it could cause if you could go around to desktops plugging in your flash drive that autoplayed a virus!!

    i'd image you could have a lot of fun at best buy or circuit city if that was the case! =)
    0
     

    Expert Comment

    by:ericsowa
    Stop the presses.  I hope I haven't caused too many people to go stumbling around in the registry only to find that my suggestion doesn't work.  According to M$ ( http://msdn.microsoft.com/library/default.asp?url=/library/en-us/shellcc/platform/shell/programmersguide/shell_basics/shell_basics_extending/autorun/autoplay_works.asp )  drives that report DRIVE_REMOVABLE to the shell don't support autorun.inf.  I thought that setting the registry value of NoDriveTypeAutoRun was supposed to overcome this.  I don't have a usb flash memory drive, so I took a memory stick and setup an autorun.inf and stuck it in the card reader.  No go.  I don't really see how preventing this helps the virus problem--all one has to do is insert the device and point and click if they really wanted to infect a machine.

    My apologizes.  I assumed too much and made an ass out of me and me.
    0
     
    LVL 2

    Expert Comment

    by:adam1213
    To test if it supports autoruns
    Open notepad
    Paste:

    [autorun]
    ICON=icon.ico

    Save it as autorun.inf  save as file type: all files    and save it on the usb memory pen.

    Open paint, make a small picture, about 30x30 pixels save it on the pen as icon.ico

    Unplug the pen, wait for your computer to detect that it is gorn, put it back in.
    If there is a icon for it that looks like the picture you saved on it as icon.ico it supports autoruns.

    To make a autorun
    http://www.typhoonsoftware.com/
    download auto run
    Use it, it will work.
    0
     
    LVL 2

    Expert Comment

    by:adam1213
    Drive removable is reported so there is no autorun? It is not true I have a laptop, I can take the CD drive out easily and put my floppy disk or a battery in there. It is reported as drive removable, in safely remove hardware it is listed. It is a cd rom drive obbviously i have autoruns.
    0
     
    LVL 20

    Expert Comment

    by:DVation191
    the difference is a cd-rom and floppy drive have auto-insert notification, and therefor autorun will work. usb flash drives are not currently supported by auto insert notification which is required to autorun
    0
     
    LVL 2

    Expert Comment

    by:adam1213
    I think I deserve points.
    I suggest how to find out if it supports it and how to make one easily.
    0
     
    LVL 20

    Expert Comment

    by:DVation191
    adam1213, I do my best not to put down other experts contributions and to only help contribute to the author's question.

    That being said, your answer is incorrect. I have owned a minimum of 6 different brand usb flash drives and none of them autorun. Nor do any of my co-worker's flash drives autorun.

    Do you own a flash drive that autoruns? If  you do I'd really like to know about it because I have never seen one that does...and it's likely the author's is not either.

    You cannot make a usb flash drive autorun without a third-party utility, sometimes this is included with the flash drive itself.
    0
     
    LVL 20

    Expert Comment

    by:DVation191
    I did want to be fair, so I tried the specific program that was suggested on three different flash drives. While the icon *did* work, autorun did *not* work...on any drive.
    0
     
    LVL 2

    Expert Comment

    by:adam1213
    If you tried my way of testing the icon was included, however there was no autorun in testing
    There was an autorun but it was not in the test.

    Try copying from a CD autorun.inf and the file that it opens (if you open autorun.inf in notepad and read it will refer to a file)


    I do not have a flash drive
    0
     
    LVL 2

    Expert Comment

    by:adam1213
    http://seclists.org/lists/fulldisclosure/2004/Jun/0631.html

    FullDisclosure: USB risks - working autorun example (fwd from pen-test)

    Okay, just to put this point at ease, autorun.inf usage on USB drives is
    possible...............
    0
     
    LVL 2

    Expert Comment

    by:adam1213
    Ctrl F  >And after some search ... autorun is possible on a usb storage device... as

    >it explained just below ...


    This will take you to the correct part
    0
     
    LVL 20

    Expert Comment

    by:DVation191
    I don't know what you got from that website, but all I see there are two batch files. I re-read that artcile three times and followed all the links.

    There is not one reference that I could find that shows you how to make your usb flash drive autorun (notice how many times they merely say usb storage device, not flash drive)

    Those two batch files posted merely give some system information along with setting up a rouge account on your windows machine...can't say that seems safe to me.
    0
     
    LVL 2

    Expert Comment

    by:adam1213
    I am objecting.

    jayca's answer just says that you cant. The question is how to, not is it possable.
    0
     
    LVL 20

    Expert Comment

    by:DVation191
    Now that I re-read the question further, the author *did* say he was looking for software that enabled him to autorun his flash drive. I think some of those software packages were presented.
    0
     

    Expert Comment

    by:wbhare
    http://www.udrw.com/en/product/

    More than just a USB Flash Memory!

    The UD-RW combines the flexibility of a USB Flash Drive and the benefit of a CD-ROM in one small compact package. The UD-RW's innovative Dual Zone Technology creates two drive icons automatically, a CD-ROM Drive (Read Only Zone) and a Removable Disk Drive (Flash Drive Zone), under 'My Computer'. It allows users to protect their precious data or files in the Read Only Zone while it still gives users the ability to modify the contents in the Flash Drive Zone.
    0

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone. Privacy Policy Terms of Use

    Featured Post

    Give your grad a cloud of their own!

    With up to 8TB of storage, give your favorite graduate their own personal cloud to centralize all their photos, videos and music in one safe place. They can save, sync and share all their stuff, and automatic photo backup helps free up space on their smartphone and tablet.

    Problem description :  Some external hard disks / USB flash drives do not show actual space as mentioned in the factory settings. This is a common problem when you use an 8 GB USB drive to make it bootable to install a firmware/ driver on a serv…
    This article is an update and follow-up of my previous article:   Storage 101: common concepts in the IT enterprise storage This time, I expand on more frequently used storage concepts.
    This video teaches viewers how to encrypt an external drive that requires a password to read and edit the drive. All tasks are done in Disk Utility. Plug in the external drive you wish to encrypt: Make sure all previous data on the drive has been …
    This Micro Tutorial will teach you how to reformat your flash drive. Sometimes your flash drive may have issues carrying files so this will completely restore it to manufacturing settings. Make sure to backup all files before reformatting. This w…

    699 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    23 Experts available now in Live!

    Get 1:1 Help Now