SCYEXIT (Security Exit)

IBM MQ ships with strong built-in controls: TLS on the wire, CHLAUTH rules that map certificates and IP addresses to MCAUSER, and CONNAUTH that validates passwords against LDAP or the operating system. Some enterprises still need SCYEXIT—the channel attribute that points at a custom security exit program loaded from the exits directory. Security exits run at defined points in channel processing so your organization can enforce policy that IBM generic rules cannot express: proprietary credential formats, integration with a mainframe security product, correlation with an external risk engine, or adoption of a service account only after multi-factor approval in another system. Beginners should treat SCYEXIT as optional and advanced; turning it on without a tested exit binary is a common cause of channels that never reach RUNNING. This tutorial explains the SCYEXIT string format, how exits interact with MCAUSER and CHLAUTH, deployment on distributed and z/OS, operational risks, and how SCYEXIT differs from message exits and from TLS.

Security Exits in the Channel Lifecycle

When a channel instance starts—whether SDR dialing out or RCVR accepting inbound—the queue manager loads channel exits according to attributes on the definition. SCYEXIT supplies the name of the security exit and optional user data passed to the exit entry point. The exit receives control in a documented API (language and structure vary by platform; IBM publishes exit programming interfaces in the product documentation). The exit can allow or veto progression, modify security context, or write to diagnostic facilities. Because exits execute inside the channel agent address space, a buggy exit can crash the channel or leak sensitive data to logs. Change control for exit DLLs or load modules should be as strict as for queue manager binaries.

Channel exit attributes compared
AttributeRoleTypical beginner need
SCYEXITSecurity policy and identityRare; use CHLAUTH first
RCVEXITTransform or inspect inbound dataRare; vendor integrations
SENDEXITTransform or inspect outbound dataRare; compression or audit
MCAUSERStatic default user for channelVery common

SCYEXIT String Format

On distributed systems SCYEXIT often appears as exitName(exitData) where exitName identifies the module in the exits path and exitData is an optional string passed to the exit for configuration (partner ID, policy version, etc.). z/OS may use load module names and parameter data appropriate to the platform. DISPLAY CHANNEL(name) SCYEXIT shows the current value. ALTER CHANNEL(name) SCYEXIT(...) updates the repository; restart channel instances to pick up changes. Empty SCYEXIT means no security exit—normal for most channels.

shell
1
2
3
4
5
6
* Example pattern only—replace with your vendor exit name and data DEFINE CHANNEL('PARTNER.SECURE') CHLTYPE(RCVR) TRPTYPE(TCP) + MCAUSER('mqpartner') SCYEXIT('myScyExit(POLICY=STRICT)') ALTER CHANNEL('PARTNER.SECURE') SCYEXIT('myScyExit(POLICY=STRICT)') DISPLAY CHANNEL('PARTNER.SECURE') SCYEXIT MCAUSER * After change: STOP CHANNEL then START or let partner reconnect

The example is illustrative. Your site must supply a real exit compiled for your MQ version and platform. IBM and third parties ship sample exits; production use requires support agreements and regression testing on every MQ fix pack upgrade.

Relationship to MCAUSER and CHLAUTH

MCAUSER on the channel sets the default user ID for puts and gets under that channel unless CHLAUTH or an exit changes it. CHLAUTH ADDRESSMAP and SSLPEERMAP rules run in the modern rule engine and do not require custom code. SCYEXIT can complement CHLAUTH—for example, call an external system after CHLAUTH maps a certificate to a user—or override behavior in legacy estates. Order of processing matters and is release-specific; document the effective identity path on a whiteboard before enabling both SSLPEERMAP and SCYEXIT on the same SVRCONN. If the exit sets a different user than administrators expect, 2035 Not authorized on queues appears even when TLS succeeded.

When Organizations Use SCYEXIT

  • Regulated industries with mandatory custom authentication hooks audited separately from IBM code.
  • Migration from older products that relied on exits before CHLAUTH existed.
  • Vendor appliances (MQIPT extensions, gateway products) that register exits as part of their package.
  • Cross-platform identity federation that is not yet modeled in LDAP CONNAUTH.

Greenfield IBM MQ 9.x designs should implement CHLAUTH deny-by-default, TLS 1.2+, and CONNAUTH before considering SCYEXIT. Exits add operational burden: 64-bit vs 32-bit libraries, path permissions, signature verification, and coordination with security scanners.

Deployment and Platform Notes

Exit programs live in the exits directory configured for the queue manager (often something like /var/mqm/exits on Linux, with parallel concepts on Windows and z/OS STEPLIB). The queue manager process must have execute permission. Mixed-endian or wrong MQ version builds cause abends. On z/OS, exits may be linked into libraries known to the channel initiator. After MQ upgrade, recompile or obtain updated exit levels from the vendor—exits are not always forward-compatible without rebuild. Keep a non-production queue manager mirroring production exit configuration for soak tests.

Explainer: Extra Bouncer at the Door

CHLAUTH and TLS are the standard ID check and metal detector at the venue. SCYEXIT is hiring your own bouncer who can ask custom questions IBM did not program—like calling HR to verify a contractor badge. If the bouncer computer crashes, nobody enters, even with a valid ticket.

Monitoring and Troubleshooting

  1. Channel STOPPED or BINDING failure immediately after enabling SCYEXIT—check exit path and module bitness.
  2. Search AMQERR and channel diagnostic logs for exit return codes.
  3. DISPLAY CHANNEL SCYEXIT—confirm typo in exit name or unbalanced parentheses in exit data.
  4. Temporarily remove SCYEXIT in lab to isolate exit vs network issues (never as a permanent production fix).
  5. Verify exit vendor supports your exact MQ maintenance level.

Explain Like I'm Five: SCYEXIT

SCYEXIT is a special helper program MQ calls to double-check if someone is allowed to use the channel, like an extra teacher checking your hall pass besides the normal rules.

Practice Exercises

Exercise 1

Draw a flowchart: TLS handshake, CHLAUTH SSLPEERMAP, MCAUSER, then SCYEXIT—where could 2035 appear?

Exercise 2

List five items for an MQ upgrade checklist when SCYEXIT is enabled on fifty channels.

Exercise 3

Explain to a manager why CHLAUTH alone might be enough without a custom security exit.

Frequently Asked Questions

Frequently Asked Questions

Test Your Knowledge

Test Your Knowledge

1. SCYEXIT is primarily for:

  • Custom security policy
  • Message compression only
  • Queue MAXDEPTH
  • Topic strings

2. SCYEXIT vs SSLCIPH:

  • Exit vs cipher suite
  • Same thing
  • Both set queue depth
  • Both are DLQ

3. Before enabling SCYEXIT in production you should:

  • Test in lab with logging
  • Skip documentation
  • Remove CHLAUTH
  • Disable listeners

4. A failed security exit usually:

  • Stops the channel
  • Increases MAXMSGL
  • Creates a topic
  • Renames the QMGR
Published
Read time17 min
AuthorMainframeMaster
Verified: IBM MQ 9.3 documentation