Enable CD drive mode in USB stick firmware
Quick answer: Scroll down.
Long answer:
Is partitioning the pen drive, and then making 1 partition as read only, a solution to this? If yes, then please guide me how to do that.
There seems to be a lot of talk (and confusion) out there about having read-only partitions on usb sticks, the idea being to make it look like a CD drive to windows so the files are protected.
Multiple partitions don't work with windows.
Story goes, we could have 2 partitions on the drive with a read-only iso image in one, and a regular FAT32 partition for the other.
Works great with linux, not with windows.
You can overwrite the whole usb stick with an iso image and windows will treat it as a CD drive (even the bios can boot from it if it's an hybrid image !) but that's all. If the image is in a partition windows doesn't know what to do with it anymore. And as harrymc pointed out, windows doesn't like multiple partitions on removable drives anyway.
U3 sticks, however, do just that !
U3 sticks have special firmware to emulate a CD drive in addition to the normal usb drive, and so show up as two different drives. The CD drive is normally used to deliver proprietary content, and so not under user control. For all practical purposes the files inside it are protected (changing it requires reprogramming firmware).
Good news is, U3 sticks came out a while back and now it seems pretty much every usb stick has this functionality built-in even if not used at all by default (!) There's even an opensource tool (u3-tool) that allows to manipulate the CD image for U3 compatible devices.
The bad news: we have to mess around with the stick's firmware, most of tools are windows-only, come from china, are extremely technical if not downright obscure, and we might well blow it all up with the wrong settings. Alright, it's not going to be pretty...
Easy case: it works with u3-tool
- Your stick is in the supported devices (or you feel adventurous and just try)
- Create an iso image with your file(s) in it (genisoimage / isomaster / your favorite burning tool)
- Replace usb stick's CD image with your own using u3-tool.
General case
Following mostly comes from this great tutorial:
- Find out what chip the stick has.
ChipGenius
and Flash Drive Information Extractor
are particularly good at that. Get latest version from flashboot.ru (Yes it's in russian, did i forget to mention we'd be visiting russia along the way ? Get chrome to translate the page for you it'll be alright).
Chip is Phison
or SMI
? We're in business, others i don't know.
For example, i have a Kingston Data Traveller stick and it turns out to be Phison-based.
- Lookup device's
VID
& PID
you got in previous step in flashboot.ru's database to find out which tool you need. ChipGenius might tell you as well. Looks like it's MPAll for Phison chips (you need the right version), UFDisk Utilities for SMI etc. Download and install from flashboot.ru.
- If you end up with MPAll as well, follow the tutorial and try to get the settings right (good luck). In the F1 part you want 2 partitions: one cd-rom, and one removable disk. Set the partitions sizes, iso image etc. Flash the drive and pray.
For UFDisk Utilities, follow the tutorial in vinayak's answer.
- Your usb stick now (hopefully) comes up as a read-only CD Drive with your presentation in it, and a read-write removable drive for the user.