[284] | 1 | <?php |
---|
| 2 | /* |
---|
| 3 | * Created on 20/08/2007 Por Bruno costa |
---|
| 4 | * |
---|
[1042] | 5 | * Arquivo de configuraᅵᅵo de catᅵlogos externos |
---|
[284] | 6 | * |
---|
| 7 | */ |
---|
| 8 | |
---|
| 9 | /* |
---|
| 10 | * This file is comprised of two arrays describing the external catalogs ($external_srcs) and their attribute mappings |
---|
| 11 | * ($external_mappings). The mapping between an external catalog and his attribute mappings are made with the array indices, i. e. |
---|
| 12 | * a catalog at external_srcs with indice = 1 use the mapping with indice = 1 at external_mapping. |
---|
| 13 | * |
---|
| 14 | * external_srcs' format: |
---|
| 15 | * |
---|
| 16 | * $external_srcs = array( |
---|
| 17 | * 1 => array( |
---|
| 18 | * 'name' => 'Catalog's name', |
---|
| 19 | * 'host' => 'catalog's hostname', |
---|
| 20 | * 'dn' => 'catalog's base dn', |
---|
| 21 | * 'acc' => 'catalog's bind dn', |
---|
| 22 | * 'pw' => 'bind dn's password', |
---|
| 23 | * 'obj' => 'objectClass that will be used in searches', |
---|
| 24 | * 'branch' => strtolower('attribute used as branches in the catalog tree'), |
---|
[1042] | 25 | 'quicksearch => 'ExpressoMail's search', |
---|
| 26 | 'max_results' => 'Ldap's search limit', |
---|
[404] | 27 | * ), |
---|
[284] | 28 | * 2 => array( |
---|
| 29 | * ... |
---|
| 30 | * ), |
---|
| 31 | * ); |
---|
| 32 | * |
---|
| 33 | * external_mappings' format: |
---|
| 34 | * |
---|
| 35 | * $external_mappings = array( |
---|
| 36 | * 1 => array( |
---|
| 37 | * 'contact.id_contact' => array('dn'), |
---|
| 38 | * 'contact.photo' => array('jpegPhoto'), |
---|
| 39 | * 'contact.prefixes.prefix' => false, //used when you don't have an attribute or don't want to use one |
---|
| 40 | * ... |
---|
| 41 | * ), |
---|
| 42 | * 2 => array( |
---|
| 43 | * ... |
---|
| 44 | * ), |
---|
| 45 | * ); |
---|
| 46 | * |
---|
| 47 | */ |
---|
[1042] | 48 | |
---|
| 49 | $external_srcs = array( |
---|
| 50 | /* 1 => array( |
---|
| 51 | 'name' => 'Exchange Fazenda', |
---|
| 52 | 'host' => '10.30.2.21', |
---|
| 53 | 'dn' => 'dc=mf,dc=correio', |
---|
| 54 | 'acc' => 'cn=Carteiro,ou=Serpro,dc=mf,dc=correio', |
---|
| 55 | 'pw' => 'bfr2000s$', |
---|
| 56 | 'obj' => 'person', |
---|
| 57 | 'branch' => '', |
---|
| 58 | 'quicksearch' => true, |
---|
| 59 | 'max_results' => 50, |
---|
| 60 | |
---|
| 61 | ),*/ |
---|
| 62 | 1 => array( |
---|
| 63 | 'name' => 'Grupos Notes', |
---|
| 64 | 'host' => '10.30.2.25', |
---|
| 65 | 'dn' => 'ou=gruposNotes,dc=correiolivre,dc=serpro,dc=gov,dc=br', |
---|
| 66 | 'acc' => 'cn=admin,dc=correiolivre,dc=serpro,dc=gov,dc=br', |
---|
| 67 | 'pw' => 'correio', |
---|
| 68 | 'obj' => 'inetOrgPerson', |
---|
| 69 | 'branch' => '', |
---|
| 70 | 'quicksearch' => false, |
---|
| 71 | 'max_result' => 0, |
---|
| 72 | ) |
---|
| 73 | ); |
---|
| 74 | $external_mappings = array( |
---|
| 75 | /* 1 => array( |
---|
| 76 | 'contact.id_contact' => array('dn'), |
---|
| 77 | 'contact.photo' => array('jpegPhoto'), |
---|
| 78 | 'contact.prefixes.prefix' => false, |
---|
| 79 | 'contact.alias' => array('alias'), |
---|
| 80 | 'contact.given_names' => array('givenName'), |
---|
| 81 | 'contact.family_names' => array('sn'), |
---|
| 82 | 'contact.names_ordered' => array('cn'),//,'displayName'), |
---|
| 83 | 'contact.suffixes.suffix' => false, |
---|
| 84 | 'contact.birthdate' => false, |
---|
| 85 | 'contact.sex' => false, |
---|
| 86 | 'contact.pgp_key' => false, |
---|
| 87 | 'contact.notes' => false, |
---|
| 88 | 'contact.mail_forwarding_address' => array('mailForwardingAddress'), |
---|
| 89 | 'contact.account_type' => false, |
---|
| 90 | 'contact.account_status' => false, |
---|
| 91 | 'contact.account_visible' => false, |
---|
| 92 | 'contact.object_class' => array('objectClass'), |
---|
| 93 | 'contact.business_info.title' => array('title'), |
---|
| 94 | 'contact.business_info.department' => array('ou'), // Setor do empregado... |
---|
| 95 | 'contact.business_info.empNumber' => array('employeeNumber'), // Matricula do empregado |
---|
| 96 | 'contact.business_info.celPhone' => array('mobile'), // Celular empresarial do empregado |
---|
| 97 | 'contact.company.company_name' => array('o'), |
---|
| 98 | 'contact.company.company_notes' => array('businessCategory'), |
---|
| 99 | |
---|
| 100 | 'contact.contact_related.names_ordered' => 'contact.contact_related.typeof_relation.contact_relation_name', |
---|
| 101 | 'contact.contact_related.typeof_relation.contact_relation_name' => array( |
---|
| 102 | 'manager' => array('manager'), |
---|
| 103 | 'secretary' => array('secretary') |
---|
| 104 | ), |
---|
| 105 | |
---|
| 106 | 'contact.address.address1' => 'contact.address.typeof_address.contact_address_type_name', |
---|
| 107 | 'contact.address.typeof_address.contact_address_type_name' => array( |
---|
| 108 | 'home' => array('street', 'st', 'postalAddress', 'homePostalAddress'), |
---|
| 109 | ), |
---|
| 110 | |
---|
| 111 | 'contact.address.postal_code' => 'contact.address.typeof_address.contact_address_type_name', |
---|
| 112 | 'contact.address.typeof_address.contact_address_type_name' => array( |
---|
| 113 | 'home' => array('PostalCode'), |
---|
| 114 | ), |
---|
| 115 | |
---|
| 116 | 'contact.address.city.city_name' => 'contact.address.typeof_address.contact_address_type_name', |
---|
| 117 | 'contact.address.typeof_address.contact_address_type_name' => array( |
---|
| 118 | 'home' => array('l'), |
---|
| 119 | ), |
---|
| 120 | |
---|
| 121 | 'contact.address.city.state.state_name' => 'contact.address.typeof_address.contact_address_type_name', |
---|
| 122 | 'contact.address.typeof_address.contact_address_type_name' => array( |
---|
| 123 | 'home' => false, |
---|
| 124 | ), |
---|
| 125 | |
---|
| 126 | 'contact.address.city.country.id_country' => 'contact.address.typeof_address.contact_address_type_name', |
---|
| 127 | 'contact.address.typeof_address.contact_address_type_name' => array( |
---|
| 128 | 'home' => array('c') |
---|
| 129 | ), |
---|
| 130 | |
---|
| 131 | 'contact.connection.connection_value' => 'contact.connection.typeof_connection.contact_connection_type_name', |
---|
| 132 | 'contact.connection.typeof_connection.contact_connection_type_name' => array ( |
---|
| 133 | 'email' => array('mail'), |
---|
| 134 | 'phone' => array('telephoneNumber'), |
---|
| 135 | // 'mobile' => array('mobile'), |
---|
| 136 | 'pager' => array('pager'), |
---|
| 137 | 'fax' => array('facsimileTelephoneNumber'), |
---|
| 138 | 'telex' => array('telexNumber') |
---|
| 139 | ), |
---|
| 140 | ),*/ |
---|
| 141 | 1 => array( |
---|
| 142 | 'contact.id_contact' => array('dn'), |
---|
| 143 | 'contact.photo' => array('jpegPhoto'), |
---|
| 144 | 'contact.prefixes.prefix' => false, |
---|
| 145 | 'contact.alias' => array('alias'), |
---|
| 146 | 'contact.given_names' => array('givenName'), |
---|
| 147 | 'contact.family_names' => array('sn'), |
---|
| 148 | 'contact.names_ordered' => array('cn'),//,'displayName'), |
---|
| 149 | 'contact.suffixes.suffix' => false, |
---|
| 150 | 'contact.birthdate' => false, |
---|
| 151 | 'contact.sex' => false, |
---|
| 152 | 'contact.pgp_key' => false, |
---|
| 153 | 'contact.notes' => false, |
---|
| 154 | 'contact.mail_forwarding_address' => array('mailForwardingAddress'), |
---|
| 155 | 'contact.account_type' => false, |
---|
| 156 | 'contact.account_status' => false, |
---|
| 157 | 'contact.account_visible' => false, |
---|
| 158 | 'contact.object_class' => array('objectClass'), |
---|
| 159 | 'contact.business_info.title' => array('title'), |
---|
| 160 | 'contact.business_info.department' => array('ou'), // Setor do empregado... |
---|
| 161 | 'contact.business_info.empNumber' => array('employeeNumber'), // Matricula do empregado |
---|
| 162 | 'contact.business_info.celPhone' => array('mobile'), // Celular empresarial do empregado |
---|
| 163 | 'contact.company.company_name' => array('o'), |
---|
| 164 | 'contact.company.company_notes' => array('businessCategory'), |
---|
| 165 | |
---|
| 166 | 'contact.contact_related.names_ordered' => 'contact.contact_related.typeof_relation.contact_relation_name', |
---|
| 167 | 'contact.contact_related.typeof_relation.contact_relation_name' => array( |
---|
| 168 | 'manager' => array('manager'), |
---|
| 169 | 'secretary' => array('secretary') |
---|
| 170 | ), |
---|
| 171 | |
---|
| 172 | 'contact.address.address1' => 'contact.address.typeof_address.contact_address_type_name', |
---|
| 173 | 'contact.address.typeof_address.contact_address_type_name' => array( |
---|
| 174 | 'home' => array('street', 'st', 'postalAddress', 'homePostalAddress'), |
---|
| 175 | ), |
---|
| 176 | |
---|
| 177 | 'contact.address.postal_code' => 'contact.address.typeof_address.contact_address_type_name', |
---|
| 178 | 'contact.address.typeof_address.contact_address_type_name' => array( |
---|
| 179 | 'home' => array('PostalCode'), |
---|
| 180 | ), |
---|
| 181 | |
---|
| 182 | 'contact.address.city.city_name' => 'contact.address.typeof_address.contact_address_type_name', |
---|
| 183 | 'contact.address.typeof_address.contact_address_type_name' => array( |
---|
| 184 | 'home' => array('l'), |
---|
| 185 | ), |
---|
| 186 | |
---|
| 187 | 'contact.address.city.state.state_name' => 'contact.address.typeof_address.contact_address_type_name', |
---|
| 188 | 'contact.address.typeof_address.contact_address_type_name' => array( |
---|
| 189 | 'home' => false, |
---|
| 190 | ), |
---|
| 191 | |
---|
| 192 | 'contact.address.city.country.id_country' => 'contact.address.typeof_address.contact_address_type_name', |
---|
| 193 | 'contact.address.typeof_address.contact_address_type_name' => array( |
---|
| 194 | 'home' => array('c') |
---|
| 195 | ), |
---|
| 196 | |
---|
| 197 | 'contact.connection.connection_value' => 'contact.connection.typeof_connection.contact_connection_type_name', |
---|
| 198 | 'contact.connection.typeof_connection.contact_connection_type_name' => array ( |
---|
| 199 | 'email' => array('mail'), |
---|
| 200 | 'phone' => array('telephoneNumber'), |
---|
| 201 | // 'mobile' => array('mobile'), |
---|
| 202 | 'pager' => array('pager'), |
---|
| 203 | // 'fax' => array('facsimileTelephoneNumber'), |
---|
| 204 | 'telex' => array('telexNumber') |
---|
| 205 | ), |
---|
| 206 | |
---|
| 207 | |
---|
| 208 | ), |
---|
| 209 | ); |
---|
| 210 | |
---|
[285] | 211 | ?> |
---|