Page MenuHomeFreeBSD

bsdinstall partedit: Avoid potential buffer overflow in newfs_command
ClosedPublic

Authored by jhb on Oct 16 2023, 10:12 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Oct 13, 4:03 PM
Unknown Object (File)
Mon, Oct 13, 9:08 AM
Unknown Object (File)
Mon, Oct 13, 9:08 AM
Unknown Object (File)
Mon, Oct 13, 9:08 AM
Unknown Object (File)
Sun, Oct 12, 8:42 PM
Unknown Object (File)
Fri, Oct 10, 2:10 PM
Unknown Object (File)
Thu, Oct 2, 12:50 PM
Unknown Object (File)
Tue, Sep 30, 7:14 AM
Subscribers

Details

Summary

Allocate the buffer holding the newfs command string dynamically
(building the string via open_memstream) rather than storing the
command into a caller-supplied buffer of unknown length.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable