Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

mount_smbfs(8): support for SMBv3.02?

363 views
Skip to first unread message

O. Hartmann

unread,
Mar 3, 2016, 4:47:46 AM3/3/16
to freebsd-current
Does FreeBSD's mount_smbfs(8) support for Microsoft's SMBv3 protocol introduced
with Windows 8 and Windows Server 2012/R2?

I tried to find informations/documentation for the kernel options
NETSMB
SMBFS
which I suspect to maintain this aspect, but I couldn't find anything regarding
NETSMB or SMBFS. The manpage for mount_smbfs(8) seems not to provide any
further informations. What does option "-n opt" of mount_smbfs(8) do? See
manpage for that sepcific command, it lacks of explanation.

I'm required to mount a SHARE provided by a Windows Server 2012 R2, which has
explicitely deisabled NetBIOS over 139/tcp (firewalled, too). I'm running
FreeBSD CURRENT, most recent. I'd like to use FreeBSD tools only - as far as
this is possible.

Now it seems that mount_smbfs(8) can not handle SMBv3 - but this is simply a
guess based upon incomplete documentation.

Can someone shed light on the maximal protocol version supported by
mount_smbfs(8)? I need to track down why I can not mount a share with 445/tcp
only. I can do so via 139/tcp NetBIOS from the very same server (windows
2012R2). Since I do not understand much about how windows negotiate the
protocol used with a client's request - if any negotiation ever takes place -
I try to find out what I did wrong with the configuration/usage of
mount_smbfs(8).

I have running a Samba 4.3 server on CURRENT on which I can set "min protocol"
and "max protocol" as I like. this server does not allow connections via
139/tcp (filtered via ipfw). When setting "min protocol = SMB2" any mount
attempt with mount_smbfs(8) fail, setting the tag to NT1 I'm able to
succesfully connect via port 445/tcp. So for that reason I suspect a problem
with the SMB version negotiated with the 2012 R2 server and the inability of
mount_smbfs(8) (or its appropriate kernel backend) to handle any protocol
version higher than NT1 (or SMB1).

Thanks in advance and kind regards,

Oliver
_______________________________________________
freebsd...@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-curre...@freebsd.org"

Edward Tomasz Napierała

unread,
Mar 8, 2016, 4:55:54 AM3/8/16
to O. Hartmann, freebsd-current
On 0303T1047, O. Hartmann wrote:
> Does FreeBSD's mount_smbfs(8) support for Microsoft's SMBv3 protocol introduced
> with Windows 8 and Windows Server 2012/R2?

No, it only supports the obsolete SMB1 (aka CIFS) protocol. Since SMB2
is a completely different protocol, supporting it properly pretty much
requires implementing it from scratch. SMB3 is one of the SMB2 revisions
and thus is backward compatible with SMB2.

O. Hartmann

unread,
Mar 8, 2016, 7:54:16 AM3/8/16
to Edward Tomasz Napiera?a, freebsd-current
On Tue, 8 Mar 2016 10:55:25 +0100
Edward Tomasz Napierała <tr...@FreeBSD.org> wrote:

> On 0303T1047, O. Hartmann wrote:
> > Does FreeBSD's mount_smbfs(8) support for Microsoft's SMBv3 protocol
> > introduced with Windows 8 and Windows Server 2012/R2?
>
> No, it only supports the obsolete SMB1 (aka CIFS) protocol. Since SMB2
> is a completely different protocol, supporting it properly pretty much
> requires implementing it from scratch. SMB3 is one of the SMB2 revisions
> and thus is backward compatible with SMB2.
>
[...]

Thank you very much for this clearification. This explains much strange
behaviour I faced.

Do you see any chance that this gets fixed in a forseable time? Linux seems to
support SMBv3 by now. Or is a support considered obsolete and handled
via /net/samba43?

For a security appliance, I try to avoid as much packages as possible, so
therefore my concerns regarding mount_smbfs.

Thanks you very much,

O. Hartmann

Miroslav Lachman

unread,
Mar 8, 2016, 8:19:47 AM3/8/16
to O. Hartmann, Edward Tomasz Napiera?a, freebsd-current
O. Hartmann wrote on 03/08/2016 13:53:
> On Tue, 8 Mar 2016 10:55:25 +0100
> Edward Tomasz Napierała <tr...@FreeBSD.org> wrote:
>
>> On 0303T1047, O. Hartmann wrote:
>>> Does FreeBSD's mount_smbfs(8) support for Microsoft's SMBv3 protocol
>>> introduced with Windows 8 and Windows Server 2012/R2?
>>
>> No, it only supports the obsolete SMB1 (aka CIFS) protocol. Since SMB2
>> is a completely different protocol, supporting it properly pretty much
>> requires implementing it from scratch. SMB3 is one of the SMB2 revisions
>> and thus is backward compatible with SMB2.
>>
> [...]
>
> Thank you very much for this clearification. This explains much strange
> behaviour I faced.
>
> Do you see any chance that this gets fixed in a forseable time? Linux seems to
> support SMBv3 by now. Or is a support considered obsolete and handled
> via /net/samba43?

I am not a FreeBSD expert but I am using mount_smbfs - with some
troubles for a long time. The code base is really old and not well
maintained. There are/were many problems with charset conversions etc.
And there is no mount_smbfs in net/sambaXY packages AFAIK (smbclient is
not an option in our environment were we need to access SMB mounted
files from 3rd party PHP web applications)

It would be really nice if somebody can bring better support for
FreeBSD's SMB/CIFS mount. Maybe through FreeBSD Foundation projects.

> For a security appliance, I try to avoid as much packages as possible, so
> therefore my concerns regarding mount_smbfs.

I can use packages but there is none with mount ability of SMB/CIFS or I
don't know about it.

Miroslav Lachman

David Chisnall

unread,
Mar 8, 2016, 9:03:24 AM3/8/16
to Miroslav Lachman, O. Hartmann, Edward Tomasz Napiera?a, freebsd-current
On 8 Mar 2016, at 13:19, Miroslav Lachman <000....@quip.cz> wrote:
>
> It would be really nice if somebody can bring better support for FreeBSD's SMB/CIFS mount. Maybe through FreeBSD Foundation projects.

Indeed. Both Solaris and OS X have SMB2 implementations. If anyone is interested in working on this, then the Apple implementation may provide some inspiration:

http://www.opensource.apple.com/source/smb/

David

Kurt Jaeger

unread,
Mar 8, 2016, 1:00:08 PM3/8/16
to freebsd-current
Hi!

> Indeed. Both Solaris and OS X have SMB2 implementations. If
> anyone is interested in working on this, then the Apple implementation
> may provide some inspiration:
>
> http://www.opensource.apple.com/source/smb/

Is there any way to download this as tgz or something ?

It looks painful to get it from that site.

--
p...@opsec.eu +49 171 3101372 4 years to go !

David Chisnall

unread,
Mar 8, 2016, 1:12:45 PM3/8/16
to Kurt Jaeger, freebsd-current
On 8 Mar 2016, at 17:59, Kurt Jaeger <li...@opsec.eu> wrote:
>
>> Indeed. Both Solaris and OS X have SMB2 implementations. If
>> anyone is interested in working on this, then the Apple implementation
>> may provide some inspiration:
>>
>> http://www.opensource.apple.com/source/smb/
>
> Is there any way to download this as tgz or something ?
>
> It looks painful to get it from that site.

Tarballs are here:

http://www.opensource.apple.com/tarballs/smb/

Latest one is here:

http://www.opensource.apple.com/tarballs/smb/smb-759.40.1.tar.gz

David

Gary Palmer

unread,
Mar 8, 2016, 1:13:12 PM3/8/16
to Kurt Jaeger, freebsd-current
On Tue, Mar 08, 2016 at 06:59:54PM +0100, Kurt Jaeger wrote:
> Hi!
>
> > Indeed. Both Solaris and OS X have SMB2 implementations. If
> > anyone is interested in working on this, then the Apple implementation
> > may provide some inspiration:
> >
> > http://www.opensource.apple.com/source/smb/
>
> Is there any way to download this as tgz or something ?
>
> It looks painful to get it from that site.

http://www.opensource.apple.com/tarballs/smb/

Note that if you poke around you'll find that the SMB code is
no longer used in the latest OSX (10.11). Not entirely sure what
it is replaced with currently

Gary
0 new messages