Hello everybody.
Welcome back.
And right now let us call a code a simple help command in our reverse shelter so open up your server
first of all let's start off with the server part of the code.
And right now let us see what we can get.
If we type here help.
So if I just go on and make another real fast if else statement so let's make that if l statement right
at the beginning so else if command.
And then first four letters since help has four letters.
Equals equals to help what we want to do is actually receive from our reversal all the available commands.
So what we want to do right here is basically.
Actually you know what we do not even need this since we are actually receiving it right here the reverse
Shell will send it back to us.
So this code is not necessary at the moment.
We'll see if I was correct.
Right after you finished the reversal.
So save this.
Now let's turn on the reverse shall not be why.
And here we must add if the command equals equals to help so let's go right here elusive command equals
equals to help then two dots
what we want to do is create the string so help underscore options.
Let's make that string to be are multiplying strings so we can do that I believe with three
so we can use three quotes right here in order to create a multiple line string.
So let's see what are our available options currently.
So download.
Let us add that first.
So download and then the download will equal to the for example.
Let us create this Sara.
Download our file from Target B C then we will have the upload right here.
Let me just
make it the same line.
Let's go this back one back and let us set the upload to be upload file to target b c the next command
we have will be B for example get so get command and that get command will actually be what.
Let me just see what the get command is.
It is download file from specified you URL Okay so download file to target from any website.
So let us add here also get and then the URL so users know that they need to specify the URL and here
that.
So we need to specify the path also right here path.
And let us make this a little bit prettier so it is in the same line.
The next command would have right here.
E D starts so we can actually use these start commands as well so start.
And then the path to the program
start program on target B C for example notepad calculator and all of the things that we started in
the previous video so screenshot
and we can said that we know what screenshot is.
So screenshot take a screenshot of targets monitor for example let me see if we have anything else for
now the check will check if we are admin and that should be it so check
check and then we add this error right here check for administrator privileges.
So this is all of the commands or we have to do right now here is close the three quotes and this will
become a multi line so 3 single quotes right here and three single quotes at the end and this is a multi
line strength now I'm not really sure how this will turn out in the in the receiving of this we will
see in just a second but right now before we actually compile this we need to send this so reliable
sent and we need to sell Sandy health options
so that this would be about it.
I believe this is the all the code we need once we send that it will go back and try to receive other
comments so good.
Let us save this.
Let's compile it with the same command.
Once we co-pilot we stand ready.
Plug in our USP drive in order to transport it.
Now if you want to transport it tower up at your door it might be actually faster than with this.
As we drive plugging in and unplugging in but however you want to do it let's see if this will work
now.
Now I will go to the tests not reverse shout to the media route and then the cat alive and then unplug
the USB drive.
Right now what they want to do is run our server.
Let me open the file and right now I will run the shell but it will not open the picture since I didn't
delete the registry and the command prompt path but it doesn't even matter.
However we will receive the shell back.
Just the picture or the image will not open or we want to check out.
Now is the help command and see if we get prompted our available options for using this reverse shell.
So we get here the shell we type your help and we can see that we get the all of the commands back.
Now beyond the team will have to change is we need to tap this.
So we need to tap this to be the part of the string we can tap it with basically just tapping it like
this.
So let me just show you what we need to fix in order for this first part to also be in line with this
other part.
So how we can do that.
Just copy this empty file empty space right here we can press here.
Cue we can now know the reverse shell the p y man right here.
All we have to do is actually add that space right here.
Paste Now this does look a little bit ugly but this will fix the problem for us.
So let us try once again.
Let us compile program.
We will do this real fast like in the US b drive.
Also let's close the one that is already running let us see if we fix the problem.
So if everything is in line right now and if we can see our available options correctly.
So these compiled go to this more reverse shell to the media route and then carry live go on directly
back on the server and let's see how this will work right now.
It should work.
Here we go.
We run this.
We wait for the for the connections to come back and then we will run the command once again and we
will finish the tutorial right here and then for every.
For example option you add to the reversal you want to also add it into the help option so users of
the server know what they're worth what their available options are.
So type your help and we can see right now all our available options are printed out correctly so help.
Once again you can see everything is good.
We can now check out for example used one of these options so check user privileges.
We can also take screenshots if we wanted to.
We can do anything we want so that would be about it.
For this tutorial I hope you enjoyed it and I hope I see you in the next one.
My.