private void CheckAccess() { if (!PrincipalInfo.HasEditAccess) { throw new SecurityException("Access denied"); } }