[linux-cifs-client] Re: [PATCH] [CIFS] Prevent OOPs when mounting with remote prefixpath

Shirish Pargaonkar shirishpargaonkar at gmail.com
Fri Feb 13 05:18:16 GMT 2009

On Tue, Feb 3, 2009 at 4:22 AM, Igor Mammedov <niallain at gmail.com> wrote:
> Managed to single out the part of  DFS root support from a big patch
> with a little modification.
> It will report error and fail to mount if perfixpath is on remote server.
> As well it will not scare people off with a error
> 'kernel BUG at fs/cifs/cifs_dfs_ref.c:274!'.
> ---------
> Fixes OOPs with message 'kernel BUG at fs/cifs/cifs_dfs_ref.c:274!'.
> Check if prefixpath in accessible while we are still in cifs_mount
> and fail with reporting a error if we can't access prefixpath
> (i.e. if prefixpath is located on another server)
> Best regards,
> -------------------------
> Igor Mammedov,
> niallain "at" gmail.com

We need to bring back NIPQUAD and NIPQUAD_FMT back in cifs_mount
instead of %pI4 i..e.
sprintf(pSesInfo->serverName, NIPQUAD_FMT,
If we sprintf hex address in serverName instead of dotted-decimal
notation, the Path parameter in Tree Connect
to IPC$ share on the server to get dfs referral fails,
\\hex_address\IPC$ is not a valid UNC path name.

I have not tried on a IPv6 setup, but I suspect the same applies to
IPv6 formatting.



More information about the linux-cifs-client mailing list