One of most common and potentially most painful task you will have to perform as a penetration tester is retesting.
However, in most cases, you will have the same problems you can have during an initial test: waiting for the environment, waiting for credentials, waiting for valid credentials… Sometimes you will just be given a report (sometimes from a competitor) with a list of issues and you will realise that it is a pretty good way to rate the quality of someone else’s report!
By retesting, you will quickly learn the difference between:
In the second sentence, you have almost everything you need to retest the issue; in the first sentence, not so much.
The simplest way is to have a script to retest each issue. I know of at least one company who uses browser automation (i.e.: driving a browser with tools like Watir, Selenium or Chrome headless) to perform most of their retesting. This allows testers to easily retest an issue in a fully working browser and have a quick feedback on whether or not things have been changed.
Other companies save Burp requests to ensure they have, at least, the bare minimum on a given vulnerability. It’s probably better to keep each vulnerability test cases in a separate file instead of having a big file (default option for Burp Suite) with all the details of your testing (remember retesting may happen up to a few years later). Along with these files, it’s common to keep a step by step explanation on how to get there.
Log in as user1 or any users with the privilege “Standard User”
This looks like a lot of work but you can see all the pitfalls you will avoid…and all the time you will save:
Now Imagine how much time you could have wasted if you didn’t have this information. Furthermore, you will probably have miss the bug since you need to log out and log in again to trigger it.
You can provide all this information as part of the report (in Appendix) or in a folder with all the information you had/use during the testing along with all the logs and output of your tools. Keeping this information out of the main report will help keep things clear in the write-up and will ensure a reasonable size report…
Another point is how to retest, having test cases that pass or don’t pass allow you to perform a quick check to ensure something has changed. It doesn’t ensure that something has been fixed. You can probably find another payload that will allow you to bypass the fix provided by developers/system administrators.
You also need to be ready for the fact that sometimes you will get asked to retest an application where none of your recommendations have been applied and the application is as vulnerable as when you initially tested it. That’s quite a frustrating (and recurring) thing especially if you work for big companies, but you need to understand that your clients don’t necessarily have the visibility to ensure fixes get implemented. And sometimes, you even get people telling the security team that everything as been remediated even if nothing was changed, just to get rid of them and go back to their daily work.
Hopefully, this article convinced you that retesting can be made easier by spending a little bit more time writing things down during your testing.