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
F154277717: D42237.id128856.diff
Mon, Apr 27, 1:38 PM
F154232486: D42237.id.diff
Mon, Apr 27, 7:32 AM
Unknown Object (File)
Wed, Apr 22, 9:25 PM
Unknown Object (File)
Tue, Apr 21, 7:32 PM
Unknown Object (File)
Mon, Apr 20, 2:27 AM
Unknown Object (File)
Wed, Apr 15, 12:06 PM
Unknown Object (File)
Tue, Apr 14, 8:46 AM
Unknown Object (File)
Mar 18 2026, 1:31 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