This file is indexed.

/usr/share/horde/sesha/migration/1_sesha_base_tables.php is in php-horde-sesha 1.0.0~beta1-11ubuntu1.

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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
<?php
/**
 * Create sesha base tables
 *
 * Copyright 2011 Horde LLC (http://www.horde.org/)
 *
 * See the enclosed file COPYING for license information (GPL). If you
 * did not receive this file, see http://www.horde.org/licenses/gpl.
 *
 * @author   
 * @category Horde
 * @license  http://www.horde.org/licenses/gpl GPL
 * @package  Sesha
 */
class SeshaBaseTables extends Horde_Db_Migration_Base
{
    /**
     * Upgrade.
     */
    public function up()
    {
        $tableList = $this->tables();

        if (!in_array('sesha_inventory', $tableList)) {
            $t = $this->createTable('sesha_inventory', array('autoincrementKey' => false));
            $t->column('stock_id', 'integer', array('null' => false));
            $t->column('stock_name', 'string', array('limit' => 255));
            $t->column('note', 'text');
            $t->primaryKey(array('stock_id'));
            $t->end();
        }

        if (!in_array('sesha_categories', $tableList)) {
            $t = $this->createTable('sesha_categories', array('autoincrementKey' => false));
            $t->column('category_id', 'integer', array('null' => false));
            $t->column('category', 'string', array('limit' => 255));
            $t->column('description', 'text');
            $t->column('priority', 'integer', array('null' => false, 'default' => 0));
            $t->primaryKey(array('category_id'));
            $t->end();
        }

        if (!in_array('sesha_properties', $tableList)) {
            $t = $this->createTable('sesha_properties', array('autoincrementKey' => false));
            $t->column('property_id', 'integer', array('null' => false));
            $t->column('property', 'string', array('limit' => 256));
            $t->column('datatype', 'string', array('limit' => 128, 'null' => false, 'default' => 0));
            $t->column('parameters', 'text');
            $t->column('unit', 'string', array('limit' => 32));
            $t->column('description', 'text');
            $t->column('priority', 'integer', array('null' => false, 'default' => 0));
            $t->primaryKey(array('property_id'));
            $t->end();
        }

        if (!in_array('sesha_relations', $tableList)) {
            $t = $this->createTable('sesha_relations', array('autoincrementKey' => false));
            $t->column('category_id', 'integer', array('null' => false));
            $t->column('property_id', 'integer', array('null' => false));
            $t->end();
        }

        if (!in_array('sesha_inventory_categories', $tableList)) {
            $t = $this->createTable('sesha_inventory_categories', array('autoincrementKey' => false));
            $t->column('stock_id', 'integer', array('null' => false));
            $t->column('category_id', 'integer', array('null' => false));
            $t->end();
        }

        if (!in_array('sesha_inventory_properties', $tableList)) {
            $t = $this->createTable('sesha_inventory_properties', array('autoincrementKey' => false));
            $t->column('attribute_id', 'integer', array('null' => false));
            $t->column('property_id', 'integer');
            $t->column('stock_id', 'integer');
            $t->column('int_datavalue', 'integer');
            $t->column('txt_datavalue', 'text');
            $t->primaryKey(array('attribute_id'));
            $t->end();
        }

    }

    public function down()
    {
        $this->dropTable('sesha_inventory');
        $this->dropTable('sesha_categories');
        $this->dropTable('sesha_properties');
        $this->dropTable('sesha_relations');
        $this->dropTable('sesha_inventory_categories');
        $this->dropTable('sesha_inventory_properties');
    }
}