C# Library for SSH and Telnet [closed] - c#

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 8 years ago.
Improve this question
I'm looking for a C# library that provides access to both SSH and Telnet under the same interface. What would be a good choice?

I recommend Granados for SSH stack. It has been used in many products.
I recommend this code project page for telnet stack.
You can also download Poderosa terminal emulator. It's using Granados as the SSH stack and it has its own implementation of telnet stack.
Poderosa is very pluggable. It provides a good abstraction layer on the network stacks. If you don't have time to write your own unified interface, you should really check out their work. It provides access to both SSH and Telnet under the same interface like what you want. Unfortunately, it's written by Japanese engineers. All the inline comments are written in Japanese. It may take you some time to understand the codes.
You may also like to check out the terminal emulation library as well. Since you are going to process the data returning from the remote terminals, most terminals return escape character sequence for device control commands, font color/style or cursor movement commands.
You may not notice that even in a simple command "ls -al", the returned content may also involve some escape character sequences. Those escape sequences are to make the directory name and file name shown in different colors.
Again, for terminal emulation, the best C# library I can find is Poderosa. If you don't have to use C# library, PuTTY has the best terminal emulation support. It can recognize almost all escape character sequences I have seen so far.
Although I highly recommend you to look at Poderosa and Granados, please be aware that these projects seem to be no longer active. Well.. even so, it's still the best I have seen.

Making the SSH work with C# is indeed very tricky and most of the implementations are either buggy or too slow. When we were making SmarTTY, we struggled with SharpSSH and SSH.Net a lot, and then finally decided to make our own C# wrapper around libssh2.
Although SmarTTY is not open-source, if you want to use its SSH library in your project, feel free to drop me an email. If there's a great demand for a library like that, we might release it as a separate product.

This link might help you C# Telnet Library
Minimalistic Telnet
telnetcsharp.codeplex.com
xpresslearn
thoughtproject.com
dotnettelnet

I couldn't find anything that provides identical (or even similar APIs) for both telnet and ssh, sharpSSH is a little library that nicely abstracts SSH.

Related

How to access individual characters or pixels with C in Linux [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 4 months ago.
Improve this question
Im trying to have something similar to Console.CursorTop and left where i can set the cursor to a specific character. As far as i know i need something called a „Handle“. I found something like this for windows and i know kinda what it is. I need something similar for linux or even cross platform.
I tried finding something in the olcConsoleGameEngine but the codebase was to advanced for me
For controlling and drawing on the terminal, use curses, specifically ncurses. If you use the wide version, <ncursesw.h>, you can use wide characters, including basically all Unicode characters. This is portable across operating systems.
(For most terminals, ncurses will use ANSI escape codes, so you could use the escape codes directly, as mentioned by kotatsuyaki in a comment to the question. However, curses libraries also allows better/nonblocking keyboard control, and makes the overall program portable across operating systems, so using curses is usually the better solution.)
For accessing individual pixels, use SDL (for games-like stuff), or Gtk or Qt toolkits (for application-like stuff). These, too, are all portable across operating systems.
In addition to the library itself, you will need also bindings to C# or Python or whatever language you choose to use (unless you use the native language to the library: C for curses/ncurses, SDL, and Gtk, and C++ for Qt).
In Linux, use your package manager to install the required (development!) packages. You will not need to download anything off any web sites.
You can find tutorials for all of these all over the web. Don't be afraid to look at old tutorials for curses stuff: that interface has stayed stable for decades now.
All terminals in Linux do support UTF-8 (because the kernel itself supports UTF-8 for terminal devices), so you can use all Unicode characters (that are included in the fonts used in those terminal devices). If there is an ornery user who uses a non-UTF-8 locale by default, they may not see all Unicode characters unless they run your program with a LANG=C.UTF-8 LC_ALL=C.UTF-8 prefix (choosing the default locale with UTF-8), but that's their choice.

NoSQL FREE alternative (alternative to ravendb) for C# development [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 9 years ago.
Improve this question
I discovered raven-db and I liked it but then I saw the license... GPL or Pay
So I'm looking for good free for closed-source C# development raven-db alternative.
Seems like MongoDB and Berkley are GPL too.
And it's much better for me to find an embedded solution.
If I understand you correctly, then you can safely use MongoDB with it's double core/driver license model.
And one more thing, AFAIK unless your code released to a "world" you can do whatever you want.
Like RavenDB and MongoDB, CouchDB is a document store noSQL database with REST Api (so you can used with any language).
But CouchDB is under Apache 2.0 that can be used on commercial/closed project
https://github.com/mcintyre321/PieDb is a very basic MIT-licenced embedded document db wot I wrote
It
writes objects to app_data using json.net serialized documents
uses Lucene.Net.Linq to provide basic IQueryable support
optimistic concurrency
requires no configuration
It would be nice to get some other developers behind it, as it's only had about a weekend of work on it, but it works for simple cases as a RavenDb replacement.
iBoxDB.net is a lightweight embeddable nosql database with transaction support.
it can embed in net application, windows phone, mono application, unity3d, node.js
Being GPL doesn't mean you can't use it in a closed source project, unless you plan on modifying the source.
EDIT: To be clearer - the key thing here is the distribution of any changes. You can use GPL software and do whatever you like to it in-house, but you cannot distribute binaries of these changes without also making the source available (unless you have reached an agreement with the copyright holder).
I don't know anything about raven-db, but I imagine it boils down to one of the following scenarios:
Your application interfaces directly with the source. If your application cannot build without the GPL project, then either your application must be licensed under the GPL, or you need permission from the copyright holder. LGPL is different, but you stated GPL in your question.
Your application can build without the GPL software, but needs it to run. This would be like me building an application on top of MySQL, and instructing customers to configure a MySQL instance themselves.

Develop a basic DNS server (in C#) [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 9 years ago.
Improve this question
I am developing a very basic DNS server for my own purpose. The way I understand it, the DNS server receives UDP packets containing the requested domain name and returns the corresponding IP under some kind of standard form.
There is a standard library for reading/writing UDP packets from/to binary format. But where can I find a C# library for serialising/deserialising DNS requests/responses?
The open source ARSoft.Tools.Net library contains a DNS Server component (see documentation).
You could use this library directly, or just use the source as a starting point for building your own DNS request serializer.
As far as I can tell, I couldn't find a library for C# which handles DNS packet serialization/deserialization, which means it's likely you'll have to roll your own.
Edit: I came across this network packet sniffer project on Code Project which might have what you need. Claims to be able to to parse TCP/UDP/DNS
I did find this very helpful site for TCP/IP which has a pretty comprehensive set of pages describing DNS packet types including the general message format.
There might be some additional help from this previous SO question though.
If you look at wikipedia you find a list over all RFC's for the dns protocol, i find rfc's to be the best way to implement a network protocol!
now the dns protocol has rather many rfc's so i dont know if this is the best way to read up on the protocol but you get all the information you need atleast.
http://en.wikipedia.org/wiki/Domain_Name_System#Internet_standards

Is there any console "graphics" library for .Net? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 9 years ago.
Improve this question
My basic goal here is writing a .NET remake of Kingdom of Kroz. For those not familiar with the game:
http://www.indiefaqs.com/index.php/Kingdom_of_Kroz
http://www.youtube.com/watch?v=cHwlNAFXpIw
Originally it was supposed to be a quick distraction project to give me a break from all the generic enterprise WCF/WF/LINQ2SQL/etc work projects occupying most of my time lately. While the result of my effort is playable, it looks like absolute arse (even for a console-based game) because of the way I'm redrawing everything in each frame.
I'm aware of some alternate approaches but in the brief tests I've done they still don't offer significant performance or aesthetic benefits. I don't want to resort to a library which 'emulates' a console if I can help it. I'd prefer to work with the proper Win32 console API under the hood, but not to work with it directly if I can help it. Keeping in mind that it's a distinctly niche use case, what would be the 'generally' accepted best approach for this? Are there any particularly optimal console 'drawing' techniques one should be aware of? I don't mind swimming in a sea of PInvoke and marshalling as long as it still ends up with a fast, responsive and efficient console UI.
You could try Curses-Sharp http://sourceforge.net/projects/curses-sharp/ or libtcod https://github.com/chamons/libtcod-net
curses-sharp is a "A full featured, object-oriented, multi-platform C# wrapper for the curses terminal control library. "
and libtcod is "...a free, fast, portable and uncomplicated API for roguelike developpers providing an advanced true color console, input, and lots of other utilities frequently used in roguelikes."
http://msdn.microsoft.com/en-us/library/ms682073(v=VS.85).aspx
Some/many of these functions you might need to use P/Invoke for, but they should do what you need. You can write at arbitrary locations in the buffer and get key-based, non-buffered input. Usually you start with GetStdHandle() to get handles to the console input and output "streams" and then you call one of the appropriate functions from the above list to do something, like WriteConsoleOutputCharacter(), or PeekConsoleInput().
I once wrote a library to create an in-process windowing system using the Windows console and plain Win32 on C. Fun project, but I don't know where it is now.
Consider checking out the pdcurses or ncurses library. I am using it in Visual C++ and while you are specifying C#, it may be of use to you. It is made for console gaming and I am using it in several projects. It will eliminate the need to utilize a callback refreshing the screen as you will be able to move the character (represented as an ASCII character) without refreshing the screen.

Connect to Exchange - Getting Started Tutorial? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 9 years ago.
Improve this question
I need to connect to an Exchange-Server and to read some values, that a third party application stores there (BlackBerry Enterprise Server).
In my understanding I need to use CDO with C++ (C# doesn't seem to work this well in this regard). Is that right? I tried searching a little, but there seems to be lot of different approaches with a lot of different APIs and the whole topic confuses me a little.
Can anyone point me to some resources or tell me where to start?
Thanks!
You have a few options based on the version of Exchange you are using.
If you are running Exchange 2007
Exchange Web Services - Language agnostic approach to communicating with Exchange and the primary method moving forward. Googling EWS will return lots of good hits with tutorials and information in addition to the numerous books.
An example from Microsoft
If you are running Exchange 2003 or earlier
WebDAV is a simple way to access Exchange as Marc recommend. There are lots of good tutorials on the web for it as well. It is also language agnostic like EWS.
Dan's WebDAV 101 Blog - a blog I've used in the past for WebDAV & EWS info.
Any version of Exchange
If C++ is an option, there's also MAPI. If you're not familiar with MAPI programming, it's going to be a little bit of a learning curve, but you can do just about anything to a mailbox and it's contents. MAPI isn't supported in C#.
It's been at least three years since I worked on this problem, but it seemed to me like the best solution was C# with WebDAV. Rather than try to explain code I don't really remember, here's a link to a tutorial I wrote at the time. Definitely check out the links at the end, I remember they were very helpful in understanding how the technology worked.
Thanks for the answers guys!
However I ended up downloading a little tool called MFCMapi from codeplex and using the provided source code as a guide on how to do things.

Categories