Issues running commands in a separate shell
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 4.4k
- Forks
- 993
- Avg merge
- 9d 21h
- Merged PRs (30d)
- 1
Description
Hello,
We are writing a C# app that needs to talk to a system running Dropbear SSH running on ARM.
We cannot use the SSH.Net RunCommand() API directly because the system requires a separate shell - due to security concerns.
Attempting to use RunCommand, the call just hangs and eventually times out.
So, we are now calling CreateShellStream() and then using ReadStream() and WriteStream() to send commands via the Shell.
This seems to work somewhat ok, but we have some concerns:
(1) Performance - after calling WriteStream(), we are calling stream.Expect()
to know when the command is complete so we can look at the results
This is noticeably slower than calling the same commands manually from a PuTTY session -
is there a better way to handle this?
(2) Command Result Processing - not clear if a command succeeds or not
after we read the output stream, we have the text from stdout,
but we have to manually parse it to see if we think the command succeeded or not
is there any way to get the command result as an integer (0 meaning success)?
thanks for any suggestions -dennis
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the RunCommand(), CreateShellStream(), ReadStream(), WriteStream(), and Expect() entry points mentioned in the report. Determine whether the separate-shell workflow can expose command exit status and avoid the reported delay; the issue does not name files or tests, so the scope and completion criteria need clarification.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp
- Domain
- networking
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100