[PATCH] smbclient fails with posix large reads
Jeremy Allison
jra at samba.org
Fri Jan 27 17:07:16 MST 2012
On Sat, Jan 28, 2012 at 08:50:12AM +1100, Andrew Bartlett wrote:
> On Fri, 2012-01-27 at 13:39 -0800, Jeremy Allison wrote:
> > On Fri, Jan 27, 2012 at 11:56:13AM +1100, Andrew Bartlett wrote:
> > > smbclient3 in master fails when we attempt to use the posix extensions
> > > to read 16MB chucks at a time. Attached is a fix, which also applies to
> > > (at least) 3.5.
> > >
> > > to reproduce:
> > >
> > > smbclient //server/tmp
> > >
> > > posix
> > > get large_file
> > >
> > > I've CC'd Alex who found the issue.
> > >
> > > The simple issue is that smb_buffer_oob fails because it is told the
> > > incorrect packet size, not taking into account that the packet may be a
> > > large read&X. There are lot of calls to smb_len() in the code - I
> > > suspect this may not be the only one wrong...
> > >
> > > Given this was for an OOB check, I wanted to run it past the list to
> > > double-check it.
> >
> > LGTM - I'm pushing it to master (and the associated test).
> >
> > I'll raise a bug to get it applied to 3.6.x also.
>
> For 3.5 the macro name changed, here is the patch.
Thanks ! Fixes uploaded to:
https://bugzilla.samba.org/show_bug.cgi?id=8727
for you to review for 3.5.next and 3.6.next.
Cheers !
Jeremy.
More information about the samba-technical
mailing list