Error Reference

Security constraint violation: operation not permitted

Security constraint violation: operation not permitted

Where this appears

This error appears in the ServiceNow application log, browser developer console, or system diagnostics when server-side security mechanisms block an attempted operation. It typically occurs during record queries, form submissions, or script executions that violate Access Control Lists (ACLs), System Security constraints, or before-query business rule restrictions.

Sourdough
Chrome Extension

Debugging this in a real instance?

Sourdough lets you trace "Security constraint violation: operation not permitted" through system logs, script errors, and API health in the ServiceNow tab you are already using.

Add to Chrome

Free to install. Pro $5/month after a 14-day no-card trial.
Pro requires the ServiceNow admin role. Upgrade inside the extension.

Overview
Tasks
CMDB
API
Metrics
Monitor
Internals
Instance:sourdoughdev·Version:Yokohama
Instance StateONLINE
System StatusFully Operational
Session Timeout90 minutes
Logged-In Sessions2 (20 active)
Build Nameyokohama-12-18-2024_p1
IP Address10.159.128.43
Instance HealthHealth Score: 90%
🔥 5dSourdough (Chrome Plugin)Dark Mode

Cause

Access Control List (ACL) on a table or field is denying read, write, create, or delete permissions for the current user's role. (high likelihood)

Before-query business rule is actively blocking the operation by setting current.setAbortAction(true) or throwing an exception. (high likelihood)

System Security policies in System Security > High Security Settings are restricting access to sensitive tables or operations. (medium likelihood)

Cross-scope access violation where a scoped application is attempting to access records or APIs outside its permitted scope without proper application cross-scope access. (medium likelihood)

Elevated privilege context has expired or been revoked during a long-running script execution, causing subsequent operations to fail security checks. (low likelihood)

Fix

Step 1: Check the System Log at System Diagnostics > Log > Application Log for detailed error messages that identify the specific table, field, or operation being blocked.

Step 2: Navigate to System Security > Access Control (ACL) and search for ACLs related to the table and operation mentioned in the error to verify if the current user's role has appropriate permissions.

Step 3: Review before-query business rules on the affected table by going to System Definition > Business Rules and filtering by the table name and 'before query' timing.

Step 4: If the operation involves cross-scope access, verify Application Cross-Scope Access records at System Applications > Application Cross-Scope Access to ensure proper permissions are configured.

Step 5: Check System Security > High Security Settings for any policies that might be restricting access to the table or operation in question.

Step 6: Test the operation while impersonating a user with admin privileges to confirm whether the issue is role-based or systemic.

Step 7: If the error occurs in a scoped application, review the application's access requirements and update the application scope or create necessary ACL entries.

Step 8: For persistent issues, enable ACL debugging by setting the system property glide.security.acl.debug to true and reproduce the error to get detailed ACL evaluation logs.

Test Your Knowledge

Quick 3-question quiz. See how your ServiceNow skills stack up.

Question 1 of 3Performance

A list view on a table with millions of records is slow. Best fix?

Select an answer to continue