TechSpot

Connecting direct to USB thumb drive in windows XP

By hana_jung
May 27, 2005
Topic Status:
Not open for further replies.
  1. Hi,

    Out team have written file by VC++ to read/write data to the USB thumb drive device. It's ok while connecting device to PC when logon PC by administator.

    the problem is, windows xp doesn't know device (error msg is USB NOT FOUND) when logon by user.

    does anyone know how to get around this? we're create a handle using createfile () and DeviceIoControl () API windows function to FindDevice,GetData and Writting to device.

    any help is appreciated

    thanks
  2. RealBlackStuff

    RealBlackStuff Newcomer, in training Posts: 8,165

    I assume that the USB drivers need to be (re-)installed under that User-logon.
    Are that user's Explorer-rights limited, in that (s)he can only see certain drives?
    Or has no access to VC++?
    Perhaps compile the routine and make an .exe, then the user should have access.
  3. hana_jung

    hana_jung Newcomer, in training Topic Starter

    Sorry, may be my question is not clear.
    My application on Flash drive (burn on RomArea in Flash drive) can run correctly with admin user of WinXP.
    but if i logon WinXP with limited user, it 's have some problem...!!!
    My application use CreateFile() function and DeviceIOControl() function...
    I think, may be window's privilege...

    How to solve this problem ?
    I try to use impersonate() , but i'm confuse..

    please kindly help

    thanks
  4. RealBlackStuff

    RealBlackStuff Newcomer, in training Posts: 8,165

    I don't know VC++.
    Why don't you just COPY data to and from that USB key?
    Writing a program for doing that sounds like a waste of time to me.

    If you are writing to the ROM, you need permission to access certain hardware.
    If you extend that permission to the limited user, it should work. Perhaps make him a Power-User?
  5. hana_jung

    hana_jung Newcomer, in training Topic Starter

    Actually, we have project to modify flashdrive h/w by adding FingerPrint Scan on it. And we create and burn program to read FingerPrint data from flashdrive.

    Example: at the first time you must register to use our flashdrive by scan your finger via our flashdrive that when you connect it to PC, program register will run automatically, you must scan in 3 times to confirm (like confirm password) and next time when you need to use this flashdrive, you connect our flashdrive to PCand you must scan your finger before use it.

    Ooh!!! I'm very thanks for you help

    :slurp: :) :slurp: :)
  6. jobeard

    jobeard TS Ambassador Posts: 13,369   +302

    mount permissison issue

    When a system has both Admin & Limited rights users, only the Admin has the rights to mount removablev media. I have XP/SP2 and just moved to the LUA concept (least-rights user access). The Admin-id is used to configure/install/mount/maintain software, while the Limited rights user is used for all else. This creates an enviroment that IF there is a virus penetration, it will be under the Limited-user-rights and thus will not be able to modify critical system files or configuration.

    I just got a USB Thumbdrive too. Here's how I used it;

    Logon as the admin user, insert the TD and access it using
    My Computer, OPEN device.

    Use Start menu to Switch User and login as the Limited-rights user.
    The Thumbdrive will be accessable.

    perform whatever task(s) necessary

    Close the access to the thumb drive

    Switch users back to the Admin-ID
    close the Thumbdrive and disconnect.

    This is procedural and some may find it a pain, but there's no substitued for security. Before you ask 'can i script this so as to avoid the triple switch-user?' ... the answer is NO! If you could, then security would be bogus and non-existant.

    Jeff
Topic Status:
Not open for further replies.


Add New Comment

TechSpot Members
Login or sign up for free,
it takes about 30 seconds.
You may also...


Get complete access to the TechSpot community. Join thousands of technology enthusiasts that contribute and share knowledge in our forum. Get a private inbox, upload your own photo gallery and more.