|
|
00c0d4 |
Downstream-only patch to move the recently added members (from
|
|
|
00c0d4 |
glibc-rh2047981-5.patch and glibc-rh2047981-6.patch) to the end
|
|
|
00c0d4 |
of _rtld_global_ro. This avoids changing the offset of
|
|
|
00c0d4 |
GLRO (dl_naudit).
|
|
|
00c0d4 |
|
|
|
00c0d4 |
Without this change, the audit invocation loop in the old
|
|
|
00c0d4 |
__libc_start_main function in a not-yet-updated version of libc.so.6
|
|
|
00c0d4 |
reads a non-zero garbage value for GLRO (dl_naudit), assumes that
|
|
|
00c0d4 |
auditing is active, and reads further garbage pointers, leading to
|
|
|
00c0d4 |
to a crash. Preserving the old offset of GLRO (dl_naudit) avoids
|
|
|
00c0d4 |
that. This works because RPM updates /lib64/ld-* before
|
|
|
00c0d4 |
/lib64/libc.so.6 because it sorts earlier (except on POWER9 due
|
|
|
00c0d4 |
to the glibc-hwcaps/power9 multilib).
|
|
|
00c0d4 |
|
|
|
00c0d4 |
diff --git a/sysdeps/generic/ldsodefs.h b/sysdeps/generic/ldsodefs.h
|
|
|
00c0d4 |
index 9dec9e3d3b6d6aa2..5e56550a4d556fa7 100644
|
|
|
00c0d4 |
--- a/sysdeps/generic/ldsodefs.h
|
|
|
00c0d4 |
+++ b/sysdeps/generic/ldsodefs.h
|
|
|
00c0d4 |
@@ -648,6 +648,15 @@ struct rtld_global_ro
|
|
|
00c0d4 |
void *(*_dl_open) (const char *file, int mode, const void *caller_dlopen,
|
|
|
00c0d4 |
Lmid_t nsid, int argc, char *argv[], char *env[]);
|
|
|
00c0d4 |
void (*_dl_close) (void *map);
|
|
|
00c0d4 |
+ void *(*_dl_tls_get_addr_soft) (struct link_map *);
|
|
|
00c0d4 |
+#ifdef HAVE_DL_DISCOVER_OSVERSION
|
|
|
00c0d4 |
+ int (*_dl_discover_osversion) (void);
|
|
|
00c0d4 |
+#endif
|
|
|
00c0d4 |
+
|
|
|
00c0d4 |
+ /* List of auditing interfaces. */
|
|
|
00c0d4 |
+ struct audit_ifaces *_dl_audit;
|
|
|
00c0d4 |
+ unsigned int _dl_naudit;
|
|
|
00c0d4 |
+
|
|
|
00c0d4 |
/* libdl in a secondary namespace (after dlopen) must use
|
|
|
00c0d4 |
_dl_catch_error from the main namespace, so it has to be
|
|
|
00c0d4 |
exported in some way. */
|
|
|
00c0d4 |
@@ -657,14 +666,6 @@ struct rtld_global_ro
|
|
|
00c0d4 |
/* libdl in a secondary namespace must use free from the base
|
|
|
00c0d4 |
namespace. */
|
|
|
00c0d4 |
void (*_dl_error_free) (void *);
|
|
|
00c0d4 |
- void *(*_dl_tls_get_addr_soft) (struct link_map *);
|
|
|
00c0d4 |
-#ifdef HAVE_DL_DISCOVER_OSVERSION
|
|
|
00c0d4 |
- int (*_dl_discover_osversion) (void);
|
|
|
00c0d4 |
-#endif
|
|
|
00c0d4 |
-
|
|
|
00c0d4 |
- /* List of auditing interfaces. */
|
|
|
00c0d4 |
- struct audit_ifaces *_dl_audit;
|
|
|
00c0d4 |
- unsigned int _dl_naudit;
|
|
|
00c0d4 |
};
|
|
|
00c0d4 |
# define __rtld_global_attribute__
|
|
|
00c0d4 |
# if IS_IN (rtld)
|