Package splunk

Class TestSplunkOutput

java.lang.Object
splunk.TestSplunkOutput

public class TestSplunkOutput
extends java.lang.Object
Tests the outputs produced for Splunk, using whatever data is pre-existing in the database
  • Field Summary

    Fields 
    Modifier and Type Field Description
    static java.lang.String OUTPUT_DIR
    The directory to output to
  • Constructor Summary

    Constructors 
    Constructor Description
    TestSplunkOutput​(ScanResponse scanResponse, ScanHost host, ScanHostResponse response, java.util.List<Vulnerability> vulns)
    Instantiates a new Test splunk output using the provided responses, host, and vulnerabilities
  • Method Summary

    Modifier and Type Method Description
    static java.util.Collection getTestParams()
    Obtains the test params from the database's existing data
    void run()
    Runs the test, producing a HostOutput record.
    static void write()
    Writes all JsonNodes produced by all the tests to a file

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

  • Constructor Details

    • TestSplunkOutput

      public TestSplunkOutput​(ScanResponse scanResponse, ScanHost host, ScanHostResponse response, java.util.List<Vulnerability> vulns)
      Instantiates a new Test splunk output using the provided responses, host, and vulnerabilities
      Parameters:
      scanResponse - the scan response
      host - the host
      response - the response
      vulns - the vulns
  • Method Details

    • getTestParams

      public static java.util.Collection getTestParams()
      Obtains the test params from the database's existing data
      Returns:
      the test params
    • run

      public void run()
      Runs the test, producing a HostOutput record. The record is serialized into a JsonNode which is saved for writing to a file at the very end of all tests
    • write

      public static void write()
      Writes all JsonNodes produced by all the tests to a file