security implemented with error messages