Tony Murray 36431dd296 Security fix: unauthorized access (#10091)
* Security fix: unauthorized access
Affects nginx users:
Moved php files outside of public html directory (Apache was protected by .htaccess)

Affects all users:
Some files did not check for authentication and could disclose some info.
Better checks before including files from user input

* git mv html/includes/ includes/html
git mv html/pages/ includes/html/
2019-04-11 23:26:42 -05:00

25 lines
696 B
PHP

<?php
echo '<table cellspacing="0" cellpadding="5" width="100%">';
$i = 0;
foreach (dbFetchRows('SELECT * FROM `packages` WHERE `device_id` = ? ORDER BY `name`', array($device['device_id'])) as $entry) {
echo '<tr class="list">';
echo '<td width=200><a href="'.generate_url($vars, array('name' => $entry['name'])).'">'.$entry['name'].'</a></td>';
if ($build != '') {
$dbuild = '-'.$entry['build'];
} else {
$dbuild = '';
}
echo '<td>'.$entry['version'].$dbuild.'</td>';
echo '<td>'.$entry['arch'].'</td>';
echo '<td>'.$entry['manager'].'</td>';
echo '<td>'.format_si($entry['size']).'</td>';
echo '</tr>';
$i++;
}
echo '</table>';