📁
SKYSHELL MANAGER
PHP v8.0.30
Create
Create
Path:
root
/
home
/
godaofbq
/
hyperredbed.com
/
wp-includes
/
Name
Size
Perm
Actions
📁
ID3
-
0755
🗑️
🏷️
🔒
📁
IXR
-
0755
🗑️
🏷️
🔒
📁
PHPMailer
-
0755
🗑️
🏷️
🔒
📁
Requests
-
0755
🗑️
🏷️
🔒
📁
SimplePie
-
0755
🗑️
🏷️
🔒
📁
Text
-
0755
🗑️
🏷️
🔒
📁
abilities-api
-
0755
🗑️
🏷️
🔒
📁
ai-client
-
0755
🗑️
🏷️
🔒
📁
assets
-
0755
🗑️
🏷️
🔒
📁
block-bindings
-
0755
🗑️
🏷️
🔒
📁
block-patterns
-
0755
🗑️
🏷️
🔒
📁
block-supports
-
0755
🗑️
🏷️
🔒
📁
blocks
-
0755
🗑️
🏷️
🔒
📁
build
-
0755
🗑️
🏷️
🔒
📁
certificates
-
0755
🗑️
🏷️
🔒
📁
css
-
0755
🗑️
🏷️
🔒
📁
customize
-
0755
🗑️
🏷️
🔒
📁
fonts
-
0755
🗑️
🏷️
🔒
📁
html-api
-
0755
🗑️
🏷️
🔒
📁
images
-
0755
🗑️
🏷️
🔒
📁
interactivity-api
-
0755
🗑️
🏷️
🔒
📁
js
-
0755
🗑️
🏷️
🔒
📁
l10n
-
0755
🗑️
🏷️
🔒
📁
php-ai-client
-
0755
🗑️
🏷️
🔒
📁
php-compat
-
0755
🗑️
🏷️
🔒
📁
pomo
-
0755
🗑️
🏷️
🔒
📁
rest-api
-
0755
🗑️
🏷️
🔒
📁
sitemaps
-
0755
🗑️
🏷️
🔒
📁
sodium_compat
-
0755
🗑️
🏷️
🔒
📁
style-engine
-
0755
🗑️
🏷️
🔒
📁
widgets
-
0755
🗑️
🏷️
🔒
📄
abilities-api.php
23.8 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
abilities.php
7.82 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
admin-bar.php
38.39 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
ai-client.php
2.49 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
atomlib.php
11.9 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
block-bindings.php
7.35 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
block-i18n.json
0.31 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
block-template-utils.php
61.33 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
blocks.php
116.64 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
bookmark-template.php
12.47 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
bookmark.php
15.07 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
cache-compat.php
10.76 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
canonical.php
33.83 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
capabilities.php
42.61 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
category-template.php
55.65 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
category.php
12.53 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-avif-info.php
29.3 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-feed.php
0.53 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-json.php
42.65 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-phpmailer.php
0.65 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-requests.php
2.18 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-simplepie.php
0.44 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-smtp.php
0.45 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-snoopy.php
36.83 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-walker-category.php
8.28 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-walker-nav-menu.php
11.76 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-walker-page-dropdown.php
2.65 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-walker-page.php
7.43 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-admin-bar.php
17.58 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-ajax-response.php
5.14 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-block-bindings-registry.php
8.07 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-block-bindings-source.php
2.92 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-block-parser-block.php
2.5 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-block-parser-frame.php
1.95 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-block-parser.php
11.25 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-block-pattern-categories-registry.php
4.28 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-block-styles-registry.php
6.27 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-block-supports.php
6.4 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-block-type-registry.php
4.91 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-block-type.php
16.83 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-block.php
24.14 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-classic-to-block-menu-converter.php
3.93 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-comment-query.php
47.49 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-comment.php
9.15 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-customize-control.php
25.51 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-customize-manager.php
198.13 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-customize-nav-menus.php
56.61 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-customize-widgets.php
70.89 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-date-query.php
35.13 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-dependencies.php
16.69 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-dependency.php
2.59 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-duotone.php
39.95 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-embed.php
15.54 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-exception.php
0.25 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-fatal-error-handler.php
7.96 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-feed-cache-transient.php
3.23 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-http-requests-hooks.php
1.97 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-icons-registry.php
7.67 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-image-editor-gd.php
20.22 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-image-editor-imagick.php
36.11 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-image-editor.php
17.01 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-list-util.php
7.27 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-locale-switcher.php
6.62 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-locale.php
16.45 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-matchesmapregex.php
1.79 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-meta-query.php
29.79 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-metadata-lazyloader.php
6.67 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-navigation-fallback.php
8.98 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-network.php
12.01 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-plugin-dependencies.php
24.59 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-post-type.php
29.95 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-recovery-mode-cookie-service.php
6.72 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-recovery-mode-link-service.php
3.44 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-rewrite.php
62.2 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-role.php
2.46 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-session-tokens.php
7.15 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-simplepie-file.php
3.47 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-site-query.php
30.74 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-speculation-rules.php
7.38 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-styles.php
13.04 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-term-query.php
39.8 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-theme-json-resolver.php
34.86 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-theme-json-schema.php
7.19 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-url-pattern-prefixer.php
4.69 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-user-request.php
2.25 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-widget-factory.php
3.27 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class-wp-xmlrpc-server.php
209.98 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class.wp-dependencies.php
0.36 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
class.wp-styles.php
0.33 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
comment-template.php
100.79 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
compat.php
15.69 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
cron.php
43.94 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
date.php
0.39 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
default-filters.php
36.54 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
error_log
63.85 KB
0644
🗑️
🏷️
⬇️
✏️
🔒
📄
feed-atom.php
3.05 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
feed-rdf.php
2.61 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
feed-rss.php
1.16 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
filefuns.php
5.92 KB
0444
🗑️
🏷️
⬇️
✏️
🔒
📄
fonts.php
9.56 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
functions.php
283.52 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
functions.wp-styles.php
8.45 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
general-template.php
170.83 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
index.php
6.83 KB
0444
🗑️
🏷️
⬇️
✏️
🔒
📄
kses.php
81.03 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
l10n.php
69.74 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
link-template.php
156.39 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
load.php
55.15 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
locale.php
0.16 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
media-template.php
61.79 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
media.php
219.66 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
meta.php
65.17 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
ms-blogs.php
25.71 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
ms-default-constants.php
4.81 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
ms-default-filters.php
6.48 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
ms-deprecated.php
21.24 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
ms-files.php
6.83 KB
0444
🗑️
🏷️
⬇️
✏️
🔒
📄
ms-network.php
3.69 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
ms-site.php
40.75 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
nav-menu-template.php
25.38 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
nav-menu.php
43.23 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
option.php
102.62 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
panel.php
6.83 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
post-formats.php
6.9 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
post-template.php
67.01 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
post.php
289.58 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
registration-functions.php
0.2 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
revision.php
29.99 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
rewrite.php
19 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
robots-template.php
5.06 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
rss-functions.php
0.25 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
rss.php
22.66 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
shortcodes.php
23.47 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
sitemaps.php
3.16 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
spl-autoload-compat.php
0.43 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
style-engine.php
7.39 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
template-loader.php
4.17 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
test.php
6.83 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
theme-i18n.json
1.85 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
theme-previews.php
2.82 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
theme.json
8.83 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
update.php
37.38 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
vars.php
6.45 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
view-transitions.php
0.59 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
widgets.php
69.17 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
wp-db.php
0.43 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
📄
wp-load.php
6.83 KB
0755
🗑️
🏷️
⬇️
✏️
🔒
Edit: lsinitrd
#!/usr/bin/bash # # Copyright 2005-2010 Harald Hoyer <harald@redhat.com> # Copyright 2005-2010 Red Hat, Inc. All rights reserved. # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. # usage() { { echo "Usage: ${0##*/} [options] [<initramfs file> [<filename> [<filename> [...] ]]]" echo "Usage: ${0##*/} [options] -k <kernel version>" echo echo "-h, --help print a help message and exit." echo "-s, --size sort the contents of the initramfs by size." echo "-m, --mod list modules." echo "-f, --file <filename> print the contents of <filename>." echo "--unpack unpack the initramfs, instead of displaying the contents." echo " If optional filenames are given, will only unpack specified files," echo " else the whole image will be unpacked. Won't unpack anything from early cpio part." echo "--unpackearly unpack the early microcode part of the initramfs." echo " Same as --unpack, but only unpack files from early cpio part." echo "-v, --verbose unpack verbosely." echo "-k, --kver <kernel version> inspect the initramfs of <kernel version>." echo } >&2 } [[ $dracutbasedir ]] || dracutbasedir=/usr/lib/dracut sorted=0 modules=0 unset verbose declare -A filenames unset POSIXLY_CORRECT TEMP=$(getopt \ -o "vshmf:k:" \ --long kver: \ --long file: \ --long mod \ --long help \ --long size \ --long unpack \ --long unpackearly \ --long verbose \ -- "$@") # shellcheck disable=SC2181 if (($? != 0)); then usage exit 1 fi eval set -- "$TEMP" while (($# > 0)); do case $1 in -k | --kver) KERNEL_VERSION="$2" shift ;; -f | --file) filenames[${2#/}]=1 shift ;; -s | --size) sorted=1 ;; -h | --help) usage exit 0 ;; -m | --mod) modules=1 ;; -v | --verbose) verbose="--verbose" ;; --unpack) unpack=1 ;; --unpackearly) unpackearly=1 ;; --) shift break ;; *) usage exit 1 ;; esac shift done [[ $KERNEL_VERSION ]] || KERNEL_VERSION="$(uname -r)" if [[ $1 ]]; then image="$1" if ! [[ -f $image ]]; then { echo "$image does not exist" echo } >&2 usage exit 1 fi else if [[ -d /efi/Default ]] || [[ -d /boot/Default ]] || [[ -d /boot/efi/Default ]]; then MACHINE_ID="Default" elif [[ -f /etc/machine-id ]]; then read -r MACHINE_ID < /etc/machine-id else MACHINE_ID="Default" fi if [[ -d /efi/loader/entries || -L /efi/loader/entries ]] \ && [[ $MACHINE_ID ]] \ && [[ -d /efi/${MACHINE_ID} || -L /efi/${MACHINE_ID} ]]; then image="/efi/${MACHINE_ID}/${KERNEL_VERSION}/initrd" elif [[ -d /boot/loader/entries || -L /boot/loader/entries ]] \ && [[ $MACHINE_ID ]] \ && [[ -d /boot/${MACHINE_ID} || -L /boot/${MACHINE_ID} ]]; then image="/boot/${MACHINE_ID}/${KERNEL_VERSION}/initrd" elif [[ -d /boot/efi/loader/entries || -L /boot/efi/loader/entries ]] \ && [[ $MACHINE_ID ]] \ && [[ -d /boot/efi/${MACHINE_ID} || -L /boot/efi/${MACHINE_ID} ]]; then image="/boot/efi/${MACHINE_ID}/${KERNEL_VERSION}/initrd" elif [[ -f /lib/modules/${KERNEL_VERSION}/initrd ]]; then image="/lib/modules/${KERNEL_VERSION}/initrd" elif [[ -f /boot/initramfs-${KERNEL_VERSION}.img ]]; then image="/boot/initramfs-${KERNEL_VERSION}.img" elif [[ -f /usr/lib/modules/${KERNEL_VERSION}/initramfs.img ]]; then image="/usr/lib/modules/${KERNEL_VERSION}/initramfs.img" elif [[ $MACHINE_ID ]] \ && mountpoint -q /efi; then image="/efi/${MACHINE_ID}/${KERNEL_VERSION}/initrd" elif [[ $MACHINE_ID ]] \ && mountpoint -q /boot/efi; then image="/boot/efi/${MACHINE_ID}/${KERNEL_VERSION}/initrd" else image="" fi fi shift while (($# > 0)); do filenames[${1#/}]=1 shift done if ! [[ -f $image ]]; then { echo "No <initramfs file> specified and the default image '$image' cannot be accessed!" echo } >&2 usage exit 1 fi TMPDIR="$(mktemp -d -t lsinitrd.XXXXXX)" # shellcheck disable=SC2064 trap "rm -rf '$TMPDIR'" EXIT dracutlibdirs() { for d in lib64/dracut lib/dracut usr/lib64/dracut usr/lib/dracut; do echo "$d/$1" done } extract_files() { ((${#filenames[@]} == 1)) && nofileinfo=1 for f in "${!filenames[@]}"; do [[ $nofileinfo ]] || echo "initramfs:/$f" [[ $nofileinfo ]] || echo "========================================================================" $CAT "$image" 2> /dev/null | cpio --extract --verbose --quiet --to-stdout "$f" 2> /dev/null ((ret += $?)) [[ $nofileinfo ]] || echo "========================================================================" [[ $nofileinfo ]] || echo done } list_modules() { echo "dracut modules:" # shellcheck disable=SC2046 $CAT "$image" | cpio --extract --verbose --quiet --to-stdout -- \ $(dracutlibdirs modules.txt) 2> /dev/null ((ret += $?)) } list_files() { echo "========================================================================" if [ "$sorted" -eq 1 ]; then $CAT "$image" 2> /dev/null | cpio --extract --verbose --quiet --list | sort -n -k5 else $CAT "$image" 2> /dev/null | cpio --extract --verbose --quiet --list | sort -k9 fi ((ret += $?)) echo "========================================================================" } list_squash_content() { SQUASH_IMG="squash-root.img" SQUASH_TMPFILE="$TMPDIR/initrd.root.sqsh" $CAT "$image" 2> /dev/null | cpio --extract --verbose --quiet --to-stdout -- \ $SQUASH_IMG > "$SQUASH_TMPFILE" 2> /dev/null if [[ -s $SQUASH_TMPFILE ]]; then echo "Squashed content ($SQUASH_IMG):" echo "========================================================================" unsquashfs -ll "$SQUASH_TMPFILE" | tail -n +4 echo "========================================================================" fi } unpack_files() { if ((${#filenames[@]} > 0)); then for f in "${!filenames[@]}"; do $CAT "$image" 2> /dev/null | cpio -id --quiet $verbose $f ((ret += $?)) done else $CAT "$image" 2> /dev/null | cpio -id --quiet $verbose ((ret += $?)) fi } read -r -N 2 bin < "$image" if [ "$bin" = "MZ" ]; then command -v objcopy > /dev/null || { echo "Need 'objcopy' to unpack an UEFI executable." exit 1 } objcopy \ --dump-section .linux="$TMPDIR/vmlinuz" \ --dump-section .initrd="$TMPDIR/initrd.img" \ --dump-section .cmdline="$TMPDIR/cmdline.txt" \ --dump-section .osrel="$TMPDIR/osrel.txt" \ "$image" /dev/null uefi="$image" image="$TMPDIR/initrd.img" [ -f "$image" ] || exit 1 fi if ((${#filenames[@]} <= 0)) && [[ -z $unpack ]] && [[ -z $unpackearly ]]; then if [ -n "$uefi" ]; then echo -n "initrd in UEFI: $uefi: " du -h "$image" | while read -r a _ || [ -n "$a" ]; do echo "$a"; done if [ -f "$TMPDIR/osrel.txt" ]; then name=$(sed -En '/^PRETTY_NAME/ s/^\w+=["'"'"']?([^"'"'"'$]*)["'"'"']?/\1/p' "$TMPDIR/osrel.txt") id=$(sed -En '/^ID/ s/^\w+=["'"'"']?([^"'"'"'$]*)["'"'"']?/\1/p' "$TMPDIR/osrel.txt") build=$(sed -En '/^BUILD_ID/ s/^\w+=["'"'"']?([^"'"'"'$]*)["'"'"']?/\1/p' "$TMPDIR/osrel.txt") echo "OS Release: $name (${id}-${build})" fi if [ -f "$TMPDIR/vmlinuz" ]; then version=$(strings -n 20 "$TMPDIR/vmlinuz" | sed -En '/[0-9]+\.[0-9]+\.[0-9]+/ { p; q 0 }') echo "Kernel Version: $version" fi if [ -f "$TMPDIR/cmdline.txt" ]; then echo "Command line:" sed -En 's/\s+/\n/g; s/\x00/\n/; p' "$TMPDIR/cmdline.txt" fi else echo -n "Image: $image: " du -h "$image" | while read -r a _ || [ -n "$a" ]; do echo "$a"; done fi echo "========================================================================" fi read -r -N 6 bin < "$image" case $bin in $'\x71\xc7'* | 070701) CAT="cat --" is_early=$(cpio --extract --verbose --quiet --to-stdout -- 'early_cpio' < "$image" 2> /dev/null) # Debian mkinitramfs does not create the file 'early_cpio', so let's check if firmware files exist [[ "$is_early" ]] || is_early=$(cpio --list --verbose --quiet --to-stdout -- 'kernel/*/microcode/*.bin' < "$image" 2> /dev/null) if [[ "$is_early" ]]; then if [[ -n $unpack ]]; then # should use --unpackearly for early CPIO : elif [[ -n $unpackearly ]]; then unpack_files elif ((${#filenames[@]} > 0)); then extract_files else echo "Early CPIO image" list_files fi if [[ -d "$dracutbasedir/skipcpio" ]]; then SKIP="$dracutbasedir/skipcpio/skipcpio" else SKIP="$dracutbasedir/skipcpio" fi if ! [[ -x $SKIP ]]; then echo echo "'$SKIP' not found, cannot display remaining contents!" >&2 echo exit 0 fi fi ;; esac if [[ $SKIP ]]; then bin="$($SKIP "$image" | { read -r -N 6 bin && echo "$bin"; })" else read -r -N 6 bin < "$image" fi case $bin in $'\x1f\x8b'*) CAT="zcat --" ;; BZh*) CAT="bzcat --" ;; $'\x71\xc7'* | 070701) CAT="cat --" ;; $'\x02\x21'*) CAT="lz4 -d -c" ;; $'\x89'LZO$'\0'*) CAT="lzop -d -c" ;; $'\x28\xB5\x2F\xFD'*) CAT="zstd -d -c" ;; *) if echo "test" | xz | xzcat --single-stream > /dev/null 2>&1; then CAT="xzcat --single-stream --" else CAT="xzcat --" fi ;; esac skipcpio() { $SKIP "$@" | $ORIG_CAT } if [[ $SKIP ]]; then ORIG_CAT="$CAT" CAT=skipcpio fi if ((${#filenames[@]} > 1)); then TMPFILE="$TMPDIR/initrd.cpio" $CAT "$image" 2> /dev/null > "$TMPFILE" pre_decompress() { cat "$TMPFILE" } CAT=pre_decompress fi ret=0 if [[ -n $unpack ]]; then unpack_files elif ((${#filenames[@]} > 0)); then extract_files else # shellcheck disable=SC2046 version=$($CAT "$image" | cpio --extract --verbose --quiet --to-stdout -- \ $(dracutlibdirs 'dracut-*') 2> /dev/null) ((ret += $?)) echo "Version: $version" echo if [ "$modules" -eq 1 ]; then list_modules echo "========================================================================" else echo -n "Arguments: " # shellcheck disable=SC2046 $CAT "$image" | cpio --extract --verbose --quiet --to-stdout -- \ $(dracutlibdirs build-parameter.txt) 2> /dev/null echo list_modules list_files list_squash_content fi fi exit "$ret"
Save