This file is indexed.

/usr/share/icingaweb2/modules/monitoring/application/views/scripts/list/hosts.phtml is in icingaweb2-module-monitoring 2.1.0-1ubuntu1.

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
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
<?php
use Icinga\Module\Monitoring\Object\Host;

if (! $this->compact): ?>
<div class="controls">
    <?= $this->tabs ?>
    <div class="grid">
        <?= $this->render('list/components/hostssummary.phtml') ?>
        <?= $this->render('list/components/selectioninfo.phtml') ?>
    </div>
    <div class="grid">
        <?= $this->sortBox ?>
        <?= $this->limiter ?>
        <?= $this->paginator ?>
    </div>
    <?= $this->filterEditor ?>
</div>
<?php endif ?>
<div class="content">
<?php if (! $hosts->hasResult()): ?>
    <p><?= $this->translate('No hosts found matching the filter.') ?></p>
    </div>
<?php return; endif ?>
    <table data-base-target="_next"
           class="table-row-selectable state-table multiselect"
           data-icinga-multiselect-url="<?= $this->href('monitoring/hosts/show') ?>"
           data-icinga-multiselect-controllers="<?= $this->href("monitoring/hosts") ?>"
           data-icinga-multiselect-data="host">
    <tbody>
    <?php foreach($hosts->peekAhead($this->compact) as $host):
        $hostStateName = Host::getStateText($host->host_state);
        $hostLink = $this->href('monitoring/host/show', array('host' => $host->host_name)); ?>
        <tr>
            <td class="state-col state-<?= $hostStateName ?><?= $host->host_handled ? ' handled' : '' ?>">
                <div class="state-label"><?= Host::getStateText($host->host_state, true) ?></div>
                <?php if ((int) $host->host_state !== 99): ?>
                    <div class="state-meta">
                        <?= $this->timeSince($host->host_last_state_change, $this->compact) ?>
                    <?php if ((int) $host->host_state > 0 && (int) $host->host_state_type === 0): ?>
                        <div><?= $this->translate('Soft', 'Soft state') ?> <?= $host->host_attempt ?></div>
                    <?php endif ?>
                    </div>
                <?php endif ?>
            </td>
            <td>
                <div class="state-header">
                    <?= $this->iconImage()->host($host) ?>
                    <?= $this->qlink(
                        $host->host_display_name,
                        $hostLink,
                        null,
                        array(
                            'title' => sprintf(
                                $this->translate('Show detailed information for host %s'),
                                $host->host_display_name
                            ),
                            'class' => 'rowaction'
                        )
                    ) ?>
                <?php if (isset($summary[$host->host_name])): ?>
                    <span class="host-services-incidents"> &#40;<?= $this->qlink(
                          sprintf(
                              $this->translatePlural(
                                  '%u unhandled service', '%u unhandled services', $summary[$host->host_name]
                              ),
                              $summary[$host->host_name]
                          ),
                          'monitoring/list/services',
                          array(
                              'host'               => $host->host_name,
                              'service_problem'    => 1,
                              'service_handled'    => 0
                          ),
                          array(
                              'title' => sprintf(
                                  $this->translatePlural(
                                      'List %s unhandled service problem on host %s',
                                      'List %s unhandled service problems on host %s',
                                      $summary[$host->host_name]
                                  ),
                                  $summary[$host->host_name],
                                  $host->host_name
                              )
                          )
                    ) ?>&#41;</span>
                <?php endif ?>
                    <span class="state-icons"><?= implode(' ', $this->hostFlags($host)) ?></span>
                </div>
                <p class="overview-plugin-output">
                    <?= $this->pluginOutput($this->ellipsis($host->host_output, 10000), true) ?>
                </p>
            </td>
        <?php foreach($this->addColumns as $col): ?>
            <td><?= $this->escape($host->$col) ?></td>
        <?php endforeach ?>
        </tr>
    <?php endforeach ?>
    </tbody>
    </table>
<?php if ($hosts->hasMore()): ?>
    <div class="text-right">
        <?= $this->qlink(
            $this->translate('Show More'),
            $this->url()->without(array('view', 'limit')),
            null,
            array(
                'data-base-target'  => '_next',
                'class'             => 'action-link'
            )
        ) ?>
    </div>
<?php endif ?>
</div>