Page MenuHomeFreeBSD

acl_equiv_mode_np: zero mode on just inited ACL
ClosedPublic

Authored by brooks on Jan 2 2024, 10:04 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Oct 4, 1:01 AM
Unknown Object (File)
Sun, Sep 20, 10:32 PM
Unknown Object (File)
Sat, Sep 12, 4:12 AM
Unknown Object (File)
Wed, Sep 9, 9:51 PM
Unknown Object (File)
Wed, Sep 9, 12:56 PM
Unknown Object (File)
Wed, Sep 9, 3:06 AM
Unknown Object (File)
Tue, Sep 8, 5:49 PM
Unknown Object (File)
Tue, Sep 8, 2:51 PM
Subscribers

Details

Summary

You can't return 0 and not write the mode if mode_p is non-NULL. That
violates the API contract and in common usage leaves stack trash in
*mode_p.

The acl_equiv_mode_test test passed by accident.

Sponsored by: DARPA

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 55202
Build 52091: arc lint + arc unit

Event Timeline

I bumped into this on CheriBSD were different stack layout made mode non-zero in the caller.

This revision is now accepted and ready to land.Jan 3 2024, 12:21 AM