gauntlt/gauntlt

View on GitHub
examples/nmap/simple-env-var.attack

Summary

Maintainability
Test Coverage
@slow
Feature: simple nmap attack (sanity check)

  Background:
    Given "nmap" is installed

    And the following environment variables:
      | name      | environment_variable_name |
      | hostname  | TEST_HOSTNAME             |

    And the following profile:
      | name     | value |
      | https_port | 443 |
      | http_port  | 80  |

  Scenario: Verify server is available on standard web ports
    When I launch an "nmap" attack with:
      """
      nmap -p <http_port>,<https_port> <hostname>
      """
    Then the output should match /80.tcp\s+open/      
    And the output should not match:
      """
      443/tcp\s+open 
      """