Skip to content

Commit

Permalink
Update boot-comp.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
natsumerinchan authored Nov 5, 2023
1 parent ca6c923 commit b494300
Showing 1 changed file with 7 additions and 8 deletions.
15 changes: 7 additions & 8 deletions src/gearlock/gearboot/boot-comp.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,12 @@
# Note: You don't need to manually deal with this file, GearLock will take care of it.

regist_libhoudini() {
nsenter --mount=/proc/1/ns/mnt "mount -t binfmt_misc binfmt_misc /proc/sys/fs/binfmt_misc"
nsenter --mount=/proc/1/ns/mnt mount -t binfmt_misc binfmt_misc /proc/sys/fs/binfmt_misc

nsenter --mount=/proc/1/ns/mnt "echo ':arm_exe:M::\\\\x7f\\\\x45\\\\x4c\\\\x46\\\\x01\\\\x01\\\\x01\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x02\\\\x00\\\\x28::/system/bin/houdini:P' > /proc/sys/fs/binfmt_misc/register"
nsenter --mount=/proc/1/ns/mnt "echo ':arm_dyn:M::\\\\x7f\\\\x45\\\\x4c\\\\x46\\\\x01\\\\x01\\\\x01\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x03\\\\x00\\\\x28::/system/bin/houdini:P' >> /proc/sys/fs/binfmt_misc/register"
nsenter --mount=/proc/1/ns/mnt "echo ':arm64_exe:M::\\\\x7f\\\\x45\\\\x4c\\\\x46\\\\x02\\\\x01\\\\x01\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x02\\\\x00\\\\xb7::/system/bin/houdini64:P' >> /proc/sys/fs/binfmt_misc/register"
nsenter --mount=/proc/1/ns/mnt "echo ':arm64_dyn:M::\\\\x7f\\\\x45\\\\x4c\\\\x46\\\\x02\\\\x01\\\\x01\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x03\\\\x00\\\\xb7::/system/bin/houdini64:P' >> /proc/sys/fs/binfmt_misc/register"
echo "Done."
nsenter --mount=/proc/1/ns/mnt echo ':arm_exe:M::\\\\x7f\\\\x45\\\\x4c\\\\x46\\\\x01\\\\x01\\\\x01\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x02\\\\x00\\\\x28::/system/bin/houdini:P' > /proc/sys/fs/binfmt_misc/register
nsenter --mount=/proc/1/ns/mnt echo ':arm_dyn:M::\\\\x7f\\\\x45\\\\x4c\\\\x46\\\\x01\\\\x01\\\\x01\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x03\\\\x00\\\\x28::/system/bin/houdini:P' >> /proc/sys/fs/binfmt_misc/register
nsenter --mount=/proc/1/ns/mnt echo ':arm64_exe:M::\\\\x7f\\\\x45\\\\x4c\\\\x46\\\\x02\\\\x01\\\\x01\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x02\\\\x00\\\\xb7::/system/bin/houdini64:P' >> /proc/sys/fs/binfmt_misc/register
nsenter --mount=/proc/1/ns/mnt echo ':arm64_dyn:M::\\\\x7f\\\\x45\\\\x4c\\\\x46\\\\x02\\\\x01\\\\x01\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x00\\\\x03\\\\x00\\\\xb7::/system/bin/houdini64:P' >> /proc/sys/fs/binfmt_misc/register
}

regist_libhoudini 2>&1 | tee -a /data/adb/libhoudini/libhoudini.log
echo "Hello World!" >> /data/adb/libhoudini/libhoudini.log
regist_libhoudini 2>&1 | tee -a /data/adb/libhoudini/libhoudini.log

0 comments on commit b494300

Please sign in to comment.