docs: def set_user_password(self, uid, mode='set_password', password=None):
          """Set user password and (modes)
  
          :param uid: id number of user.  see: get_names_uid()['name']
  
          :param mode:
              disable       = disable user connections
              enable        = enable user connections
              set_password  = set or ensure password
              test_password = test password is correct
  
          :param password: max 16 char string
              (optional when mode is [disable or enable])
  
          :return:
              True on success
              when mode = test_password, return False on bad password
          """
          mode_mask = {
              'disable': 0,
              'enable': 1,
              'set_password': 2,
              'test_password': 3
          }
          data = [uid, mode_mask[mode]]
          if password:
              password = str(password)
              if 21 > len(password) > 16:
                  password = password.ljust(20, b'\x00')
                  data[0] |= 0b10000000
              elif len(password) > 20:
                  raise Exception('password has limit of 20 chars')
              else:
                  password = password.ljust(16, "\x00")
              data.extend([ord(x) for x in password])
          try:
              self.xraw_command(netfn=0x06, command=0x47, data=data)
          except exc.IpmiException as ie:
              if mode == 'test_password':
                  return False
              elif mode in ('enable', 'disable') and ie.ipmicode == 0xcc:
                  # Some BMCs see redundant calls to password disable/enable
                  # as invalid
                  return True
              raise
          return True