code: def get_salt(cls, hashed_passord):
          
          scheme = cls.get_scheme(hashed_passord)
          cls._test_scheme(scheme)
          if scheme in cls.schemes_nosalt:
              return b""
          elif scheme == b'{CRYPT}':
              return b'$'.join(hashed_passord.split(b'$', 3)[:-1])[len(scheme):]
          else:
              try:
                  hashed_passord = base64.b64decode(hashed_passord[len(scheme):])
              except (TypeError, binascii.Error) as error:
                  raise cls.BadHash("Bad base64: %s" % error)
              if len(hashed_passord) < cls._schemes_to_len[scheme]:
                  raise cls.BadHash("Hash too short for the scheme %s" % scheme)
              return hashed_passord[cls._schemes_to_len[scheme]:]
docs: Return the salt of ``hashed_passord`` possibly empty
  
              :param bytes hashed_passord: A hashed password
              :return: The salt used by the hashed password (empty if no salt is used)
              :rtype: bytes
              :raises BadHash: if no valid scheme is found within ``hashed_passord`` or if the
                  hashed password is too short for the scheme found.