Giter VIP home page Giter VIP logo

dwn's People

Contributors

anubissec avatar leonjza avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

dwn's Issues

how to pipe with dwn?

Hello, I find your project very interesting, so thanks in advance.

I have a question, how could I make use of "pipe" to pass data between tools using dwn?

considering that one of the plans is gau, regularly with gau we could do this:
printf example.com | gau
or even concatenate with multiple tools that they will be gradually integrated and support STDIN with pipe.. so, I think that this is currently a limitation of the project or maybe I just don't know how to make it possible with dwn.

support tag for plans image?

Once I try to use tag for image like image: longlone/glimmer:cli, I got a horrible error, it seems that dwn image can't support image tag, and always use latest tag, If dwn can add support for the image tag?

Traceback (most recent call last):
  File "/usr/local/lib/python3.9/dist-packages/docker/api/client.py", line 268, in _raise_for_status
    response.raise_for_status()
  File "/usr/local/lib/python3.9/dist-packages/requests/models.py", line 943, in raise_for_status
    raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 400 Client Error: Bad Request for url: http+docker://localhost/v1.40/containers/create?name=dwn_glimmer

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/local/bin/dwn", line 8, in <module>
    sys.exit(cli())
  File "/usr/local/lib/python3.9/dist-packages/click/core.py", line 829, in __call__
    return self.main(*args, **kwargs)
  File "/usr/local/lib/python3.9/dist-packages/click/core.py", line 782, in main
    rv = self.invoke(ctx)
  File "/usr/local/lib/python3.9/dist-packages/click/core.py", line 1259, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/usr/local/lib/python3.9/dist-packages/click/core.py", line 1066, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/usr/local/lib/python3.9/dist-packages/click/core.py", line 610, in invoke
    return callback(*args, **kwargs)
  File "/usr/local/lib/python3.9/dist-packages/dwn/cli/commands/base.py", line 77, in run
    service = plan.container.run()
  File "/usr/local/lib/python3.9/dist-packages/dwn/plan.py", line 377, in run
    container = self.get_client(). \
  File "/usr/local/lib/python3.9/dist-packages/docker/models/containers.py", line 811, in run
    container = self.create(image=image, command=command,
  File "/usr/local/lib/python3.9/dist-packages/docker/models/containers.py", line 870, in create
    resp = self.client.api.create_container(**create_kwargs)
  File "/usr/local/lib/python3.9/dist-packages/docker/api/container.py", line 430, in create_container
    return self.create_container_from_config(config, name)
  File "/usr/local/lib/python3.9/dist-packages/docker/api/container.py", line 441, in create_container_from_config
    return self._result(res, True)
  File "/usr/local/lib/python3.9/dist-packages/docker/api/client.py", line 274, in _result
    self._raise_for_status(response)
  File "/usr/local/lib/python3.9/dist-packages/docker/api/client.py", line 270, in _raise_for_status
    raise create_api_error_from_http_exception(e)
  File "/usr/local/lib/python3.9/dist-packages/docker/errors.py", line 31, in create_api_error_from_http_exception
    raise cls(e, response=response, explanation=explanation)
docker.errors.APIError: 400 Client Error for http+docker://localhost/v1.40/containers/create?name=dwn_glimmer: Bad Request ("invalid reference format")

add command attach

just add a command called dwn attach to attach dwn docker instead of raw docker attach, it can also be more convenient to be lazy: use dwn attach netcat-reverse instead of docker attach dwn_tcap_netcat-reverse

Unreasonable project structure

i think plans directory should not be placed outside the dwn folder, this will cause site-packages to be contaminated (for example, if there is another project named plans)

Client Error: Not Found for url: http+docker://localhost/v1.41/images/dwn-network:local/json

installed dwn in KALI Linux 2020.3 using:
pip install dwn

Trying to run:
dwn run ffuf

getting error:

(i) network image dwn-network:local does not exist, quickly building it
Traceback (most recent call last):
  File "/usr/local/lib/python3.9/dist-packages/docker/api/client.py", line 268, in _raise_for_status
    response.raise_for_status()
  File "/usr/local/lib/python3.9/dist-packages/requests/models.py", line 943, in raise_for_status
    raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 404 Client Error: Not Found for url: http+docker://localhost/v1.41/images/dwn-network:local/json

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/local/lib/python3.9/dist-packages/dwn/plan.py", line 275, in _ensure_net_exists
    self.get_client().images.get(config.net_container_name())
  File "/usr/local/lib/python3.9/dist-packages/docker/models/images.py", line 316, in get
    return self.prepare_model(self.client.api.inspect_image(name))
  File "/usr/local/lib/python3.9/dist-packages/docker/utils/decorators.py", line 19, in wrapped
    return f(self, resource_id, *args, **kwargs)
  File "/usr/local/lib/python3.9/dist-packages/docker/api/image.py", line 253, in inspect_image
    return self._result(
  File "/usr/local/lib/python3.9/dist-packages/docker/api/client.py", line 274, in _result
    self._raise_for_status(response)
  File "/usr/local/lib/python3.9/dist-packages/docker/api/client.py", line 270, in _raise_for_status
    raise create_api_error_from_http_exception(e)
  File "/usr/local/lib/python3.9/dist-packages/docker/errors.py", line 31, in create_api_error_from_http_exception
    raise cls(e, response=response, explanation=explanation)
docker.errors.ImageNotFound: 404 Client Error for http+docker://localhost/v1.41/images/dwn-network:local/json: Not Found ("no such image: dwn-network:local: No such image: dwn-network:local")

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/local/bin/dwn", line 8, in <module>
    sys.exit(cli())
  File "/usr/local/lib/python3.9/dist-packages/click/core.py", line 829, in __call__
    return self.main(*args, **kwargs)
  File "/usr/local/lib/python3.9/dist-packages/click/core.py", line 782, in main
    rv = self.invoke(ctx)
  File "/usr/local/lib/python3.9/dist-packages/click/core.py", line 1259, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/usr/local/lib/python3.9/dist-packages/click/core.py", line 1066, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/usr/local/lib/python3.9/dist-packages/click/core.py", line 610, in invoke
    return callback(*args, **kwargs)
  File "/usr/local/lib/python3.9/dist-packages/dwn/cli/commands/base.py", line 77, in run
    service = plan.container.run()
  File "/usr/local/lib/python3.9/dist-packages/dwn/plan.py", line 367, in run
    self._ensure_net_exists()
  File "/usr/local/lib/python3.9/dist-packages/dwn/plan.py", line 279, in _ensure_net_exists
    _, logs = self.get_client().images.build(
  File "/usr/local/lib/python3.9/dist-packages/docker/models/images.py", line 287, in build
    raise BuildError(chunk['error'], result_stream)
docker.errors.BuildError: The command '/bin/sh -c apk add --update --no-cache           socat   && rm -rf /var/cache/apk/' returned a non-zero code: 1

are there more requirments to install ?

Hi,
i have a fresh install of Ubuntu 18.04 LTS and have tried it 2 ways first with the offical docker install for Docker and Compose Python3 and pip3. I thought theres maybe a depency conflict so i startet from scratch only with python3 pip3 and python-docker via pip but i still get an traceback error if i run plain "dwn" or any one of the other commands

root@host:/home/user# dwn Traceback (most recent call last): File "/usr/local/bin/dwn", line 7, in <module> from dwn.cli.cli import cli File "/usr/local/lib/python3.6/dist-packages/dwn/cli/cli.py", line 4, in <module> from dwn.cli.commands.base import check, run, stop, show File "/usr/local/lib/python3.6/dist-packages/dwn/cli/commands/base.py", line 59 if not (plan := loader.get_plan(name)): ^ SyntaxError: invalid syntax

it there anything else i have to install to use this toolkit ?

my python version is 3.6.9

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.