bugacl - Bugs: bug #59061, acl_from_mode doesn't properly...

 
 

bug #59061: acl_from_mode doesn't properly handle allocation failure

Submitter:  Tavian Barnes <tavianator>
Submitted:  Thu 03 Sep 2020 08:50:23 PM UTC
   
 
Category:  None Severity:  3 - Normal
Priority:  5 - Normal Item Group:  None
Status:  Fixed Privacy:  Public
Assigned to:  None Open/Closed:  Closed
* Mandatory Fields

Post a Comment

Add a New Comment Rich Markup
   

Discussion

Thu 03 Sep 2020 09:11:47 PM UTC, comment #2: 

Indeed, thanks for the fix.

The same bug exists in acl_copy_int, so I've fixed that at the same time.

Andreas Gruenbacher <agruen>
Group administrator
Thu 03 Sep 2020 08:58:31 PM UTC, comment #1: 

Patch attached.

(file #49740)

Tavian Barnes <tavianator>
Thu 03 Sep 2020 08:50:23 PM UTC, original submission:  

acl_from_mode() does


        acl_obj_p = __acl_init_obj(3);
        if (!acl_obj_p)
                goto fail;
        ...
fail:
        __acl_free_acl_obj(acl_obj_p);
        return NULL;


But __acl_free_acl_obj() doesn't handle NULL, resulting in a segfault.  Changing that `goto fail;` into `return NULL;` fixes the crash.

Tavian Barnes <tavianator>

 

Attached Files

(Note: upload size limit is set to 4.0MiB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

 

Dependencies

This item does not depend on any other items.

No items depend on this one.

 

Mail Notification Carbon-Copy List

Carbon-Copy List
  • -email is unavailable- added by agruen (Posted a comment)
  • -email is unavailable- added by tavianator (Submitted the item)
  •  

    Votes

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    History

    Follow 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2020-09-03 agruen StatusNone Fixed
        Open/ClosedOpen Closed
    2020-09-03 tavianator Attached File- Added 0001-acl_from_mode-Fix-segfault-on-allocation-failure.patch, #49740

    Back to the top

    Powered by Savane 3.16-8b18.
    Corresponding source code