def _split_password(password):
    """
    Split the password hash into it's components.
    Returns a tuple of the hashtype, number of repetitions and salt.
    """
    sp = password[1:].split('$')
    hashtype = sp[0]
    n = int(sp[1])
    salt = sp[2]
    return hashtype, n, salt