Giter VIP home page Giter VIP logo

renci.sshnet's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

renci.sshnet's Issues

Namespaces missing in compiled DLL

Hello zeevl,

There are namespaces within Renci.SshNet that are unavailable in the compiled DLL.
Channels
NetConf
Sftp.Requests
Sftp.Responses

I have downloaded the source files from your repo and tried compiling it myself to no avail.

These Classes simply don't expose themselves through the Object Browser nor through any 'Using' statements.

I am hoping to reach out to you to work on a solution.

Thanks,

Tony

NetConfClient SendReceiveRpc with AutomaticMessageIdHandling can cause NullReferenceException

Renci.SshNet/Netconf/NetConfSession.cs -> _messageId is undefined when calling SendReceiveRpc.

The following code:

            var netConfClient = new NetConfClient("hostname.here", 830, "usernamehere", "passwordhere");
            
            netConfClient.Connect();

            if (netConfClient.IsConnected)
            {
                XmlDocument rpc = new XmlDocument();
                rpc.LoadXml("<rpc><get-interface-information></get-interface-information></rpc>");

                var rpcResponse = netConfClient.SendReceiveRpc(rpc);

                Console.Write(rpcResponse.OuterXml);
            }

This causes the following issue:

Unhandled exception. System.NullReferenceException: Object reference not set to an instance of an object.
   at Renci.SshNet.NetConf.NetConfSession.SendReceiveRpc(XmlDocument rpc, Boolean automaticMessageIdHandling)
   at Renci.SshNet.NetConfClient.SendReceiveRpc(XmlDocument rpc)

Currently using

AutomaticMessageIdHandling = false

to bypass this issue.

Proposed fix is init'ing the _messageId in the constructor.

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.