// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
//
-#if NET_2_0
-
using System.Security.Principal;
namespace System.Security.AccessControl {
{
AuditFlags auditFlags;
- protected AuditRule ()
- {
- /* Give it a 0-param constructor */
- }
-
protected AuditRule (IdentityReference identity,
int accessMask,
bool isInherited,
: base (identity, accessMask, isInherited,
inheritanceFlags, propagationFlags)
{
- if (!(identity is SecurityIdentifier)) {
- /* FIXME: check auditFlags too */
- throw new ArgumentException ("identity");
- }
-
- if (accessMask == 0) {
- /* FIXME: check inheritance and
- * propagation flags too
- */
- throw new ArgumentOutOfRangeException ();
- }
+ if (auditFlags != ((AuditFlags.Success | AuditFlags.Failure) & auditFlags))
+ throw new ArgumentException ("Invalid audit flags.", "auditFlags");
this.auditFlags = auditFlags;
}
}
}
}
-
-#endif