Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.


n/nDescriptionInputsExpected ResultStep by Step ScriptActual Result
WS: BlockUser, UnblockUser


2FA_user_BU1Block user (happy pass)
  • WS = BlockUser()
  • Authorization - Mithril Admin

Response 200

Update user in DB (is_blocked, block_reason).

  • Login as Mithril Admin
  • Call BlockUser()
OK
2FA_user_BU2Block user (bad user_id)
  • WS = BlockUser()
  • Authorization - Mithril Admin
  • Corrupted user_id

Response 404


  • Login as Mithril Admin
  • Call BlockUser()

OK

2FA_user_BU3Block user (without scope )
  • WS = BlockUser()
  • Authorization - NHS Admin

Response 403


  • Login as NHS Admin
  • Call BlockUser()
OK
2FA_user_BU4UnBlock user (happy pass)
  • WS = UnBlockUser()
  • Authorization - Mithril Admin

Response 200

Update user in DB (is_blocked).

  • Login as Mithril Admin
  • Call UnBlockUser()
OK
2FA_user_BU5UnBlock user (bad user_id)
  • WS = UnBlockUser()
  • Authorization - Mithril Admin
  • Corrupted user_id

Response 404


  • Login as Mithril Admin
  • Call UnBlockUser()

OK

2FA_user_BU6UnBlock user (without scope )
  • WS = UnBlockUser()
  • Authorization - NHS Admin

Response 403


  • Login as NHS Admin
  • Call UnBlockUser()
OK
WS: Create2FA


2FA_create_FA1Create FA item (happy pass)
  • WS = Create2FA()
  • DELETE 2FA item with type `SMS`
  • Authorization - Mithril Admin

Response 201

Create 2FA item in DB

  • Login as Mithril Admin
  • Check not-exist 2FA item for user
  • Call Create2FA()
OK
2FA_create_FA2Create FA item (try create duplicate with type)
  • WS = BlockUser()
  • DELETE 2FA item with type `SMS`
  • Authorization - Mithril Admin
Response 422
  • Login as Mithril Admin
  • Check exist 2FA item for user with type SMS
  • Call Create2FA()
OK
2FA_create_FA3Create FA item (with bad type
  • WS = BlockUser()
  • Use Corrupted type `ID_ID`
  • Authorization - Mithril Admin
Response 422
  • Login as Mithril Admin
  • Call Create2FA()
Bug
2FA_create_FA4Create FA item (with factor value)
  • WS = BlockUser()
  • Use factor in payload
  • DELETE 2FA item with type `SMS`
  • Authorization - Mithril Admin
Response 422
  • Login as Mithril Admin
  • Check not-exist 2FA item for user with type SMS
  • Call Create2FA()
Bug
2FA_create_FA5Create FA item (without scope)
  • WS = BlockUser()
  • Use factor in payload
  • DELETE 2FA item with type `SMS`
  • Authorization - NHS Admin
Response 403
  • Login as NHS Admin
  • Call Create2FA()
OK
WS: Get2FAList, Get2FAbyID


2FA_get_FA1Get 2FA list (happy pass)
  • WS = Get2FAList()
  • Authorization - Mithril Admin
Response 200
  • Login as Mithril Admin
  • Call Get2FAList()
OK
2FA_get_FA2Get 2FA list (with type filter)
  • WS = Get2FAList() with type `EMAIL`
  • Authorization - Mithril Admin
Response 200, rows=0
  • Login as Mithril Admin
  • Call Get2FAList() with type `EMAIL`
OK
2FA_get_FA3Get 2FA by ID (happy pass)
  • WS = Get2FAbyID() 
  • Authorization - Mithril Admin
Response 200, rows=1
  • Login as Mithril Admin
  • Call Get2FAbyID()
OK
2FA_get_FA4Get 2FA list (without scope)
  • WS = Get2FAList()
  • Authorization - authentication_factor:read
Response 403
  • Login as NHS Admin
  • Call Get2FAList()
Bug
WS: DisableUser2FA, EnableUser2FA, ResetUser2FA


2FA_DER_FA1DisableUser2FA (happy pass)
  • WS = DisableUser2FA()
  • Authorization - Mithril Admin

Response 200

Update 2FA item in DB

  • Login as Mithril Admin
  • Call DisableUser2FA()
OK
2FA_DER_FA2EnableUser2FA (happy pass)
  • WS = EnableUser2FA()
  • Authorization - Mithril Admin

Response 200

Update 2FA item in DB

  • Login as Mithril Admin
  • Call EnableUser2FA()
OK
2FA_DER_FA3DisableUser2FA (bad ID)
  • WS = DisableUser2FA()
  • Authorization - Mithril Admin
  • Corrupted 2fa_id
Response 404
  • Login as Mithril Admin
  • Call DisableUser2FA()
OK
2FA_DER_FA4EnableUser2FA (bad ID)
  • WS = EnableUser2FA()
  • Authorization - Mithril Admin
  • Corrupted 2fa_id
Response 404
  • Login as Mithril Admin
  • Call EnableUser2FA()
OK
2FA_DER_FA5ResetUser2FA (happy pass)
  • WS = ResetUser2FA()
  • Authorization - Mithril Admin
  • Corrupted 2fa_id

Response 200

Update 2FA item in DB

  • Login as Mithril Admin
  • Call ResetUser2FA()
Bug
WS: CreateUser


2FA_create_U1Create user (2FA deafult)
  • WS = CreateUser()
  • DELETE user with test email 
  • Authorization - Mithril Admin

Response 201

Create User  in DB

Create 2FA item in DB 

  • Login as Mithril Admin
  • Check not-exist user
  • Call CreateUser() without "2fa_enable" attribute
Bug
2FA_create_U2Create user (2FA enable)
  • WS = CreateUser()
  • DELETE user with test email 
  • Authorization - Mithril Admin

Response 201

Create User  in DB

Create 2FA item in DB 

  • Login as Mithril Admin
  • Check not-exist user
  • Call CreateUser() with "2fa_enable" = true 
OK
2FA_create_U3Create user (2FA disable)
  • WS = CreateUser()
  • DELETE user with test email 
  • Authorization - Mithril Admin

Response 201

Create User  in DB

Create 2FA item in DB 

  • Login as Mithril Admin
  • Check not-exist user
  • Call CreateUser() with "2fa_enable" = false
OK
WS: CreateToken


2FA_create_T1Create Token (2FA Reset)
  • WS = CreateToken()
  • Check 2FA exist, enable, factor = null 
  • Authorization - Mithril Admintest user of MSP

Response 201

Response.urgent.next_step = REQUEST_FACTOR

 

  • Login as test_2fa_user
  • Check 2FA state
  • Call CreateToken() with grant_type=password
Ok
2FA_create_T2Create Token (2FA Active)
  • WS = CreateToken()
  • Check 2FA exist, enable, factor exist 
  • Authorization - Mithril Admin test user of MSP

Response 201

Response.urgent.next_step = AUTHORIZE_OTP

Create OTP item 

  • Login as test_2fa_user
  • Check 2FA state
  • Call CreateToken() with grant_type=password
Bug - 500
2FA_create_T2Authorize OTP (2FA Active)
  • WS = CreateToken()
  • Check 2FA exist
  • Exist OTP
  • Authorization - test user of MSP

Response 201

Update OTP item 

  • Login as test_2fa_user
  • Check 2FA state
  • Call CreateToken() with grant_type=password
Bug - 500