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

Upload command! #6

Open
Chomikmarkus opened this issue Dec 8, 2021 · 5 comments
Open

Upload command! #6

Chomikmarkus opened this issue Dec 8, 2021 · 5 comments

Comments

@Chomikmarkus
Copy link

Seems that upload command is not working!
When i issue upload command its freeze agent and seems that agent disconnects as no callbacks is made! From proccess hacker on windows machine i can see that proccess is running but no callbacks made! Command itself does not produce any error output and agent built itself works fine

@Chomikmarkus
Copy link
Author

V2.3-Testing upload.py error output:
[-] atlas ran into an error processing upload:
'File to Upload'
Traceback (most recent call last):
File "/usr/local/lib/python3.8/site-packages/mythic_payloadtype_container/mythic_service.py", line 269, in callback
final_task = await Command.create_tasking(task)
File "/Mythic/mythic/agent_functions/upload.py", line 51, in create_tasking
filename = json.loads(task.original_params)["File to Upload"]
KeyError: 'File to Upload'

@Chomikmarkus
Copy link
Author

also load_assembly runs into error
[-] atlas ran into an error processing loadassembly:
Error from Mythic: 73 : add_arg() got an unexpected keyword argument 'name'

@its-a-feature
Copy link
Contributor

just fixed those two parsing issues, i'll wait for @airzero24 to update the underlying code though

@s1lvershad0w
Copy link

s1lvershad0w commented Feb 3, 2022

@its-a-feature - I'm facing the below error when I try to upload files(.exe, .txt). Could you help me resolve this? :

-----error-creating task
[-] atlas ran into an error processing upload: 
a bytes-like object is required, not 'str'
Traceback (most recent call last):
  File "/usr/local/lib/python3.8/site-packages/mythic_payloadtype_container/mythic_service.py", line 277, in callback
    final_task = await Command.create_tasking(task)
  File "/Mythic/mythic/agent_functions/upload.py", line 53, in create_tasking
    file=base64.b64encode(task.args.get_arg("assembly_id")).decode(),
  File "/usr/local/lib/python3.8/base64.py", line 58, in b64encode
    encoded = binascii.b2a_base64(s, newline=False)
TypeError: a bytes-like object is required, not 'str'
-----

@its-a-feature
Copy link
Contributor

Hey! I just updated the python files, so you should be able to do sudo ./mythic-cli install github https://github.com/MythicAgents/atlas -f to just pull in the latest (or you can look at the merge i just did from the v2.3 branch to see what i updated).

However, there's an outstanding issue that @airzero24 is aware of that's causing an issue with files in atlas. For some reason, when uploading (or registering an assembly), atlas isn't processing the final success message, so it gets stuck in a weird loop reporting that it's loaded or uploaded an infinite number of times.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants