On 2025-03-06 09:10, Otto Moerbeek wrote:
> On Wed, Mar 05, 2025 at 06:45:13PM -0600, Tim Chase wrote:
>> However, when I dereference ufs_args.fspec it segfaults
>
> Looks like a pointer into kernel mem.

Okay, that matches my guess.

> Dereffing it will cause a segfault.

Which in turn makes sense and is the right thing to happen.

> If anything, it should probably be cleared in the kernel before
> copying out, there are also other pointers in export_args.

Looks like perhaps the clearing would end up in

sys/kern/vfs_syscalls.c:copyout_statfs()

where some other "if you're not root, you don't get to see this"
redaction is happening?

> The mount helpers do use fspec and a few fields of export_info as an
> input argument, check mount_ffs.c.

I'm insufficiently kernel-savvy to make approriate changes, but
hopefully this email-thread can get to the right people? (or maybe
that's you?)

Thanks!

-tkc





Reply via email to