Fixing CICS AEY9 ABEND: Transaction & Resource Security Key Check Failures
Quick Diagnostic Summary: What Causes Fixing CICS AEY9 ABEND: Transaction & Resource Security Key Check Failures?
CICS ABEND AEY9 occurs when a user or surrogate identity attempts to execute a transaction or access a protected CICS resource (file, program, TS queue) without required RACF, ACF2, or Top Secret authorization. Understand ESM class definitions and command security.
1 Incident Symptoms: What Triggers Fixing CICS AEY9 ABEND: Transaction & Resource Security Key Check Failures?
Users authenticate to CICS or call a CICS REST API through z/OS Connect and receive:
DFHAC2001 11:30:14 CICS01 TRANSACTION TX99 ABENDED AEY9 IN PROGRAM ORDR01.
SECURITY CHECK FAILURE FOR USER APPLUSER.
ICH408I USER(APPLUSER) GROUP(FINGRP) NAME(APP INTEGRATION)
CICS01.PAYROLL.MASTER CL(FCICSFMP)
INSUFFICIENT ACCESS AUTHORITY
FROM CICS01.PAYROLL.* (G)
ACCESS INTENT(UPDATE) ACCESS ALLOWED(READ)
The transaction halts, throwing HTTP 500 to modern web front-ends or kicking terminal operators out of the system.
2 Technical Root Cause & Architecture Mechanics
When CICS is configured with security enabled (SEC=YES in the System Initialization Table - SIT), CICS invokes the external security manager (IBM RACF, Broadcom ACF2, or Broadcom Top Secret) for:
1. Transaction Attachment Security (TCICSTRN): Does APPLUSER have READ authority to execute transaction TX99?
2. Resource Security Checking (RESSEC / XFCT / XPCT / XJCT): Does the transaction have permission to perform UPDATE or READ against the target VSAM file (FCICSFMP), temporary storage queue (JCICSJCT), or program (PCICSPCT)?
3. Surrogate Security: In web service or MQ triggered transactions, is the regional default user authorized to act as surrogate for the incoming authenticated user identity?
If the external security manager returns RC=08 (Not Authorized), CICS immediately terminates the task with ABEND AEY9.
3 Step-by-Step Diagnostic & Code Resolution
# 1. Identify the Exact RACF Class and Profile
Inspect the ICH408I console syslog message:
- User ID:
APPLUSER - Class:
FCICSFMP(CICS File Control) - Resource:
CICS01.PAYROLL.MASTER - Required Access:
UPDATE
# 2. Grant the Missing RACF Permissions
Have the security administrator issue RACF commands:
PERMIT CICS01.PAYROLL.MASTER CLASS(FCICSFMP) ID(FINGRP) ACCESS(UPDATE)
SETROPTS RACLIST(FCICSFMP) REFRESH
If using general grouping profiles, refresh the group class:
SETROPTS RACLIST(GCICSTRN) REFRESH
# 3. Handle Command Security in Application Code
If the application needs to gracefully handle permission denials without crashing with AEY9, use the NOHANDLE or RESP option in the CICS command:
EXEC CICS READ
FILE('PAYROLL-MASTER')
INTO(WS-PAYROLL-RECORD)
RIDFLD(WS-EMP-ID)
RESP(WS-RESP-CODE)
RESP2(WS-RESP2-CODE)
END-EXEC.
IF WS-RESP-CODE = DFHRESP(NOTAUTH)
MOVE 'Security Error: Unauthorized File Access'
TO WS-ERROR-MSG
PERFORM 9900-DISPLAY-AUTH-ERROR
END-IF.
Diagnostic Reference Matrix
| Attribute | Specification |
|---|---|
| Target Subsystem | IBM z/OS 2.4 - 3.1 • ABENDS & Diagnostics |
| Error Signature | CICS, AEY9, RACF |
| Resolution SLA | < 15 Minutes via Verified StackMF Runbook |
| Technical Reviewer | Anshu, Chief Technology Architect • StackMF Architecture Pod |
Architectural Prevention & Performance Tuning Checklist
- Always include `RESP(WS-RESP-CODE)` on all CICS file, queue, and link statements to intercept `NOTAUTH` gracefully.
- Maintain automated RACF profile auditing during Endevor/Git promotion pipelines to prevent untested security configurations from entering production.
- Verify surrogate user authorizations (`SURROGAT` class) when standing up z/OS Connect API providers.
- Periodically review CICS SIT parameters `CMDSEC=ALWAYS` and `RESSEC=ALWAYS` across regions.
? Frequently Asked Questions
What is the root cause of Fixing CICS AEY9 ABEND: Transaction & Resource Security Key Check Failures? ↓
How do you resolve Fixing CICS AEY9 ABEND: Transaction & Resource Security Key Check Failures in production? ↓
How can teams prevent Fixing CICS AEY9 ABEND: Transaction & Resource Security Key Check Failures in enterprise pipelines? ↓
Recommended Technical Runbooks
Resolving ABEND S0C7 (Data Exception) in COBOL Packed-Decimal (COMP-3) Fields
Debugging ABEND S0C4 (Protection Exception) in COBOL Linkage Section & Pointers
Mastering SB37, SD37, and SE37 Out-of-Space ABENDs in z/OS Sequential & PDS Datasets
Authoritative Reference Documentation
Official IBM manuals, Redbooks, and vendor technical advisories:
This diagnostic runbook is published by StackMF Technologies LLP for educational and architectural reference only. All code snippets, JCL, and procedures are provided "AS IS" without warranty of any kind. Always test changes thoroughly in non-production sysplex environments prior to production rollout.
IBM, z/OS, CICS, Db2, IMS, RACF, and IDz are registered trademarks of International Business Machines Corporation. Broadcom, CA-7, and Endevor are trademarks of Broadcom Inc. All other trademarks belong to their respective owners and are referenced under the Nominative Fair Use Doctrine (US Lanham Act 15 U.S.C. ยง 1125 / Section 30 of the Indian Trade Marks Act, 1999) solely for technology compatibility and diagnostic identification. StackMF Technologies LLP is an independent consulting entity not affiliated with or endorsed by these vendors. View Full Legal & IP Policy →
Struggling with Critical Mainframe Incidents or Vendor Renewal Pressure?
StackMF deploys certified Senior Mainframe Engineers fluent in both z/OS legacy internals (COBOL, DB2, CICS, VSAM, CA-7, Endevor) and modern cloud stacks (React, Kafka, AWS, Git). Onboard dedicated pods in 48 hours or cut Broadcom licensing by 60%.