Wednesday, 7 March 2012

Hiring pentesters... (2/?)

After the first post on hiring pentesters I thought I had to keep going... A lot of people read it and apparently liked it... If you are really interested by the interview process, matasano's one is pretty impressive...

Before the interview (or even before you read the resume), it's good to have a basic opinion on someone's skills... I wrote a simple website with 20 questions to get a quick feeling of who I'm talking to.

The questions are simple but allow to detect people with no security knowledge. Below are 2 of the 20 questions so you can see what I'm talking about:
  • unmd5 is the PHP function used to retrieve the clear text of a md5 ? True/False
  • Windows passwords are stored in C:\Windows\System32\drivers\etc\shadow ? True/False
If someone passes this test, the real technical interview can start.

As always, you will have the normal security questions (I guarantee most security companies ask for these):
  • explain a tcp handshake
  • how Windows passwords are stored?
  • what is a cookie?
  • opinion on disclosure?
From my experience, I think it's better to ask people to explain things than just to ask them what it's. You can really see what level of understanding people have of a problem...

For example, with Cross Site Scripting, you can have the following responses:
  • "it's a problem of filtering and it allows an attacker to inject script in the page"
  • "it's a problem of filtering and an attacker can display/run arbitrary code in victims' browser"
  • "it's a problem of output encoding and can be used to inject Javascript or HTML in the page sent back to victims"
  • ...
That way, you're able to see if the person really understands what's going on and how he will be able to explain it to someone else.

You need to have 2 types of questions:
  • questions based on memory: "what port is used by X", "what nmap options do you used"
  • questions based on reflection: "how will you solve that problem"

I also have my favorite set of questions:
  • "You're going to PentesterLab's website, explain what happens...", that way you can see someone's knowledge of TCP/IP, DNS, HTTP, SSL, ...
  • "What is the last cool thing you learned/read", that way you can see what people are interested by and where they at
After this test, another interview is setup with hands-on test (only if the person did good enough obviously), it's currently the web application of the exercise "From SQL injection to shell" and it's used to see how people think and behave with a computer.

You can see a lot of different things:
  • what people use for desktop
  • how fast someone is with his computer
  • how people solve a problem
  • if people bring a working laptop (yes it happened, someone came to an interview with a broken gentoo...)
  • learn from people: sometime people show you cool tricks you didn't think of
  • ...
Obviously, not everyone (actually only one person did it without any help so far) knows how to exploit a SQL injection manually (why do you think I created PentesterLab). But during the test, we help people and show how things work to see how they can learn new things and incorporate information into their way of thinking.