Path: utzoo!utgpu!watmath!clyde!att!osu-cis!tut.cis.ohio-state.edu!ukma!uflorida!novavax!nanook
From: nanook@novavax.UUCP (Keith Dickinson)
Newsgroups: comp.sys.ibm.pc
Subject: Re: Protecting directories from peeping eyes (how???)
Message-ID: <838@novavax.UUCP>
Date: 6 Dec 88 15:43:38 GMT
References: <46@VAX1.CC.UAKRON.EDU>
Distribution: na
Organization: Nova University, Fort Lauderdale, FL
Lines: 59

in article <46@VAX1.CC.UAKRON.EDU>, greggt@VAX1.CC.UAKRON.EDU (Gregg Thompson) says:
> 
> 
> 	I am in need of protecting directories from being read by "normal"
> means.  I need it so that ncd and other dos directory utility programs
> won't acknowledge the directory.  Or something that will password the
> directory so that nothing can get to it unless some sort of password is
> given to unprotect it.
> 	If enough responses I will sumarize to the net.
> 
> 					GRegg Thompson
> 
> -- 
> To live is to die, to die is to live forever;			GRegg Thompson
> Where will you spend eternity?			     greggt@vax1.cc.uakron.edu

Gregg,
  There is a simple way to do what you are asking. It's not passwording, but
instead makes the directory "invisible" or hidden. You will need some program
(such as norton utilities or something) that will allow you to edit the actual
directory that your sub-directory is listed in.

  When you look at an actual file entry in the dirctory, the FIRST thing that
is part of the 32 byte listing is the file name. If you count out from the
first letter of the name to the 11th byte you will be able to change the
file attributes for the directory. You _should_ see probably a 10(hex) in
the position. 10H indicates that the file is a directory. By changing the
bit-switches you can change the attributes of the file listing. Below is an
list of the bit values and what they do:

Bit	Hex	Dec	What it Does
----------------------------------------------------------------------------
0	1	1	Read only flag. 
1	2	2	Hidden File... (set this bit for invisible entries!)
2	4	4	System file (can't be moved or opened!)
3	8	8	Entry is the Volume Label!
4	10	16 	Entry is a sub directory.
5	20	32	Archive bit (flag for backup programs. no actual funct)
6	40	64	N/A (no use)
7	80	128	N/A (no use)

If you had a directory entry and the value of the byte 11 was 10H (plain entry
for a directory), you would set bit 1 (by adding 2 to it) making the entry
12H. This would make the directory entry a HIDDEN DIRECTORY. It wll NOT be
viewed by most NORMAL DOS programs, but some (most actualy) utilities that
show graphic trees tend to make the directory visible. Also a chkdsk/v will
list the directory and it's contents during the run.

If you have any more questions, please feel free to write!

Keith Dickinson
Nanook of the South
-------
_   /|  | Fidonet  : 369/2 [(305) 421-8593] Brave Mew World South
\'o.O'  | Internet : nanook@muadib.FIDONET.ORG
=(___)= | UUCP     : (novavax,hoptoad!ankh)!muadib!nanook | nanook@novavax
   U    | USNail   : 433 SE 13th CT. J-202, Deerfield Beach, Fl. 33441
  Ack!  | Disclamer: This message was created by a faulty AI program.
Don't blame me...I voted for Bill'n'Opus in '88