Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search

[REBOL] NTFS Stream Fun

From: robert::muench::robertmuench::de at: 5-Aug-2002 17:40

Hi, I don't know if someone has posted something about this already. Anyway, ever heard of NTFS streams? This is in fact a way to store multiple data-tacks in one file. And MS has a very simple usage pattern (at least that's what they sometimes get right) that even works with Rebol!! Have a look:
>> write %test.txt "This is a test." >> print read %test.txt
This is a test.
>> write %"test.txt:hidden" "This is an other test stored in a stream." >> print read %test.txt
This is a test.
>> print read %"test.txt:hidden"
This is an other test stored in a stream. Cool, eh? Have a look at the file "test.txt", you will only see the 15 bytes from the first write. The stream named "hidden" can't be detected with just normal tools. Of course this only works on NTFS filesystem drives. But I think it's a real cool thing. Imagine what you could do with this: You can add your library files into a "library" stream and have them loaded at runtime. No need to pack scripts etc. Robert