mirror of
https://github.com/torrentpier/torrentpier
synced 2025-08-20 13:24:01 -07:00
Add referrer "origin" policy to repository links (#1357)
This commit is contained in:
parent
be08d2bba9
commit
827ce7998d
2 changed files with 5 additions and 5 deletions
|
@ -53,8 +53,8 @@ if (!is_file($file_path)) {
|
||||||
$file_contents = file_get_contents($file_path);
|
$file_contents = file_get_contents($file_path);
|
||||||
|
|
||||||
if ($bb_cfg['flist_max_files']) {
|
if ($bb_cfg['flist_max_files']) {
|
||||||
$filetree_pos = !empty($row['info_hash_v2']) ? strpos($file_contents, '9:file tree') : false;
|
$filetree_pos = $meta_v2 ? strpos($file_contents, '9:file tree') : false;
|
||||||
$files_pos = !empty($row['info_hash']) ? strpos($file_contents, '5:files', $filetree_pos) : false;
|
$files_pos = $meta_v1 ? strpos($file_contents, '5:files', $filetree_pos) : false;
|
||||||
|
|
||||||
if ($filetree_pos) {
|
if ($filetree_pos) {
|
||||||
$file_count = substr_count($file_contents, '6:length', $filetree_pos, ($files_pos ? ($files_pos - $filetree_pos) : null));
|
$file_count = substr_count($file_contents, '6:length', $filetree_pos, ($files_pos ? ($files_pos - $filetree_pos) : null));
|
||||||
|
@ -201,14 +201,14 @@ sup {
|
||||||
<sup>?
|
<sup>?
|
||||||
<span class="tooltiptext">
|
<span class="tooltiptext">
|
||||||
BitTorrent Merkle Root is a hash of a file embedded in torrents with BitTorrent v2 support, tracker users can extract, calculate them, and download deduplicated torrents using desktop tools such as
|
BitTorrent Merkle Root is a hash of a file embedded in torrents with BitTorrent v2 support, tracker users can extract, calculate them, and download deduplicated torrents using desktop tools such as
|
||||||
<a href="https://github.com/kovalensky/tmrr" target="_blank">Torrent Merkle Root Reader.</a>
|
<a href="https://github.com/kovalensky/tmrr" target="_blank" referrerpolicy="origin">Torrent Merkle Root Reader.</a>
|
||||||
</span>
|
</span>
|
||||||
</sup>
|
</sup>
|
||||||
</th>
|
</th>
|
||||||
</tr>
|
</tr>
|
||||||
{$allFiles}
|
{$allFiles}
|
||||||
</table>
|
</table>
|
||||||
<p style = "color: gray; font-family: Calibri Light">Generated by <a href = "https://github.com/torrentpier/torrentpier" target="_blank" title = "Bull-powered BitTorrent tracker engine">TorrentPier</a></p>
|
<p style = "color: gray; font-family: Calibri Light">Generated by <a href = "https://github.com/torrentpier/torrentpier" target="_blank" referrerpolicy="origin" title = "Bull-powered BitTorrent tracker engine">TorrentPier</a></p>
|
||||||
</center>
|
</center>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|
|
@ -16,7 +16,7 @@ global $bb_cfg, $userdata, $template, $DBS, $lang;
|
||||||
if (!empty($template)) {
|
if (!empty($template)) {
|
||||||
$template->assign_vars([
|
$template->assign_vars([
|
||||||
'SIMPLE_FOOTER' => !empty($gen_simple_header),
|
'SIMPLE_FOOTER' => !empty($gen_simple_header),
|
||||||
'POWERED' => 'Fueled by <a target="_blank" href="https://github.com/torrentpier/torrentpier">TorrentPier</a> © 2005-' . date('Y'),
|
'POWERED' => 'Fueled by <a target="_blank" referrerpolicy="origin" href="https://github.com/torrentpier/torrentpier">TorrentPier</a> © 2005-' . date('Y'),
|
||||||
'SHOW_ADMIN_LINK' => (IS_ADMIN && !defined('IN_ADMIN')),
|
'SHOW_ADMIN_LINK' => (IS_ADMIN && !defined('IN_ADMIN')),
|
||||||
'ADMIN_LINK_HREF' => 'admin/index.php',
|
'ADMIN_LINK_HREF' => 'admin/index.php',
|
||||||
]);
|
]);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue