0
  "   ˆl–Ðz¾””ÔD¨ 	Å Œ¹q¦”Å£¿ƒh¹ÂÁ      0x0
  
   	ˆƒO‡ÃÂÁ Ó    	<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
 <head>
  <title>Index of /anon_sym/anon/sys/devices/virtual/tty/tty6/subsystem/tty58</title>
 </head>
 <body>
<h1>Index of /anon_sym/anon/sys/devices/virtual/tty/tty6/subsystem/tty58</h1>
  <table>
   <tr><th valign="top">&nbsp;</th><th><a href="?C=N;O=D">Name</a></th><th><a href="?C=M;O=A">Last modified</a></th><th><a href="?C=S;O=A">Size</a></th><th><a href="?C=D;O=A">Description</a></th></tr>
   <tr><th colspan="5"><hr></th></tr>
<tr><td valign="top">&nbsp;</td><td><a href="/anon_sym/anon/sys/devices/virtual/tty/tty6/subsystem/">Parent Directory</a>       </td><td>&nbsp;</td><td align="right">  - </td><td>&nbsp;</td></tr>
<tr><td valign="top">&nbsp;</td><td><a href="dev">dev</a>                    </td><td align="right">2026-10-11 20:36  </td><td align="right">4.0K</td><td>&nbsp;</td></tr>
<tr><td valign="top">&nbsp;</td><td><a href="power/">power/</a>                 </td><td align="right">2026-10-11 20:33  </td><td align="right">  - </td><td>&nbsp;</td></tr>
<tr><td valign="top">&nbsp;</td><td><a href="subsystem/">subsystem/</a>             </td><td align="right">2026-10-11 06:17  </td><td align="right">  - </td><td>&nbsp;</td></tr>
<tr><td valign="top">&nbsp;</td><td><a href="uevent">uevent</a>                 </td><td align="right">2026-10-11 20:36  </td><td align="right">4.0K</td><td>&nbsp;</td></tr>
   <tr><th colspan="5"><hr></th></tr>
</table>
</body></html>
  9   ˆl–Ãa¾”êeJq@ŠãNÜdJbÑ¿ÀƒeÑ9a–Ðz¾””ÔD¨ 	Å �ãAS�ÿÃ Ž    #!/usr/local/cpanel/3rdparty/bin/perl

#                                      Copyright 2024 WebPros International, LLC
#                                                           All rights reserved.
# copyright@cpanel.net                                         http://cpanel.net
# This code is subject to the cPanel license. Unauthorized copying is prohibited.

use strict;
use warnings;

use Cpanel::Config::Constants ();
use Cpanel::Logger            ();
use Cpanel::SafeFile          ();
use Cpanel::Themes::Utils     ();

use Whostmgr::ACLS            ();
use Whostmgr::Packages::Fetch ();
use Whostmgr::Packages::Load  ();

use Getopt::Long ();

my $logger = Cpanel::Logger->new();

$| = 1;

if ( $> != 0 ) {
    $logger->die("Sorry, only root can use this script.");
}

my ( $theme, $packages, $help, $all_packages );

Getopt::Long::GetOptions(
    'help'         => \$help,
    'theme=s'      => \$theme,
    'all-packages' => \$all_packages,
    'packages=s'   => \$packages
  )
  || do {
    usage();
    exit 1;
  };

if ($help) {
    usage();
    exit;
}

unless ( $theme && ( $all_packages || $packages ) ) {
    usage();
    exit 1;
}

my $theme_docroot = Cpanel::Themes::Utils::get_theme_root($theme);
$logger->die( "The specified theme [" . $theme . "] does not exist." ) unless -d $theme_docroot;

if ( !$ENV{'REMOTE_USER'} ) { $ENV{'REMOTE_USER'} = 'root'; }

Whostmgr::ACLS::init_acls();

my @list_pkgs = ();

my %pkgs = %{ Whostmgr::Packages::Fetch::fetch_package_list( 'want' => 'editable' ) };

my %valid_pkgs = ();

if ($all_packages) {
    @list_pkgs  = keys %pkgs;
    %valid_pkgs = map { ( $_ => $pkgs{$_} ) } @list_pkgs;
}
else {
    @list_pkgs  = split( /\s*\,\s*/, $packages );
    %valid_pkgs = map { exists( $pkgs{"$_"} ) ? ( $_ => $pkgs{$_} ) : () } @list_pkgs;
}

unless ( scalar( keys %valid_pkgs ) ) {
    $logger->die("No valid packages are specified.");
}

my %updated_pkgs = ();
my $package_dir  = Whostmgr::Packages::Load::package_dir();
foreach my $name ( keys %valid_pkgs ) {

    # Should not happen but just in case
    next unless -e $package_dir . $name;

    my $pkglock = Cpanel::SafeFile::safeopen( \*PKG, '+<', $package_dir . $name );
    if ( !$pkglock ) {
        $logger->warn("Could not edit ${package_dir}$name");
        next;
    }

    $updated_pkgs{$name} = 1;
    my %PKG_CONFIG = %{ $valid_pkgs{$name} };
    seek( PKG, 0, 0 );
    foreach my $pkgitem ( sort keys %PKG_CONFIG ) {
  