UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = 'J2jMTiiO5Elz3Ex741y9gilHKON08bOlAjl4pBnm0cg=' 
WHERE 
  key_id = '113bcdf19ddc42c9f77c044c99d5be553449c4d4e4c3d6d5687bb4da67a84644' 
  AND (
    token = 'J2jMTiiO5Elz3Ex741y9gilHKON08bOlAjl4pBnm0cg=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00029