Coder Social home page Coder Social logo

Detect SMB Version about amsmb2 HOT 8 CLOSED

amosavian avatar amosavian commented on June 11, 2024
Detect SMB Version

from amsmb2.

Comments (8)

amosavian avatar amosavian commented on June 11, 2024

I don’t get the question. This library is client and supports connecting to SMB2 server and its dialects.

from amsmb2.

anonymouz4 avatar anonymouz4 commented on June 11, 2024

Whether it is a SMB2 Server or not?

For example I tried connecting to a old server (Apple TimeCapsule) and it never returned anything. So my assumption is that it only supports SMBv1

from amsmb2.

amosavian avatar amosavian commented on June 11, 2024

This library does not provide any way to detect server support. It only will return an error if server doesn’t support SMB2/3 protocol or fails to establish a connection.

You can use a SMB1 library like libdsm (or its objective-c wrappers) as fallback.

from amsmb2.

anonymouz4 avatar anonymouz4 commented on June 11, 2024

My problem is that it doesn't return an error, it only timeouts.

But I'm talking about a method to detect in general besides this library, if there is any (MacOS/Linux)

from amsmb2.

amosavian avatar amosavian commented on June 11, 2024

Probably the server doesn’t return anything.

from amsmb2.

anonymouz4 avatar anonymouz4 commented on June 11, 2024

Well it could also be a slow connection or slow dns Server that is resolving a hostname. So I don't want to wait 2 minutes to find out whether I need SMBv1 or SMBv2/3

from amsmb2.

anonymouz4 avatar anonymouz4 commented on June 11, 2024

There has to be a way
How is the MacOS Finder then doing it? It always and instantly take the best Version?

from amsmb2.

amosavian avatar amosavian commented on June 11, 2024

Of course there is. Please read this link to know how this can be done. But the underlying library (libsmb2) supports no protocol other than SMB2 protocol and its dialects and there is no intention to add SMB1/CIFS support. But you can use libdsm to add SMB1/CIFS support.

from amsmb2.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.