Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stop command needs more user feedback when incorrectly used #97

Open
jeffmcjunkin opened this issue Sep 11, 2019 · 1 comment · May be fixed by #140
Open

Stop command needs more user feedback when incorrectly used #97

jeffmcjunkin opened this issue Sep 11, 2019 · 1 comment · May be fixed by #140
Assignees
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@jeffmcjunkin
Copy link

Issue Template

Context

Please provide any relevant information about your setup. This is important in case the issue is not reproducible except for under certain conditions.

jeff@blue:~/dev/SILENTTRINITY$ git branch
* master
jeff@blue:~/dev/SILENTTRINITY$ git rev-parse HEAD
c3b397d85dbb471c4f202151d30100e4222215eb
  • SILENTTRINITY Version: Latest master branch
  • OS running the Client: Ubuntu 18.04 x64
  • Python Version Running the Client: Python 3.7.4+
  • OS running the TeamServer: Ubuntu 18.04 x64 (same system as client)
  • Python version running the Teamserver: Python 3.7.4 (same system as client)

Expected Behavior

The stop command from within the listeners context should stop the listener.

Current Behavior

Currently I wasn't able to stop a listener other than restarting teamserver.py

Failure Information

[1] ST ≫ listeners                                                                                                                                                                                                 
[1] ST (listeners) ≫ use http                                                                                                                                                                                      
[1] ST (listeners)(http) ≫ set Port 8000                                                                                                                                                                           
[1] ST (listeners)(http) ≫ list                                                                                                                                                                                    
[1] ST (listeners)(http) ≫ start                                                                                                                                                                                   
[1] ST (listeners)(http) ≫ list                                                                                                                                                                                    
┌Running────────────────────────────┐
│ Name │ URL                        │
├──────┼────────────────────────────┤
│ http │ http://10.153.143.148:8000 │
└──────┴────────────────────────────┘
[1] ST (listeners)(http) ≫ stop                                                                                                                                                                                    
[1] ST (listeners)(http) ≫ list                                                                                                                                                                                    
┌Running────────────────────────────┐
│ Name │ URL                        │
├──────┼────────────────────────────┤
│ http │ http://10.153.143.148:8000 │
└──────┴────────────────────────────┘
[1] ST (listeners)(http) ≫  

A separate terminal window shows python3 is still listening:

jeff@blue:~/dev/SILENTTRINITY$ lsof -ni | grep :8000
python3 12973 jeff   23u  IPv4 131287      0t0  TCP 10.153.143.148:8000 (LISTEN)

Steps to Reproduce

Start to finish is shown under Failure Information

Failure Logs

I can provide more information if needed, but I think the above is enough to replicate this from scratch.

@jeffmcjunkin
Copy link
Author

Derp! I needed more judicious use of -h:

[1] ST (listeners)(http) ≫ list                                                                                                                                                                                    
┌Running───────────────────────────┐
│ Name │ URL                       │
├──────┼───────────────────────────┤
│ http │ http://192.168.252.1:8000 │
└──────┴───────────────────────────┘
[1] ST (listeners)(http) ≫ stop                                                                                                                                                                                    
[1] ST (listeners)(http) ≫ stop http                                                                                                                                                                               
[1] ST (listeners)(http) ≫ list   

Maybe an incomplete command like stop by itself should give an error or show the usage, instead?

@byt3bl33d3r byt3bl33d3r added enhancement New feature or request good first issue Good for newcomers labels Jan 27, 2020
@byt3bl33d3r byt3bl33d3r changed the title [BUG] http listener doesn't stop listening Stop command needs more user feedback when incorrectly used Jan 27, 2020
glides added a commit to glides/SILENTTRINITY that referenced this issue Jan 30, 2020
Display a message when the user fails to use a command properly.
@glides glides linked a pull request Jan 30, 2020 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants