Git Product home page Git Product logo

medusa's People

Contributors

ajpc500 avatar alfiegarratt avatar coldwaterq avatar gmatuz avatar litios avatar r00t0v3rr1d3 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  avatar  avatar  avatar  avatar

medusa's Issues

Local IP address resolution fails on macOS

The agent uses socket.gethostbyname() to retrieve the IP address of the host by looking up the hostname, returned from socket.gethostname(), against either the local resolver or the hosts file.

On macOS the device hostname is not present in /etc/hosts by default, so looking up the hostname fails, causing the agent to exit.

Upload command

Upload command seems not working! It adds in padding slashes and getting upload command output:
[Errno 13] Permission denied: 'C:\Users\minka\Downloads
Running it as Administrator

error handling: name of ssl protocol does not exist on target system

Hi,
somehow on one of the target systems the ssl module does not have PROTOCOL_TLS as it is included here

"gcontext = ssl.SSLContext(ssl.PROTOCOL_TLS)\n gcontext.verify_mode = ssl.CERT_NONE")

This results at the end in the following error:
AttributeError: module 'ssl' has no attribute 'PROTOCOL_TLS'

I'm not entirely sure how this happens, just fixed it up with the following, which ends up taking PROTOCOL_TLSv1 on the system:

gcontext = ssl.SSLContext([e for e in dir(ssl) if e.startswith('PROTOCOL_TLS')][0])
if "PROTOCOL_TLS" in dir(ssl):
  gcontext = ssl.SSLContext(ssl.PROTOCOL_TLS)

I'm not sure how common this is, if it is worth adding

Callback is missing it's process name.

Hello,

Running latest version of Mythic + latest version of Medusa agent.

Medusa callback could show process name, which runs the payload.

image

Also could be cool to see all IP addresses (ipv4+6) of the target machine (similar to Poseidon agent, which shows all IP addresses).

image

Pyinstaller

Can Medusa payloads be compiled with pyinstaller to executables?

SOCKS

Cross posting it here for visibility, but there's a small issue with the SOCKS command in Medusa:

its-a-feature/Mythic#321

Super easy fix (i added the fix as a comment there)

Mythic create new callback issue

Hi,

when spawning a new linux payload (python3), the active callback cannot be created as the username field is empty:

image

Failed to create new callback null value in column "user" of relation "callback" violates not-null constraint
DETAIL:  Failing row contains (1, e11d1b05-1279-445e-af89-7cdf6a829c8f, 2022-02-06 08:56:10.628592, 2022-02-06 08:56:10.628595, null, WEB50, 35668, 172.10.10.50, 172.10.10.50, , First linux-python-payload, 1, t, 1, 2, f, null, 1, null, null, null, Linux 5.11.0-49-generic, x64, , null, , , null).

It seems as the os.getlogin() function causes the trouble, so I decided to replace it with getpass.getuser() which is also supported according to this article: https://stackoverflow.com/questions/47444178/difference-between-os-getlogin-and-os-environ-for-getting-username

Always fail in docker containers

Always fail in docker containers

docker pull ubuntu:20.04
docker run -itd --name ubuntu-test ubuntu:20.04
docker exec -it 6822bb6bb8aa6d7dec7c87daf0782aa9fd81c4fcf8a858a4c505b7bedd121af6 bash
apt update
apt install python3 python2 wget -y
wget http://1.1.1.1/test.py
python3 or python2 test.py

Decode the error message as follows

{"status":"error","error":"Failed to create callback: null value in column \"user\" of relation \"callback\" violates not-null constraint\nDETAIL:  Failing row contains (34, bbc2c88c-2df8-4b62-9148-5726a39313d5, 2023-02-22 21:47:59.525972, 2023-02-22 21:47:59.525976, null, 6E86881CAB32, 3903, 172.17.0.3,  172.70.211.58, , medusa_py3_linux, 1, t, 29, 2, f, null, 1, null, null, null, Linux 5.15.0-60-generic, x64, , null, , , null).\n"}

Use minimal generation. It still has this error. Seems to be a problem with encryption and decryption

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.