Attention: All pages of this wiki depend on the pages that come before it, in order as they are listed on the Main Page. Please check for Dependencies.
Please also look at What You Need to Know Before Using This Wiki

/etc/davical/cal.computerisms.com-conf.php

From COCNM
Jump to navigation Jump to search
<?php
   $c->sysabbr    = 'ComputerismsCalendar';
   $c->admin_email= 'bob.miller@computerisms.com';

   $c->pg_connect[] = 'dbname=davical port=5432 user=davical_dba';
   $c->authenticate_hook['call'] = 'LDAP_check';
   $c->authenticate_hook['config'] = array(
       'host'            => 'ldap://localhost',
       'bindDN'          => 'authenticator@COMPUTERISMS.COM',
       'passDN'          => 'ThisDevilIkn0w',
       'baseDNUsers'     => 'cn=users,DC=computerisms,DC=com',
       'protocolVersion' => 3,
       'optReferrels'    => 0,
       'filterUsers'     => '(&(objectclass=person)(objectclass=user)(!(objectClass=computer))(!(userAccountControl:1.2.840.113556.1.4.803:=2)))',
       'mapping_field'   => array("username"    => "sAMAccountName",
                            "modified"          => "whenChanged" ,
                            "fullname"          => "displayName" ,
                            "email"             => "userPrincipalName",
                            "locale"            => "en_CA",
                            "date_format_type"  => "I",
                        ),
        'baseDNGroups'  => 'cn=users,DC=computerisms,DC=com',
        'filterGroups'  => 'objectClass=group',
        'group_mapping_field'   => array('username'     => 'cn',
                                         'modified'     => 'whenChanged',
                                         'fullname'     => 'cn',
                                         'members'      => 'member',
                                        ),
        'scope'         => 'subtree',
   );
   include_once('drivers_ldap.php');
   function local_index_not_logged_in() {
        ?>
        <form action="/" method="post">
        <table>
                <tr>
                        <th class="prompt">User Name:</th>
                        <td class="entry"><input class="text" type="text" name="username" size="12" /></td>
                </tr>
                <tr>
                        <th class="prompt">Password:</th>
                        <td class="entry">
                                <input class="password" type="password" name="password" size="12" />
                                <label>forget me not: <input class="checkbox" type="checkbox" name="remember" value="1" /></label>
                        </td>
                </tr>
                <tr>
                        <th class="prompt"> </th>
                        <td class="entry">
                                <input type="submit" value="GO!"
                                title="Enter your username and password then click here to log in." name="submit" class="submit" />
                        </td>
                </tr>
        </table>
        </form>
        <?php
   }