crypto: Check for callback before assignment

These callbacks are a one time thing, so if another library has already done this, this will throw an error.