You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[](https://pypi.org/project/Flask-Shell2HTTP/)
4
8
5
-
A minimalist [Flask](https://github.com/pallets/flask) extension that serves as a REST API wrapper for python's subprocess API.<br/>
9
+
A minimalist [Flask](https://github.com/pallets/flask) extension that serves as a REST API wrapper for python's subprocess API.
6
10
7
11
-**Convert any command-line tool into a REST API service.**
8
-
- Execute pre-defined shell commands asynchronously and securely from flask's endpoints.
12
+
- Execute pre-defined shell commands asynchronously and securely via flask's endpoints.
9
13
- Designed for development, prototyping or remote control.
10
14
11
15
Inspired by the work of awesome folks over at [msoap/shell2http](https://github.com/msoap/shell2http).
@@ -18,91 +22,17 @@ Inspired by the work of awesome folks over at [msoap/shell2http](https://github.
18
22
- This is useful for internal docker-to-docker communications if you have lots of different binaries. See [real-life example](https://github.com/intelowlproject/IntelOwl/blob/develop/integrations/peframe/app.py).
19
23
- Currently, all commands are run asynchronously, so result is not available directly. An option would be provided for this in future release.
20
24
21
-
> Note: This module is primarily meant for running long-running shell commands/scripts (like nmap, code-analysis' tools) in background and getting the result at a later time.
25
+
> Note: This extension is primarily meant for executing long-running
26
+
> shell commands/scripts (like nmap, code-analysis' tools) in background from an HTTP request and getting the result at a later time.
We have created some example python scripts to demonstrate various use-cases. These include extension setup as well as making HTTP calls with python's [requests](https://requests.readthedocs.io/en/master/) module.
4
+
5
+
-[run_script.py](https://github.com/Eshaan7/Flask-Shell2HTTP/blob/master/examples/run_script.py): Execute a script on a succesful POST request to an endpoint.
6
+
-[basic.py](https://github.com/Eshaan7/Flask-Shell2HTTP/blob/master/examples/basic.py): Map a base command to an endpoint and pass dynamic arguments to it.
7
+
-[multiple_files.py](https://github.com/Eshaan7/Flask-Shell2HTTP/blob/master/examples/multiple_files.py): Upload multiple files for a single command.
0 commit comments