Giter Site home page Giter Site logo

send command about python-backdoor HOT 19 CLOSED

xp4xbox avatar xp4xbox commented on July 20, 2024
send command

from python-backdoor.

Comments (19)

xp4xbox avatar xp4xbox commented on July 20, 2024

I am not sure, I just tried it out with a 20mb file and it worked fine..

from python-backdoor.

ArlenRicard avatar ArlenRicard commented on July 20, 2024

I have the same problem, I performed the test with two types of files, the first a notepad file containing only plain text with a size of 5mb, the second binary file also of 5mb. The text file has been uploaded correctly, since the binary file hangs in ... "Total bytes sent : 5242880 ( 5,242,880)" The script simply hangs in that part, and I need to close and reopen both server and client.
Note: The download function works correctly, since the upload function hangs when sending binary files, executables etc.
I performed the test in an external server / external client environment. I did not test the local network, server runs Win7x64 and Client Win10x64.

from python-backdoor.

ArlenRicard avatar ArlenRicard commented on July 20, 2024

About upload problem, I did several tests. And I saw that the problem has no relation to the file type, whether it is executable or text file. The problem seems to be with some packet loss at the time of shipment. The larger the file being sent, the greater the chance of 1-byte corruption, and somehow the client or server does not handle it. And it just hangs.
I did the test with very small file of 100kb, text files and executable. Both files have been transferred.
So I was increasing the size of the file, I was able to send at maximum 800kb without crashing.
So I did a network stress test, opened a torrent application and donated my entire upload. After that, when trying to send files to the client, I managed to transfer only files from 100 to 200kb, more than that the server crashed.
On a local network will work smoothly, because the bandwidth is usually 1GBps, versus 600kbps from an external network. So the tests performed on virtual machines do not count as much for diagnostic purposes of this problem.

I did these tests using the download and upload options, both caught when sending or receiving files during and without network stress.

Perhaps implementing another form of handling the server, and receiving by the client solves the problem.

from python-backdoor.

ArlenRicard avatar ArlenRicard commented on July 20, 2024

I was researching, and it seems that this upload problem affects many people who are developing a project with the parameters and functions similar to yours.
I have yet to find an efficient way to eliminate this file transfer problem between server and client.
I wanted to suggest another option, which can be considered an implementation, even if temporary.
Since I can not transfer files directly from the server to the client using the conventional method, I was thinking of using an http or ftp server to store everything I want the client to download. So I upload these files to my http server. And then I pass this command to the client to download, using the same idea of ​​downloading the keylogger from the github repository.
Would it be possible to add another menu to the server so that I could insert the direct link from that file? ex: https: //www.myserver.com/myfile.rar .exe ... etc ...
It has a similar function already on the server, but it is that of opening the browser, however it is very noisy. It would be best to implement on top of that new "requests.get" paramenter that you are using in the developer version.

from python-backdoor.

xp4xbox avatar xp4xbox commented on July 20, 2024

I previously added that feature, but I removed it, since it was basically just a powershell command that you could run using the remote cmd feature.

from python-backdoor.

ArlenRicard avatar ArlenRicard commented on July 20, 2024

Yes I had already tested this possibility as well, but the server cmd does not run the powershell. By typing powershell in the server cmd it crashes as well. I tried to download it through the Invoke-WebRequest parameter of powershell, but the server crashes. I tried using the -File script.ps1 parameter of powershell, but the server hangs and returns nothing.
Not to mention that we can not rely so much on powershell, several versions of windows 7 and some early windows 10 comes off by safely executing scripts by powershell.
But thank you for being helpful.

from python-backdoor.

ArlenRicard avatar ArlenRicard commented on July 20, 2024

Okay, I was able to solve the powershell problem, running it in a second instance and not first by the server. It's nothing practical but it will do.
Windows 7 does not have many libraries that Windows 10 already has, such as Invoke-WebRequest and Wget. But I got it another way.

from python-backdoor.

xp4xbox avatar xp4xbox commented on July 20, 2024

@ArlenRicard try running just the client without building it to .exe. Probably not related, but might be as seen with the keylogger.

from python-backdoor.

ArlenRicard avatar ArlenRicard commented on July 20, 2024

So on this problem I'm doing the following:
These tests, I perform in two environments. One on a local network, another on an external network.
The local network test works without problems, even because of the time of error, the transfer speed is instantaneous. Already in external network delay, since the network here transfers to 60kb / s against 100mb / s of the local network.
Since I can not upload more than 400kb of file without the system crash, I upload a .bat file normally of 5kb at the maximum containing only the powershell commands.
So this powershell .bat, search everything I need on my HTTP server.
It does not have to be with antivirus, because the virtual machines that I use are clean, have only the client of your project.
But for now I'm using the http server to upload the client files.

from python-backdoor.

ArlenRicard avatar ArlenRicard commented on July 20, 2024

This problem, I believe will take time to have a solution. Looking on the internet, I have seen that many have this file transfer problem. This problem is similar to that problem of the windows ftp feature, it seems that it uses a treatment for very limited packet receive transmission, so these problems happen.
Unlike you install an apache on the computer, and use your machine as http server. I did this to test, and seamlessly transferred all files from 30 up to 80mb.
So this problem really seems to be with the handling of those data packets at the time of transmission and reception.

from python-backdoor.

xp4xbox avatar xp4xbox commented on July 20, 2024

I actually had theses same problems on Linux when I was incorporating some of theses features. The reason was, some of the byte data got lost while sending it since I was trying to send all the data as one. I fixed this by incorporating a recvall() function which checks to make sure all the data has been received.

from python-backdoor.

ArlenRicard avatar ArlenRicard commented on July 20, 2024

Well, in my case I have not been successful yet. It's been a long time since I used the --s function to send files. However I tried to send now a simple 2mb binary.
But it always hangs at the end, displaying the file size and nothing else.
I am using server and client updates.
errorsendfile

from python-backdoor.

xp4xbox avatar xp4xbox commented on July 20, 2024

@ArlenRicard could you try testing the screenshot module, since it should generate a decently large file.

from python-backdoor.

ArlenRicard avatar ArlenRicard commented on July 20, 2024

Yes I tested it, the screenshot function worked perfectly, I had no problem with receiving files. Only with the sending, using the --s function.

from python-backdoor.

xp4xbox avatar xp4xbox commented on July 20, 2024

Very strange, they both use the same code for sending the file, could you try sending the screenshot using the --s option?

from python-backdoor.

ArlenRicard avatar ArlenRicard commented on July 20, 2024

I'm going to take a test now. I will try to send 2 types of files 3 times each. And I'll post the result here.

from python-backdoor.

ArlenRicard avatar ArlenRicard commented on July 20, 2024

You were right, the problem was solved.
About the image that I sent, I had done the test only once with a file, and so it gave problem I gave up.
I took the test now to take my doubts, I tried to send the same file 3 times.
I tried uploading a .bmp file 3 times: Success in 3 attempts.
I tried uploading a .rar file 3 times: Success in 3 attempts.
sucess

from python-backdoor.

xp4xbox avatar xp4xbox commented on July 20, 2024

@ArlenRicard Can I close this now?

from python-backdoor.

ArlenRicard avatar ArlenRicard commented on July 20, 2024

Yes, so far it's working perfectly for me.

from python-backdoor.

Related Issues (20)

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.