/proc/$$/exec with termux-exec #27078
Replies: 3 comments 1 reply
-
|
Hi, please show the source code of your Termux fork.
|
Beta Was this translation helpful? Give feedback.
-
That only applies to google play version of termux, not fdroid/github supplied by us. Busybox in playstore could be patched to use TERMUX_EXEC__PROC_SELF_EXE. It depends on which repo you are using to build packages. It might not be best to use this repo to build packages for linker, as all patches may not have been ported yet for linker. As Robert said, this is more relevant to be reported in other org. |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.



Uh oh!
There was an error while loading. Please reload this page.
-
Hi, I built the busybox package for my termux fork but when I asked it to create applets using "busybox --install -s", all the symlinks it created pointed to linker64 but when I did the same in the termux app(both the version from the play store and the one on github) the symlinks points correctly to busybox.
Termux uses linker64 to bypass Android 10's restrictions on executing code so /proc/self/exec will point to linker64 and not whatever command is actually running so Termux uses TERMUX_EXEC__PROC_SELF_EXE to tell packages what command is actually running.
But somehow calling "file /proc/self/exe" or "file /proc/$$/exe" inside the termux app currently displays the correct command and not linker64.
Something is intercepting reads of /proc/$$/exe and rewritting its content as it still in reality points to linker64 which can be verified by using "toybox file /proc/$$/exe" which says linker64.
Toybox is part of Android so whatever intercepts termux commands doesn't apply to it.
My question is what does this interception?
termux-exec?
I couldn't find any info on this in the termux docs and I've been trying to figure this out for a couple of days now.
Isn't TERMUX_EXEC__PROC_SELF_EXE now useless if /proc/self/exe now works correctly again?
Beta Was this translation helpful? Give feedback.
All reactions