commit-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[SCM] Hurd branch, master, updated. v0.9.git20210404-18-gd9f93a3


From: Samuel Thibault
Subject: [SCM] Hurd branch, master, updated. v0.9.git20210404-18-gd9f93a3
Date: Mon, 24 May 2021 11:55:40 -0400 (EDT)

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Hurd".

The branch, master has been updated
       via  d9f93a335f230fe018747c075734646db70bdb7a (commit)
      from  4c6ad5705584f9d76a67b0688ba66aef2eca66dc (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit d9f93a335f230fe018747c075734646db70bdb7a
Author: Sergey Bugaev <bugaevc@gmail.com>
Date:   Mon May 24 18:43:40 2021 +0300

    procfs: Fix use-after-free
    
    Fix several issues with reference counting in
    rootdir_make_translated_node ():
    
    * Grab an additional reference while still holding the lock.
    
    * Give the node an additional reference for being pointed to
      by the ops.
    
    * Reference the existing node if we find it on the second try,
      not only if we find it on the first try.
    
    * Dereference, not just clean, the created node if it turns out
      to be unneeded.
    
    Fixes a crash with the following backtrace:
    
     #2  0x010855c8 in __assert_fail_backtrace (
         assertion=0x1051148 "! (r.hard == 1 && r.weak == 0) || !\"refcount 
detected use-after-free!\"",
         file=0x1050cec "../../libshouldbeinlibc/refcount.h", line=170, 
function=0x1051220 <__PRETTY_FUNCTION__.3> "refcounts_ref")
         at ../../libshouldbeinlibc/assert-backtrace.c:64
     #3  0x01050358 in refcounts_ref (result=0x0, ref=0x15009a0) at 
../../libshouldbeinlibc/refcount.h:170
     #4  netfs_nref (np=0x15008f0) at ../../libnetfs/nref.c:26
     #5  0x0804c9f4 in rootdir_make_translated_node (dir_hook=0x10001990, 
entry_hook=0x8055180 <__compound_literal.8>)
         at ../../procfs/rootdir.c:674
     #6  0x0804ace3 in procfs_dir_lookup (hook=0x10001c10, name=0x2857efc 
"mounts", np=0x2855d68) at ../../procfs/procfs_dir.c:88
     #7  0x0804a410 in procfs_lookup (np=0x10001c40, name=0x2857efc "mounts", 
npp=0x2855d68) at ../../procfs/procfs.c:185
     #8  0x0804cae5 in dircat_lookup (hook=0x10001d50, name=0x2857efc "mounts", 
np=0x2855d68) at ../../procfs/dircat.c:76
     #9  0x0804a410 in procfs_lookup (np=0x10001d80, name=0x2857efc "mounts", 
npp=0x2855d68) at ../../procfs/procfs.c:185
     #10 0x0804a96f in netfs_attempt_lookup (user=0x1401c60, dir=0x10001d80, 
name=0x2857efc "mounts", np=0x2855d68)
         at ../../procfs/netfs.c:212
     #11 0x0103fd5b in netfs_S_dir_lookup (dircred=<optimized out>, 
filename=<optimized out>, flags=<optimized out>,
         mode=<optimized out>, do_retry=<optimized out>, retry_name=<optimized 
out>, retry_port=<optimized out>,
         retry_port_type=<optimized out>) at ../../libnetfs/dir-lookup.c:175
    Message-Id: <20210524154340.264885-2-bugaevc@gmail.com>

-----------------------------------------------------------------------

Summary of changes:
 procfs/rootdir.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)


hooks/post-receive
-- 
Hurd



reply via email to

[Prev in Thread] Current Thread [Next in Thread]