encryption bugfix