This issue is now resolved.
The reason server was disconnecting is that the implementor is using port 139 which is Netbios-over-TCP. Windows client and server do not support encryption on Netbios-over-TCP. This is documented in MS-SMB2 as follows:
"
<90> Section 3.1.4.3: Windows-based clients and servers do not encrypt the message if the connection is NetBIOS over TCP
"