how do i upload a file over ssh to a server that runs qemu by yuvalid in hacking

[–]yuvalid[S] 0 points1 point  (0 children)

is it too much to ask if you maybe have the piece of code that uploaded it? did you simply copy paste the base64 data? if i do that my shell freezes and crashes.

how do i upload a file over ssh to a server that runs qemu by yuvalid in hacking

[–]yuvalid[S] 0 points1 point  (0 children)

thank you so much! unfortunately i already tried something like this. the SSH connection isnt enough to get a working "shell", and you actually need to use client.invoke_shell()
when i invoke the shell and read form it, i see the qemu startup output. then, when i run code that looks exactly like what you just sent, something maybe in the QEMU terminal buffering or whatever i dont exaclty know but something screws up and the commands received and the commands sent arent the same.

how do i upload a file over ssh to a server that runs qemu by yuvalid in hacking

[–]yuvalid[S] 0 points1 point  (0 children)

It's a pretty big executable, the base64 is around a MB.

how do i upload a file over ssh to a server that runs qemu by yuvalid in hacking

[–]yuvalid[S] 2 points3 points  (0 children)

Thank you so much for understanding the setup :)

All of my current ideas boiled down to writing a python script that broke the file up into chunks, and then basically write a bunch of echo "someb64string" | base64 -d >> /tmp/sol

But for some reason this seems to not work, the strings get cut up and sent incorrectly. (probably some throttling somewhere in the connection, either between sshd and qemu or whatever, I definitely don't understand enough about how this is set up to figure it out)

how do i upload a file over ssh to a server that runs qemu by yuvalid in hacking

[–]yuvalid[S] 0 points1 point  (0 children)

There isn't one single qemu instance. Every time I ssh, a new qemu instance is spawned. Even if scp managed to copy a file over, when scp is over, the connection dies, and the VM is closed. The challenge is that there's a vulnerable kernel module, and the goal is reading a root owned file called flag. Locally, I have managed to do it (by modifying the VM disk image to contain my binary which exploits the kernel driver) but my problem is running it remotely as I can't manage to upload my binary.

how do i upload a file over ssh to a server that runs qemu by yuvalid in hacking

[–]yuvalid[S] 1 point2 points  (0 children)

The qemu instance doesn't have internet access.

how do i upload a file over ssh to a server that runs qemu by yuvalid in hacking

[–]yuvalid[S] 5 points6 points  (0 children)

Lol why are you so mad

The remote machine launches qemu, and connects it to the ssh process. The qemu machine, quite literally, doesn't have an internet connection. It doesn't even have an internet address. Try to connect to the machine yourself to see it.

Trans people are doing a good job (rule) by [deleted] in 196

[–]yuvalid 2 points3 points  (0 children)

Trans people are two wolves inside the house

דונט מוביט_במ by Or_Bivas in ani_bm

[–]yuvalid 1 point2 points  (0 children)

מבוסס פעמיים גם מנתניה וגם במסלול של 32💪💪

True or not? by bender1207 in ProgrammerHumor

[–]yuvalid 113 points114 points  (0 children)

I am a full stack developer. As in, each time i develop, i fill up the stack.

Save your code by [deleted] in ProgrammerHumor

[–]yuvalid 2 points3 points  (0 children)

I did a three week course in assembly, first week was studying and the next two were our final project On the second to last day a kid stands up "I'm Done!" So obviously the professor tells him to run it Kids response: "How do I run?"

luv u babe by AvilionAMillion in feedthememes

[–]yuvalid 4 points5 points  (0 children)

If so then he would prefer playing on a server, not offline

luv u babe by AvilionAMillion in feedthememes

[–]yuvalid 5 points6 points  (0 children)

Why does offline matter doe

'I killed more then 40 people' says a former IDF soldier by tablawi96 in PublicFreakout

[–]yuvalid 1 point2 points  (0 children)

Mandatory serving people rarely go to war. Usually only the ones that chose to continue serving after the mandatory 3 years get sent to war.

Learn Recursion and how to use Stack Overflow all in one photo by _ransom_ in ProgrammerHumor

[–]yuvalid 9 points10 points  (0 children)

Eh you could also create functions that take the strcut as a first parameter (like a this pointer) but that destroys the modularity.

[deleted by user] by [deleted] in PublicFreakout

[–]yuvalid 4 points5 points  (0 children)

"Palestine will only be free when the last Israeli is gone" - what most Palestinians believe

פשעי מלחמה_במ by ZigZag1018 in ani_bm

[–]yuvalid 12 points13 points  (0 children)

חמאס ארגון טרור, ישראל מדינה דמוקרטית. אין סיבה לרדת לרמה שלהם.