• Identifying New Vulnerabilities | 143
  • Identifying New Vulnerabilities




    Download 22,59 Mb.
    Pdf ko'rish
    bet136/225
    Sana14.05.2024
    Hajmi22,59 Mb.
    #232856
    1   ...   132   133   134   135   136   137   138   139   ...   225
    Bog'liq
    learningkalilinux

    Identifying New Vulnerabilities
    Software has bugs. It’s the nature of the beast. Software, especially larger pieces of
    software, is complex. The more complexity, the more chance for error. Think about
    all of the choices that are made in the course of running a program. If you start calcu‐
    lating all the potential execution paths through a program, you will quickly get into
    large numbers. How many of those complete execution paths get tested when soft‐
    ware testing is performed? Chances are, only a subset of the entire set of execution
    paths. Even if all the execution paths are being tested, what sorts of input are being
    tested?
    Some software testing may be focused on 
    functional testing
    . This is about verifying
    that the functionality specified is correct. This may be done by positive testing—mak‐
    ing sure that what happens is expected to happen. There may also be some amount of
    negative testing. You want to make sure that your program fails politely if something
    unexpected happens. It’s this negative testing that can be difficult to accomplish,
    because if you have a set of data you expect, it’s only a partial set compared with
    everything that could possibly happen in the course of running a program, especially
    one that takes user input at some point.
    Identifying New Vulnerabilities | 143


    Boundary testing
    occurs when you go after the bounds of expected input. You test the
    edges of the maximum or minimum values, and just outside the maximum or mini‐
    mum—checking for errors and correct handling of the input.
    Sending applications data they don’t expect is a way to identify bugs in a program.
    You may get error messages that provide information that may be useful, or you may
    get a program crash. One way of accomplishing this is to use a class of applications
    called 
    fuzzers
    . A fuzzer generates random or variable data to provide to an applica‐
    tion. The input is programmatically generated based on a set of rules.
    Fuzzing may be considered black-box testing by some people,
    because the fuzzing program has no knowledge of the inner work‐
    ings of the service application. It sends in data, regardless of what
    the program is expecting the input to look like. Black-box testing is
    about viewing the software under test as a black box—the inner
    workings can’t be seen. Even if you have access to the source code,
    you are not developing the tests you run with a fuzzer with respect
    to the way the source code looks. From that standpoint, the appli‐
    cation may as well be a black box, even if you have the source code.
    Kali has a few fuzzers installed and more that can be installed. The first one to look at,
    sfuzz
    , used to send network traffic to servers. 
    sfuzz
    has a collection of rules files that
    tells the program how to create the data that is being sent. Some of these are based on
    Download 22,59 Mb.
    1   ...   132   133   134   135   136   137   138   139   ...   225




    Download 22,59 Mb.
    Pdf ko'rish