[Solved] Why does my crypt package give me invalid magic prefix error?

Why does this happen and how do I resolve it? You have an invalid magic prefix. github.com/tredoe/osutil/user/crypt/sha512_crypt/sha512_crypt.go if !bytes.HasPrefix(salt, c.Salt.MagicPrefix) { return “”, common.ErrSaltPrefix } Read the crypt package code. PHP: crypt — One-way string hashing PHP: password_hash — Creates a password hash Read the PHP documentation. See your earlier question: golang equivalent of PHP … Read more