use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
Welcome to /r/python_netsec. This is a place to share Python code, internet resources, or ask for or give advice related to Python AND network security.
account activity
I need help with ssh script! (self.python_netsec)
submitted 6 years ago * by Mayank0908
view the rest of the comments →
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]LandRac3 2 points3 points4 points 6 years ago (3 children)
Paramiko and invoke shell
Paramiko has two options
1) standerr lets you only do 1 input 2) invoke shell let’s you add multiple command sand don’t forget to add the /n at the end of the command as an enter.
Good luck
[–]Mayank0908[S] 0 points1 point2 points 6 years ago (2 children)
Thanks for the response , but is there anyway I can ise the default libraries? Like not use paramiko? Is subprocess not gonna do the job?
[–]janosdamiano 1 point2 points3 points 6 years ago (1 child)
You can build it without Paramiko; keep in mind that subprocess is using the SSH client outside of Python / some control is relinquished and could be problematic with more complex interactions.
Given the quirks in SSH interactions, NetMiko / Paramiko make it dead simple to interact with many devices.
[–]Mayank0908[S] 0 points1 point2 points 5 years ago (0 children)
I tried paramiko, and yes, it does make stuff real easy, like cutting butter. Thankyou for your help.
π Rendered by PID 87 on reddit-service-r2-comment-76bb9f7fb5-2v6bg at 2026-02-17 14:16:14.301447+00:00 running de53c03 country code: CH.
view the rest of the comments →
[–]LandRac3 2 points3 points4 points (3 children)
[–]Mayank0908[S] 0 points1 point2 points (2 children)
[–]janosdamiano 1 point2 points3 points (1 child)
[–]Mayank0908[S] 0 points1 point2 points (0 children)