| George Keishing | 74751f7 | 2018-10-09 13:46:27 -0500 | [diff] [blame] | 1 | *** Settings *** | 
|  | 2 | Documentation   OEM IPMI in-band BMC authentication reset. | 
|  | 3 |  | 
|  | 4 | # This resets the BMC authentication: | 
|  | 5 | # - Enable local users if they were disabled. | 
|  | 6 | # - Delete the LDAP configuration if there was one. | 
|  | 7 | # - Reset the root password back to the default one. | 
|  | 8 |  | 
|  | 9 | Resource        ../lib/resource.txt | 
|  | 10 | Resource        ../lib/ipmi_client.robot | 
|  | 11 | Resource        ../lib/boot_utils.robot | 
|  | 12 | Library         ../lib/ipmi_utils.py | 
|  | 13 |  | 
|  | 14 | Test Teardown   FFDC On Test Case Fail | 
|  | 15 |  | 
|  | 16 | *** Test Cases *** | 
|  | 17 |  | 
|  | 18 | Test Inband IPMI Auth Reset | 
|  | 19 | [Documentation]  Trigger in-band BMC authentication reset and verify. | 
|  | 20 | [Tags]  Test_Inband_IPMI_Auth_Reset | 
|  | 21 |  | 
|  | 22 | Create Session  openbmc  ${AUTH_URI}  max_retries=1 | 
|  | 23 | ${headers}=  Create Dictionary  Content-Type=application/json | 
|  | 24 | @{credentials}=  Create List  ${OPENBMC_USERNAME}  ${OPENBMC_PASSWORD} | 
|  | 25 | ${data}=  create dictionary   data=@{credentials} | 
|  | 26 | ${resp}=  Post Request  openbmc  /login  data=${data}  headers=${headers} | 
|  | 27 | Should Be Equal As Strings  ${resp.status_code}  ${HTTP_UNAUTHORIZED} | 
|  | 28 |  | 
|  | 29 | # Call reset method. | 
|  | 30 | Run Inband IPMI Raw Command  0x3a 0x11 | 
|  | 31 |  | 
|  | 32 | Initialize OpenBMC |