Here is a utility for touching and lower-casing files and subdirectories, recursively.
It only works under Win9x however but hey, thats me.

Somewhat entertaining finding out how to do this under Win9x, as the source shows.

Cheers all
Attachments:
Posted on 2006-08-07 23:39:25 by davk
Why on earth are you using VXDCall instead of the Win32 functions?
Posted on 2006-08-08 05:34:14 by f0dder
Perhaps pVxDCall0 really sets the filetime of a directory?
AFAIR touching directory creating time in DOS was not a trivial task:

  • Store current system time.

  • Fake system time to the desired time.

  • Create a directory with temporary name.

  • Restore current system time.

  • Move all files and subfolders from original to the new directory.

  • Remove original directory.

  • Rename temporary directory to its original name.


Posted on 2006-08-08 13:02:51 by vit$oft

Perhaps pVxDCall0 really sets the filetime of a directory?
AFAIR touching directory creating time in DOS was not a trivial task:


This is a win32 utility, though, not a DOS utility... if the win32 functions can't set the file for directories, then ho humm.
Posted on 2006-08-08 13:05:54 by f0dder
F0dder:

Try as I might, Win98 would not let me touch directories with the published api.
As you know, this merely increases the challenge and eventually directly accessing
the underlying functions worked. I think in NT/XP you can do this via the API.
Posted on 2006-08-08 14:10:40 by davk
davk, interesting - didn't know it had a problem like that. Was it any date you couldn't set for directories?

I guess I ought to test on NT, I'm just a bit too lazy and busy I'm afraid :)
Posted on 2006-08-08 14:17:30 by f0dder
F0dder

I couldn't even get to the setting of a datetime.

All I got when using CreateFile on a directory was "Access Denied". I tried every permutation
of parameters I could think of but to no avail...

Without a directory handle then the api SetFileTime no go.

Help came via Pietrik's undocumented 95 docs and the commentary by * on his creatiion of the hps vx (a demonstrator of kernel vulnerabilities - it mirror images images when you boot on a saturday).

Posted on 2006-08-08 15:51:33 by davk
Is there a particular directory you are trying to access, or some sort of protection software installed on the system to prevent such access?
Posted on 2006-08-08 18:21:06 by SpooK
Nope, bog standard w98se, any directory and anywhere...
Posted on 2006-08-09 01:42:30 by davk