This file is indexed.

/usr/share/horde/turba/lib/Form/CreateAddressBook.php is in php-horde-turba 4.2.2-3.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
<?php
/**
 * Horde_Form for creating address books.
 *
 * See the enclosed file LICENSE for license information (ASL). If you
 * did not receive this file, see http://www.horde.org/licenses/apache.
 *
 * @package Turba
 */

/**
 * The Turba_Form_CreateAddressBook class provides the form for
 * creating an address book.
 *
 * @author  Chuck Hagenbuch <chuck@horde.org>
 * @package Turba
 */
class Turba_Form_CreateAddressBook extends Horde_Form
{
    public function __construct($vars)
    {
        parent::__construct($vars, _("Create Address Book"));

        $this->addVariable(_("Name"), 'name', 'text', true);
        $this->addVariable(_("Description"), 'description', 'longtext', false, false, null, array(4, 60));

        $this->setButtons(array(_("Create")));
    }

    /**
     * @return Horde_Share  The new share object.
     * @throws Turba_Exception
     */
    public function execute()
    {
        // Need a clean cfgSources array
        $cfgSources = Turba::availableSources();
        $driver = $GLOBALS['injector']
            ->getInstance('Turba_Factory_Driver')
            ->create($cfgSources[$GLOBALS['conf']['shares']['source']]);
        $params = array(
            'params' => array('source' => $GLOBALS['conf']['shares']['source']),
            'name' => $this->_vars->get('name'),
            'desc' => $this->_vars->get('description'),
        );
        return $driver->createShare(strval(new Horde_Support_Randomid()),
                                    $params);
    }
}