# small ldap schema for storing a website in ldap.
#
# This schema will be used by RoLF (Roxen LdapFS)
#
# Licensed under GPL, written by Stefan Pfetzing <dreamind@dreamind.de>

# for some more information about the needed stuff look at:
# http://www.selfhtml.org/

# Currently there is a Roxen module (not yet released) which will
# access objects stored in ldap.

attributetype ( 1.3.6.1.4.1.18172.1.3.1 NAME 'webTitle'
        DESC 'The long Title of a Website, must be unique'
        EQUALITY caseIgnoreMatch
        SUBSTR caseIgnoreSubstringsMatch
        ORDERING caseIgnoreOrderingMatch
        SYNTAX 1.3.6.1.4.1.1466.115.121.1.15 SINGLE-VALUE )

attributetype ( 1.3.6.1.4.1.18172.1.3.2 NAME 'documentBody'
        DESC 'The complete Document body, without <body>'
        SYNTAX 1.3.6.1.4.1.1466.115.121.1.5 )

attributetype ( 1.3.6.1.4.1.18172.1.3.3 NAME 'documentRefresh'
        DESC 'Refresh information for the Website'
        SYNTAX 1.3.6.1.4.1.1466.115.121.1.15 SINGLE-VALUE )

attributetype ( 1.3.6.1.4.1.18172.1.3.4 NAME 'documentExpires'
        DESC 'The time, when the document expires, in HTML stle'
        SYNTAX 1.3.6.1.4.1.1466.115.121.1.15 SINGLE-VALUE )

attributetype ( 1.3.6.1.4.1.18172.1.3.5 NAME 'documentMimeType'
        DESC 'The mime Type for the Document, needed for storing a CSS (in the body)'
        SUP webTitle )

attributetype ( 1.3.6.1.4.1.18172.1.3.6 NAME 'documentEncoding'
        DESC 'The encoding of the body, or in which it should be translated.'
        SUP webTitle )

attributetype ( 1.3.6.1.4.1.18172.1.3.7 NAME 'css'
        DESC 'The CSS of the current Website.'
        EQUALITY caseIgnoreMatch
        SUBSTR caseIgnoreSubstringsMatch
        ORDERING caseIgnoreOrderingMatch
        SYNTAX 1.3.6.1.4.1.1466.115.121.1.15 )


attributetype ( 1.3.6.1.4.1.18172.1.3.8 NAME 'url'
        DESC 'An external|internal URL'
        EQUALITY caseIgnoreMatch
        SUBSTR caseIgnoreSubstringsMatch
        ORDERING caseIgnoreOrderingMatch
        SYNTAX 1.3.6.1.4.1.1466.115.121.1.15 )

attributetype ( 1.3.6.1.4.1.18172.1.3.9 NAME 'icon'
        DESC 'The URL of tha favicon for the html header.'
        SUP url )

attributetype ( 1.3.6.1.4.1.18172.1.3.10 NAME 'headerComments'
        DESC 'Additionally header comments'
        EQUALITY caseIgnoreMatch
        SUBSTR caseIgnoreSubstringsMatch
        ORDERING caseIgnoreOrderingMatch
        SYNTAX 1.3.6.1.4.1.1466.115.121.1.15 )

attributetype ( 1.3.6.1.4.1.18172.1.3.11 NAME 'htmlDocumentType'
        DESC 'The HTML Document Type String'
        EQUALITY caseIgnoreMatch
        SUBSTR caseIgnoreSubstringsMatch
        ORDERING caseIgnoreOrderingMatch
        SYNTAX 1.3.6.1.4.1.1466.115.121.1.15 )

attributetype ( 1.3.6.1.4.1.18172.1.3.12 NAME 'templateCN'
        DESC 'The CN of the Template to be used'
        SUP cn )

attributetype ( 1.3.6.1.4.1.18172.1.3.13 NAME 'javaScript'
        DESC 'The CN or a complete path of a javascript file to be used'
        SUP cn )

# cn : will be used for the searchwords under which a website can be internally (through RXML) referenced.
# webTitle: the long (unique) title of the website.
# documentBody: the contents of <body>...</body>
# documentAuthor: the author which will be shown through <meta>
# documentLocation: the address base of the document, if given.
# documentPublisher: <meta name="generator" content=" ...... ">
# documentVersion: internal version of the document
# documentRefresh: <meta http-equiv="refresh" content=" ... "> for example "5; URL=http://www.dreamind.de/"
# documentExpires: the time the document gets expired.
# documentMimeType: for example text/html, whats also default
# documentEncoding: for example ISO-8859-15, which is also default
# css: either a link or a common name of a css (have to test that yet)
objectclass ( 1.3.6.1.4.1.18172.1.4.1 NAME 'webDocument'
        SUP 'top'
        DESC 'A Web Document stored in LDAP'
        MUST ( cn $ webTitle $ documentBody )
        MAY ( htmlDocumentType $ o $ ou $ documentAuthor $ documentLocation $ documentPublisher $
                documentVersion $ documentRefresh $ documentExpires $ documentMimeType $
                documentEncoding $ css $ icon $ headerComments $ javaScript ) )

objectclass ( 1.3.6.1.4.1.18172.1.4.2 NAME 'webLink'
        SUP 'top'
        DESC 'A Link to another Website, important for Link-Collections'
        MUST ( cn $ url $ description )
        MAY ( o $ ou $ documentAuthor $ documentPublisher $ documentVersion ) )

objectclass ( 1.3.6.1.4.1.18172.1.4.3 NAME 'webRewrite'
        SUP 'top'
        DESC 'A Rewrite object, used for Header rewrites'
        MUST ( cn $ url )
        MAY ( o $ ou $ documentAuthor $ documentPublisher $ documentVersion ) )

objectclass ( 1.3.6.1.4.1.18172.1.4.4 NAME 'webTemplate'
        SUP 'top'
        DESC 'A Web Template stored in LDAP'
        MUST ( cn $ webTitle $ documentBody )
        MAY ( htmlDocumentType $ o $ ou $ documentAuthor $ documentLocation $ documentPublisher $
                documentVersion $ documentRefresh $ documentExpires $ documentMimeType $
                documentEncoding $ css $ icon $ headerComments $ javaScript ) )

objectclass ( 1.3.6.1.4.1.18172.1.4.5 NAME 'webTemplatedDocument'
        SUP 'top'
        DESC 'A Web Document which uses a Template to generate HTML'
        MUST ( cn $ webTitle $ documentBody $ templateCN )
        MAY ( htmlDocumentType $ o $ ou $ documentAuthor $ documentLocation $ documentPublisher $
                documentVersion $ documentRefresh $ documentExpires $ documentMimeType $
                documentEncoding $ css $ icon $ headerComments $ javaScript ) )