Is your browser teaching Ethical Hacking ?

You might be thinking about this topic,  Many of us, use various toolkit for various purpose for (un/) – professional ethical hacking. We used (Man-In-Middle)proxy interceptor, Scanner, Intruder, Decoder, and many more things while performing web auditing.

Very first step of ethical hacking is reconnaissance.  Sometimes we used 3rd party toolkit to do information gathering, absolutely the process of professional security enthusiasm is different, it depends on the perspective of them. No one can judge their professional security method in right and wrong category. This article is waiting to introduce about browser that help tester, developer and security professional etc.

OWASP Mantra Security Framework is the browser that i would like to introduce.

Here is the Source Information of OWASP Mantra Portal 1/2/3 :

OWASP Mantra is such an innovative product, a security framework built on top of a browser. Its cross-platform, portable and can run out of the box. You can take it with you where ever you go in absolutely any rewritable media including memory cards, flash drives and portable hard disks. More over, Mantra can be used for both offensive security and defensive security related tasks which makes it incredible.

Mantra is a free and open source security toolkit with a collection of hacking tools, add-ons and scripts based on Firefox and Chromium. It is intended for web application penetration testers, web application developers, security professionals, etc.

OWASP Mantra is a powerful set of tools to make the attacker’s task easier. The beta version of Mantra Security Toolkit has various tools built onto it. Moreover Mantra follows the guidelines and structure of FireCAT which makes it even more accessible. The OWASP Mantra Security Toolkit has tools under the following categories. The complete list of tools is available on the official website. (List of Tools)

  • Information gathering
  • Editors
  • Network utilities
  • Miscellaneous
  • Application auditing
  • Proxy

Mantra browser is teaching many times with the help of their Gallery and Hackery collection 🙂

1. Galley – Online Penetration Testing Tools Index

2. Hackery – Open Penetration Testing Bookmarks Collection

Mantra officially integrated with BackTrack 5 Linux in May 2011 and Matriux Krypton

Lets find out with intro video of OWASP Mantra here:

And Many More Videos

Well this article is all about Mantra Browser only. All you have to do just Experience it !!

I hope i introduced this browser very well and it’s really helpful for security professional that is why the topic of article is “Is your Browser Teaching Ethical Hacking ?

Happy Learning and Happy Hacking with Mantra ^_^

Can we use browser for Web Automation ? (Google is my Real-Best Friend !)

Hi Enthusiast-er,

(I am really sorry for long wait… 😦 )

Many Time we search so many things/information with the help of Google search engine. frankly speaking, I checked my internet connection by typing in our url bar. But can you imagine how Google is helping us ?. Why we mumbled every-time that “Google is my Best friend” ? Can you analyze how Google is talking with our machines with the help of Wireshark ?

Here is some snapshot of my wireshark :-

Well above wireshark image is all about my topic today. nothing but, Talking with Google without any browser. A great resource for google hacking is Google Hacking for Penetration Testers. Volume 2.

Is there any relation between Penetration Tester and Google ? ohh.. simply YES !!

Google is just awesome tool for Penetration Testers. Just need to understand it properly, and you are gathering many information of your respective project title 😉 ! All you have to do every-time is “just ask” to Google. that’s it !

Now there are two options about to ask question to Google and that is,

  • with browser and
  • without browser

we all know about with browser, and basically we are moving to our main point of article. Lets find interesting stuff with without browser.

Here we used Perl script to get us a listing of files from Google. In this article we will be using Perl with many module as LWP::UserAgent or WWW::Mechanize

Before going directly to the Exact scripting, we surely understand Perl and Perl Script behavior through below link:
Perl Download link :- Click Here !
General Information :- Click Here !
Perl Module Information :- Click Here !
Best url all the time :- ! Google is our best friend now ! 😛

Below is the Perl script which used to get a listing of files from google with the help of LWP::UserAgent module in order to handle web task.

—————Perl Script with LWP::UserAgent————-
use LWP::UserAgent;
use HTML::Parse;
$site = @ARGV[0];
$filetype = @ARGV[1];
$searchurl =”$site+filetype%3A$filetype”;
$useragent = new LWP::UserAgent;
$useragent->agent(‘Mozilla/4.0 (compatible; MSIE 5.0; Windows 95)’);
$request =HTTP::Request->new(‘GET’);
$response = $useragent->request($request);
$body = $response->content;
$parsed = HTML::Parse::parse_html($body);
for (@{ $parsed->extract_links(qw(a)) })
($link) = @$_;
if ($link =~ m/url/)
print $link . “\n”;

Now Understand above Perl Scripting Objects,

For defining any interpreter we used Shebang every-time in any respective scripting language.

LWP (short for “Library for WWW in Perl”) is a popular group of Perl modules for accessing data on the Web.
The LWP::UserAgent is a class implementing a web user agent. LWP::UserAgent objects can be used to dispatch web requests. Click Here for full LWP::UserAgent Description.

The name of site goes into $site and type of file goes into $filetype.

The string in $searchurl is a simple Google Search, with the values in $site and $filetype plugged in, in the appropriate places.

Then comes the useragent part of scripting to know the google about browser agent identifier.

HTTP::Request is a class encapsulating HTTP style requests, consisting of a request line, some headers, and a content body. Understand the basic idea, about how the request we are handling with $request and $response objects.

Next we used (HTTP::Parse) Parse module to parse the content of $body out into something we

Then we put together a for loop to go through our lines, looking only for the links and , of those links, only the links of href variety, and discarding images and other links in which we are not interested.

See below, my screenshot of command line Perl script output :-

( hope you can understand the white patches on images 😛 )

Save above script as and type command as “./ website(url) filetype” for example “./ pdf” and you will get the result as above in jpg image.

Before going to next module of perl, we can used bit command line module as LWP::Simple, Here is the single command line: perl -MLWP::Simple -e “getprint ‘'”

Now there is another beauty in Perl known as WWW::Mechanize module, we can do nearly anything from this module that we can do from web browser with a person operating it.

WWW::Mechanize, or Mech for short, is a Perl module for stateful programmatic web browsing, used for automating interaction with websites.

Features include:

  • All HTTP methods
  • High-level hyperlink and HTML form support, without having to parse HTML yourself
  • SSL support
  • Automatic cookies
  • Custom HTTP headers
  • Automatic handling of redirection
  • Proxies
  • HTTP authentication

Mech supports performing a sequence of page fetches including following links and submitting forms. Each fetched page is parsed and its links and forms are extracted. A link or a form can be selected, form fields can be filled and the next page can be fetched. Mech also stores a history of the URLs you’ve visited, which can be queried and revisited.

—————Perl Script with WWW::Mechanize————-


# Handy web browsing in a Perl object
use WWW::Mechanize;

# Name of the site, filetype, searchurl
$site = @ARGV[0];

$filetype = @ARGV[1];

# create mech as Handler
$mech = WWW::Mechanize->new();

# Sets user agent string to the expanded version from a table of actual user strings
$mech->agent_alias(‘Windows Mozilla’);

# Page Fetching Method

@links = $mech->find_all_links(url_regex => qr/\d+.+\.$filetype$/);
for $link (@links) {
$url = $link->url_abs;
$filename = $url;
$filename =~ s[.*/][];
print “downloading $url\n”;
$mech->get($url, ‘:content_file’ => $filename);}

Well we already tag comment in above perl scripting. For more Detail those who want to learn – can read Coding for Penetration Tester : Building Better Tools

Here is the video that will give you idea about wireshark with browser query

note: The google search used in above script is not the approved way to talk to google with automation. If you are not careful and abuse this type of connection, Google will get confused and ban your IP address. Google has helpfully documented the proper way for us, and we should really be using that. This is bit out of scope for what we are doing here, but documentation will get us there for constructing our queries in the approved manner.

Defensive Security – Vulnerable Web Apps Auditing

Hello Security Readers,

Find some video about SQL injection attack here,

1. Joe McCray – Advanced SQL Injection – LayerOne 2009

Joe McCray Described very nicely about the Advance SQL injection method – those who wants to have the ppt/pdf file – see the bottom of this post.

2. SQL Injection Imperva

3. Testing SQL injection with SQLmap

4. php Tutorial – Sql Injection

5. Sqlninja & Metasploit Demo

Some URL link for understanding the SQL injection:

Most Beautiful PDF file of Advance SQL injection by Joe McCray


This insanity I speak of

            There are various stages occurred in everyone’s life, when the person is at small age. He faces different problems and their solutions depending on his environment. When the person is at bachelor’s life. He learns another world from his colleges and with social environments, and at the stage of earning or becoming the employee, he has to tilt his life from family to the real world. The real world which is completely mix-up of all kinds of people. World is so beautiful, so graceful, but the main thing behind it, is how you are taking the advantage of your world from your ability. What ever you are going to do, is effect on your world only. The world which you are seeing through your eyes, so the perspective of everyone’s looking towards the world is different from you. but if you observer the things behind the perspective that some group of people reached last stage and some people stay behind cause, though the perspective of the group is different from others, still the goal they are acquiring is the same. It becomes group goal. That is why some thoughts we have to bookmark in our mind

“Everyone’s World is different. The perspective of two people looking at the same thing could be different based on their preconceived notions and thoughts.” by Tej Gyan Foundation.

strange right !! but its true, believe it or not !

These are some thoughts eagerly motivate us to spread the knowlerience (knowledge + experience) about the humanity and the source. Well as of now, I discussed the topic which is being on humanity and this platform indicates completely about the information security. sorry gentle man !

I faced so many things that I would like to share with you like when you are reading some books of the hacking/security. At very eager step, you learn techniques(tools) and later after reading full books, you get to know how to use right tool with right time ? why we do ? and what is the process and framework ? yes the same thing that I want to focus your mind on and it is UNDERSTANDING !!

Every ethical hacker needs an understanding for reason that really help to glow his career. May be people will not agree with “understanding” term but it’s according to my point of view (eye). so relax and enjoy.

Now I will explain the meaning of understanding in security field,

When you are securing your information, first you have to understand the configuration of server, client.. etc.
When you are sending your data over the network securely first to understand the encryption..
When you are reading personal data over the network first understand the decryption or malicious packages..
Understand the tool, algorithm, OS, Keys, and blah blah..

In every scenario, what you are doing on internet or network, you have to understand first, we found !

I am Niraj Mohite From Pune, MH, India – searching for the best opportunity in the field of Computer Security Research.

so lets begin with understanding about the information security

(I have never written blog post about my self and documents before. This feels a lot like LiveJournal.)