George Keishing | 6cd44cb | 2020-08-18 14:38:50 -0500 | [diff] [blame] | 1 | *** Settings *** |
| 2 | Documentation Test bmc web vulnerability. |
| 3 | |
| 4 | Resource ../lib/resource.robot |
| 5 | Resource ../lib/bmc_redfish_resource.robot |
| 6 | Resource ../lib/openbmc_ffdc.robot |
| 7 | |
| 8 | Test Setup Test Setup Execution |
| 9 | Test Teardown FFDC On Test Case Fail |
| 10 | |
George Keishing | 87dc442 | 2023-10-20 12:56:30 +0530 | [diff] [blame^] | 11 | Force Tags BMCweb_Security |
| 12 | |
George Keishing | 6cd44cb | 2020-08-18 14:38:50 -0500 | [diff] [blame] | 13 | *** Variables *** |
| 14 | |
| 15 | ${LOOP_COUNT} 4 |
| 16 | |
| 17 | *** Test Cases *** |
| 18 | |
| 19 | Check BMCWeb Service After Attempted GET With Invalid URL |
| 20 | [Documentation] Request BMC GET with invalid URL. |
| 21 | [Tags] Check_BMCWeb_Service_After_Attempted_GET_With_Invalid_URL |
| 22 | |
Matt Fischer | 46bd8c2 | 2023-09-01 11:00:26 -0600 | [diff] [blame] | 23 | ${invalid_url}= Set Variable https://${OPENBMC_HOST}:${HTTPS_PORT}/'redfish\\[' |
George Keishing | 6cd44cb | 2020-08-18 14:38:50 -0500 | [diff] [blame] | 24 | |
| 25 | # Exhaust bmcweb restart policy by crashing 4 times in succession. |
| 26 | Repeat Keyword ${LOOP_COUNT} times Run ${curl_tool} -k ${invalid_url} |
| 27 | |
| 28 | # This should fail, if bmcweb is crashed. |
| 29 | Redfish.Login |
| 30 | |
| 31 | *** Keywords *** |
| 32 | |
| 33 | Test Setup Execution |
| 34 | [Documentation] Do test setup execution. |
| 35 | |
| 36 | ${cmd_tool}= Run which curl |
| 37 | Should Contain ${cmd_tool} curl |
| 38 | Set Test Variable ${curl_tool} ${cmd_tool} |