Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

openssh: Keep also the LD_PRELOAD environment variable #18069

Merged
merged 1 commit into from
Oct 2, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions packages/openssh/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ TERMUX_PKG_DESCRIPTION="Secure shell for logging into a remote machine"
TERMUX_PKG_LICENSE="BSD"
TERMUX_PKG_MAINTAINER="@termux"
TERMUX_PKG_VERSION=9.4p1
TERMUX_PKG_REVISION=1
TERMUX_PKG_SRCURL=https://fastly.cdn.openbsd.org/pub/OpenBSD/OpenSSH/portable/openssh-${TERMUX_PKG_VERSION}.tar.gz
TERMUX_PKG_SHA256=3608fd9088db2163ceb3e600c85ab79d0de3d221e59192ea1923e23263866a85
TERMUX_PKG_DEPENDS="krb5, ldns, libandroid-support, libedit, openssh-sftp-server, openssl, termux-auth, zlib"
Expand Down
2 changes: 1 addition & 1 deletion packages/openssh/session.c.patch
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ diff -uNr openssh-9.3p1/session.c openssh-9.3p1.mod/session.c


+#ifdef __ANDROID__
+ char const* envs_to_keep[] = {"ASEC_MOUNTPOINT", "BOOTCLASSPATH", "DEX2OATBOOTCLASSPATH", "EXTERNAL_STORAGE", "LANG", "PATH", "PREFIX", "SYSTEMSERVERCLASSPATH", "TMPDIR"};
+ char const* envs_to_keep[] = {"ASEC_MOUNTPOINT", "BOOTCLASSPATH", "DEX2OATBOOTCLASSPATH", "EXTERNAL_STORAGE", "LANG", "PATH", "PREFIX", "SYSTEMSERVERCLASSPATH", "TMPDIR", "LD_PRELOAD"};
+ for (i = 0; i < (sizeof(envs_to_keep) / sizeof(envs_to_keep[0])); i++) {
+ char const* env_to_keep_name = envs_to_keep[i];
+ char const* env_to_keep_value = getenv(env_to_keep_name);
Expand Down