This file is indexed.

/usr/share/gosa/plugins/admin/systems/services/dhcp/class_dhcpNewSectionDialog.inc is in gosa-plugin-dhcp 2.7.4+reloaded2-13+deb9u1.

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
<?php

class dhcpNewSectionDialog extends plugin
{
    /* attribute list for save action */
    var $ignore_account     = TRUE;
    var $attributes         = array();
    var $objectclasses      = array("whatever");

    /* Mapping array */
    var $types= array();
    var $classtype= "";
    var $sectionMap= array(  "dhcpService" => array("dhcpSharedNetwork", "dhcpSubnet", "dhcpGroup", "dhcpHost", "dhcpClass", "dhcpTSigKey", "dhcpDnsZone"),
            "dhcpClass" => array("dhcpSubClass"),
            "dhcpSubClass" => array(),
            "dhcpHost" => array(),
            "dhcpGroup" => array("dhcpHost"),
            "dhcpPool" => array(),
            "dhcpSubnet" => array("dhcpPool", "dhcpGroup", "dhcpHost", "dhcpClass", "dhcpTSigKey", "dhcpDnsZone"),
            "dhcpSharedNetwork" => array("dhcpSubnet", "dhcpPool", "dhcpTsigKey", "dhcpDnsZone"),
            "dhcpTSigKey"=> array(),
            "dhcpDnsZone" => array());



    function __construct($type)
    {
        $this->initTime = microtime(TRUE);
        stats::log('plugin', $class = get_class($this), $category = array($this->acl_category),  $action = 'open',
                $amount = 1, $duration = (microtime(TRUE) - $this->initTime));

        $this->types= array(  "dhcpService" => _("Global options"),
                "dhcpClass" => _("Class"),
                "dhcpSubClass" => _("Subclass"),
                "dhcpHost" => _("Host"),
                "dhcpGroup" => _("Group"),
                "dhcpPool" => _("Pool"),
                "dhcpSubnet" => _("Subnet"),
                "dhcpSharedNetwork" => _("Shared network"),
                "dhcpTSigKey" => _("DNS update key"),
                "dhcpDnsZone" => _("DNS update zone") );

        $this->classtype= $type;
    }

    function execute()
    {
        plugin::execute();

        /* Fill templating stuff */
        $smarty = get_smarty();
        $display= "";

        $sections= $this->sectionMap[$this->classtype];
        $t_sections= array();
        foreach ($sections as $section){
            $t_sections[$section]= $this->types[$section]; 
        }
        asort($t_sections);
        $ui = get_userinfo();
        $smarty->assign("sections", set_post($t_sections));
        $display.= $smarty->fetch(get_template_path('dhcpNewSection.tpl', TRUE, dirname(__FILE__)));
        return($display);
    }

    /* Get posts and set class name 
     */ 
    function save_object()
    {
    }

    /* Check given class name */
    function check()
    {
        /* Call common method to give check the hook */
        $message= "";

        return ($message);
    }


    /* Return the class name */
    function save()
    {
    }

}

// vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler:
?>