an Lunch - Open Source... · most of the mainstream testing tools. It’s also based on Ubuntu...

29
1

Transcript of an Lunch - Open Source... · most of the mainstream testing tools. It’s also based on Ubuntu...

1

As an IT auditor and management consultant, I sometimes have the opportunity to see the penetration test reports which various service providers have given to my clients. What the client often hands me, usually with a roll of their eyes, is a printout of the automated report generated by some scanning tool like Nessus. The “tester” has run the scan, stuck a cover letter on the top, and left my client with a mostly useless report and a big bill. The reports are usually riddled with false positives and warnings about things like the FTP server running on their Ricoh printer.

It’s no wonder that a lot of us have a bad taste in our mouth when it comes to penetration testing.

2

3

Some testers do a much more thorough and professional job of the actual testing, but give insufficient detail in their reports. This leaves clients knowing about specific problems, but unable to replicate the tester’s findings. If I can’t replicate what you did to exploit a system, how can I possibly know when I have corrected the problem?!?

4

Whether it’s because of regulatory requirements, or just peer pressure, many different types and sizes of organizations are now undergoing penetration testing. It’s likely that you will be called upon at some point to scope and procure penetration testing services for your organization. The standards covered in the presentation should help you better understand HOW a penetration test should be performed. My hope is that you will become a good consumer of this type of service.

Outside the scope of the presentation, but still very important to understand, is that penetration testing should be risk‐based ‐ just like your other information security and assurance activities. PLEASE discuss with your tester what data and processes are of vital importance to your organization, and allow them to prioritize their efforts in those areas. The better the tester understands what you care about as an organization, the better they can test and report their findings.

5

6

The standards covered in this presentation should help you to become more familiar with how a high‐quality, high‐value penetration test can be performed. The basic material we cover today will get you started, and you can dig into the referenced material as deeply as you need to.

7

If you or your team needs to do testing of your own systems (which I would recommend before paying an outsider to do it), then one of these Linux distributions (the cool kids call them “distros”) probably has the tools you need.

BackTrack Linux is pretty commonly used among professional testers, because it contains most of the mainstream testing tools. It’s also based on Ubuntu Linux, which has a pretty good software package management system, called APT, which allows the tester to install additional software quickly, even when running from a bootable DVD.

Backtrack can be downloaded and used in several ways, and this presentation will discuss your options for obtaining and using BackTrack on your own system.

8

In the 50 minutes we’ll spend together today, you will probably not become an elite and world‐famous hacker. You will probably not master all there is to know about penetration testing methods and tools. You will not get a deep and abiding understanding of the tools or the standards we discuss today. You will, however, get enough information to help you get started on any of those journeys.

9

It is also my hope to better the penetration testing industry just a little bit today, by making all of you the kind of customer who seeks the very best testers. As consumers become more savvy, this will eventually help to weed out the “scan and print it” testers from the market. That will be a good thing for all of us. I encourage my clients to do automated testing on their own, as soon as they have the in‐house capability of doing it safely and effectively. This allows for more frequent testing and a better understanding of the results. You know the old saying, “Give a man a fish…”

10

This module will cover three sets of documents which will help you to understand the “how” and “why” of penetration testing.

11

Sometimes, being a good driver means keeping the car between the ditches on either side of the road. Today’s ditches to avoid have already been discussed: “scan and print” tests with absolutely no analysis or prioritization of findings, and “a magician never reveals his secrets” tests which have interesting findings, but no way for the client to reproduce them.

12

Each of these standards is covered in more detail on the subsequent slides.

13

The NIST 800 series of publications could be mentioned in nearly every presentation I prepare. Developed by the National Institute of Standards and Technology to provide advice and direction to federal agencies, the documents cover a wide range of security and assurance topics. The first URL in the list below is the index of all the documents in the series.

http://csrc.nist.gov/publications/PubsSPs.htmlhttp://csrc.nist.gov/publications/nistpubs/800‐37‐rev1/sp800‐37‐rev1‐final.pdfhttp://csrc.nist.gov/publications/nistpubs/800‐53A‐rev1/sp800‐53A‐rev1‐final.pdfhttp://csrc.nist.gov/publications/nistpubs/800‐115/SP800‐115.pdf

14

Still in beta, the PTES is the effort of twenty or so penetration testers and security professionals who got together at a security conference in late 2010 and began working on an execution standard with the goal of showing how a good test should be performed. It covers all interactions between the tester and the client, from initial meeting to exit. Even though it is still incomplete, and is geared towards testers, potential customers of penetration testers can learn a lot about what some pretty talented testers think should be done during an engagement.

http://www.pentest‐standard.org/index.php/Main_Pagehttps://workspaces.acrobat.com/app.html#d=U1W6FnTEY0J5‐aj3ZKDI2g

15

Sometimes reading as a cross between an academic thesis and a religious manifesto, the new version of OSSTMM takes a fresh look at how testing, and the associated reporting, should be performed. Pete Herzog, the lead author, has the idea that testing should be based on the exposure level of systems (called the “attack surface”) rather than risk. This can be a little painful and jarring for those of us who have cut our teeth on ISACA and other risk‐based standards, but it allows the tester and the organization tested to have a different perspective on the test and its results. OSSTMM concentrates on “defense in width,” or the Mobius defense, which concentrates on placing controls over interactions within the environment.

The OSSTMM is published by ISECOM (the Institute for Security and Open Methodologies).

http://www.isecom.org/research/osstmm.html

16

At the end of the 213‐page OSSTMM document is a section covering the Security Test Audit Report (STAR). It covers in some detail 17 areas that should be included in a test, and is the closest thing to an audit work program that you are going to get out of the manual. If you don’t read anything else, you might check out the STAR section of the OSSTMM, and look at the testing tools listed on the ISECOM research page.

http://www.isecom.org/research.html

17

18

None of these distributions will be covered in today’s presentation, but when you need something slightly more specialized in a specific area, they may be useful.

Live Hacking DVD: http://www.livehacking.com/BackBox Linux: http://www.backbox.org/NodeZero Linux: http://nodezero‐linux.org/

Samurai Web Testing Framework: http://sourceforge.net/projects/samurai/files/Developer site: http://samurai.inguardians.com/

WeakerThan: (lots of wireless tools) http://weaknetlabs.com/main/?page_id=479Matriux: (Focus on data forensics and data recovery tools) http://www.matriux.com/Deft v7.2: (Digital evidence and forensic toolkit ‐ Digital forensics) http://www.deftlinux.net/

19

We’re focusing on BackTrack today because it is a good general‐purpose distribution with a wide range of tools. The distributions on the previous slide may have some specialized tools you need for specific situations, but BackTrack is likely to have whatever you need first. It’s a good distro for learning because the tools are well‐organized and pretty easy to find, once you understand the categories.

We’ll cover the options for downloading and installing BackTrack on the next slide.

20

You can download BackTrack from their website at:

http://www.backtrack‐linux.org/downloads/

Don’t let the registration form fool you; you don’t have to register to download it.

21

The reference system for today’s demonstration was built using the options shown above. I really like to use the pre‐built virtual machines or install to a hard drive on a dedicated laptop when possible, because that allows me to permanently install new tools as I need them. With a bootable image, if I need a specialized tool which is not included, I would have to install it every time I boot the system.

22

The following slides have some screen shots of the things you’ll see when you boot BackTrack. By default, it boots into a text‐based console. You’ll probably want to do most of your early exploration of BackTrack in the X windows graphical environment, since the application menu makes it easy to explore what’s available to you.

23

24

25

The graphical theme used by BackTrack has the annoying feature (unless you’re a Mac user) of putting the windows maximize, minimize, and close buttons in the upper left corner, so I have highlighted them for you here.

26

All the testing tools included in BackTrack are somewhere under this menu. Many of the tools are command‐line only, which means when you select the tool in the menu, BackTrack will open a new terminal in the program’s default directory. For the demonstration today, all the tools will be opened in just this way.

27

If you intend to learn to use the tools included in BackTrack, you should probably start with the four listed on this slide. They cover some of the major functional areas, and will likely appear in the technical section of any penetration test report you receive.

28

29