public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug dynamic-link/26076] New: dlclose crashes when cleaning up an empty namespace after dlmopen failure
@ 2020-06-03 11:43 fweimer at redhat dot com
  2020-06-04 12:50 ` [Bug dynamic-link/26076] dlmopen crashes when cleaning up an empty namespace in audit mode fweimer at redhat dot com
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: fweimer at redhat dot com @ 2020-06-03 11:43 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=26076

            Bug ID: 26076
           Summary: dlclose crashes when cleaning up an empty namespace
                    after dlmopen failure
           Product: glibc
           Version: unspecified
            Status: NEW
          Severity: minor
          Priority: P2
         Component: dynamic-link
          Assignee: unassigned at sourceware dot org
          Reporter: fweimer at redhat dot com
  Target Milestone: ---
             Flags: security-

If nothing has been loaded, ns->_ns_loaded is NULL and head->l_auditing
attempts to dereference a NULL pointer:

#ifdef SHARED
  /* Auditing checkpoint: we have deleted all objects.  */
  if (__glibc_unlikely (do_audit))
    {
      struct link_map *head = ns->_ns_loaded;
      /* Do not call the functions for any auditing object.  */
      if (head->l_auditing == 0)
        {
          struct audit_ifaces *afct = GLRO(dl_audit);
          for (unsigned int cnt = 0; cnt < GLRO(dl_naudit); ++cnt)
            {
              if (afct->activity != NULL)
                {
                  struct auditstate *state = link_map_audit_state (head, cnt);
                  afct->activity (&state->cookie, LA_ACT_CONSISTENT);
                }

              afct = afct->next;
            }
        }
    }
#endif

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2020-07-07  8:12 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-03 11:43 [Bug dynamic-link/26076] New: dlclose crashes when cleaning up an empty namespace after dlmopen failure fweimer at redhat dot com
2020-06-04 12:50 ` [Bug dynamic-link/26076] dlmopen crashes when cleaning up an empty namespace in audit mode fweimer at redhat dot com
2020-06-04 12:52 ` [Bug dynamic-link/26076] dlmopen crashes after failing to load dependencies " fweimer at redhat dot com
2020-06-04 16:20 ` fweimer at redhat dot com
2020-07-07  8:12 ` fweimer at redhat dot com
2020-07-07  8:12 ` fweimer at redhat dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).