Juliar Webserver: GETting parameters – Part 1

November 17, 2016 | Views: 1876

Begin Learning Cyber Security for FREE Now!

FREE REGISTRATIONAlready a Member Login Here

Hey guys,

In order to follow this tutorial, you must have *Juliar* installed with a web server.

Run Juliar as a webserver, create index.ju file in webfiles and add the following to index.ju:

*get query/test *

This will basically access the object query that is automatically populated if run as a web server.

We will be populating using GET request, so we can type in the URL parameters.

So, let’s say our host is localhost/index.ju

In order to pass parameter “test”, we do localhost/index.ju?test=22
This will pass the parameter test with value 22.

So when we open up our website, you will see that 22 is displayed. Change from “test=22” to “test=random” and you will see that the words random appear.

We can now pass items to the server and access them with *get query/ * method.

What if we wanted to have two parameters? Well simple, in the index.ju file we create something like:

*get query/param1 *
*get query/param2 *

In the URL we need to separate parameters via ‘&’ i.e.:
We can now pass parameters via “localhost/index.ju?param1=hello&param2=world”

If you open that page, you should now see:

hello
world

I hope that this tutorial has been helpful. If you have any suggestions, please comment below. Also, for the latest news, visit Juliar.org.

Share with Friends
FacebookTwitterLinkedInEmail
Use Cybytes and
Tip the Author!
Join
Share with Friends
FacebookTwitterLinkedInEmail
Ready to share your knowledge and expertise?
2 Comments
Comment on This

You must be logged in to post a comment.

Our Revolution

We believe Cyber Security training should be free, for everyone, FOREVER. Everyone, everywhere, deserves the OPPORTUNITY to learn, begin and grow a career in this fascinating field. Therefore, Cybrary is a free community where people, companies and training come together to give everyone the ability to collaborate in an open source way that is revolutionizing the cyber security educational experience.

Support Cybrary

Donate Here to Get This Month's Donor Badge

 

We recommend always using caution when following any link

Are you sure you want to continue?

Continue
Cancel