fixed crypto stuff