[Osiris-devel]updated specs

Brian Wotring brian at shmoo.com
Tue Mar 20 00:15:42 EST 2001


>> The one thing left out of this style is the concept of not scanning
>> vs. not entering a directory.
>
> i'm not sure i understand that, sorry.

Consider everything to be a file ( which it is  ).  You can specify to 
ignore the file that is the directory as well as to not enter it.  I made 
this clear by suggesting the "noenter" directive to not enter a directory 
and the "ignore" directive to not scan something -which includes the files 
that are directories.

So, the issue now is how to distinguish the difference between the two.  If 
you put file("local") inside an exclude block, does it ignore the directory 
and the file or just not enter the directory but scan the file "local"?

A quick solution would be to have blocks for <Include>, <Exclude>, and 
<NoEnter>.  The <NoEnter> block being just for directories.

> <Directory />
>   Options blah blah
>   Order Include,Exclude
>   <Include>
>     file
>     file
>     <Except>
>       file
>       file
>     </Except>
>   </Include>
> </Directory>

I think this is more confusing, sorry.

Maybe having quantifiers in "Options" and "Order" is confusing.  They 
should be in one or the other, not both.  We could can the ScanAll and 
ScanOnly options and only use the "Order" statement to specify what the 
scan covers.  For example, here is a recursive scan that excludes 
everything by default:

<Directory />
    Options recursive
    Order include,exclude        # this means everything is excluded except 
what's specified.

    <Include>                    # scan only perl scripts and files owned 
by bob.
        suffix("pl")
        user("bob")
    </Include>

    # but any of bob's core files and/or files with the specific header are 
excluded.

    <Exclude>
        file("core")
        header(0xcafe)
    </Exclude>

</Directory>

Here is a recursive scan that includes everything by default:

<Directory />
    Options recursive
    Order exclude,include        # this means everything is included except 
what's specified.

    <Exclude>                    # do not scan perl scripts and files owned 
by bob.
        suffix("pl")
        user("bob")
    </Exclude>

    # but any of bob's core files and/or files with the specific header are 
still included.

    <Include>
        file("core")
        header(0xcafe)
    </Include>

</Directory>


Thoughts, questions, comments?

--
  Brian Wotring  ( brian at shmoo.com )
  PGP KeyID: 0x9674763D





More information about the osiris-devel mailing list