Fixing some security issues 2