[turba] shared mysql contacts question
Derek Dresser
ddresser at rnome.com
Thu Feb 2 06:18:14 PST 2006
Hello,
I am running the current CVS versions of Horde/IMP/Turba,etc.
I recently set up a shared sql contacts list by doing the following
1. created shared_turba_objects table
2. created config sources.php entry (see below)
3. added permissions objects for turba,sources,Shared MySQL Addressbook and
assigned appropriate permissions
My intention was to set up a contacts list that is both readable and writable by
all our Horde users. After doing this, I found that users could only access
entries where the 'owner_id' field contained their username (essentially
contacts they created).
I tried the following:
1. setting the owner_id field on all entries in the shared_turba_objects to ''
2. setting the following options (even though, as I understand it, these options
are deprecated)
'public' => true,
'readonly' => false,
'browse' => true,
3. setting VERY open permissions on all the turba permissions objects
4. banging my head against the wall ;-)
None of these things allowed users to view any entries except those where the
owner_id was their username.
finally, I got this to work for everyone by commenting out the following line in
the sources.php entry
//'__owner' => 'owner_id',
Does that make any sense? I saw other people's documentation on shared SQL
address books that still contained that line. Is this going to cause me
problems? I feel like this should not be necessary, but I couldn't figure out
what I did wrong. Any ideas?
Thanks,
Derek
####### complete sources.php entry #########
$cfgSources['sharedsql'] = array(
'title' => _("Shared MySQL Addressbook"),
'type' => 'sql',
// The default connection details are pulled from the Horde-wide SQL
// connection configuration.
//
// The old example illustrates how to use an alternate database
// configuration.
//
// New Example:
'params' => array_merge($conf['sql'], array('table' =>
'shared_turba_objects')),
// Old Example:
// 'params' => array(
// 'phptype' => 'mysql',
// 'hostspec' => 'localhost',
// 'username' => 'horde',
// 'password' => '*****',
// 'database' => 'horde',
// 'table' => 'turba_objects',
// 'charset' => 'iso-8859-1'
// ),
'map' => array(
'__key' => 'object_id',
//'__owner' => 'owner_id',
'__type' => 'object_type',
'__members' => 'object_members',
'__uid' => 'object_uid',
'name' => 'object_name',
'email' => 'object_email',
'alias' => 'object_alias',
'homeAddress' => 'object_homeaddress',
'workAddress' => 'object_workaddress',
'homePhone' => 'object_homephone',
'workPhone' => 'object_workphone',
'cellPhone' => 'object_cellphone',
'fax' => 'object_fax',
'title' => 'object_title',
'company' => 'object_company',
'notes' => 'object_notes',
'pgpPublicKey' => 'object_pgppublickey',
'smimePublicKey' => 'object_smimepublickey',
'freebusyUrl' => 'object_freebusyurl'
),
'search' => array(
'name',
'email'
),
'strict' => array(
'object_id',
'owner_id',
'object_type'
),
'export' => true,
'browse' => true,
'use_shares' => true
);
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-keys
Size: 1324 bytes
Desc: PGP Public Key
Url : http://lists.horde.org/archives/turba/attachments/20060202/a48e98e1/attachment.bin
More information about the turba
mailing list