SAP transaction codeObjectSU21ModuleSECURITY_GRC

SU21 — Maintain Authorization Objects and Object Classes

SU21 is where custom authorization objects are created and maintained: object classes, the object itself, and the up to ten fields that make it up. Creating an object here has no runtime effect by itself. It only defines the shape of a check. Something has to call AUTHORITY-CHECK against it, and it needs an SU24 assignment before PFCG will propose it automatically.

This page covers SU21, the transaction used to define custom authorization objects and object classes for use in AUTHORITY-CHECK statements. It focuses on the gap between defining an object and it actually doing anything, and on the transport and linkage failures that make custom authorization objects appear broken when the object definition itself is fine.

Reviewed by an ERPClimb SAP consultant on 15 Sept 2026· 1,276 words

Esta página ainda não está disponível em português.

Purpose

SU21 maintains the authorization object catalog: object classes (functional groupings like HR, FI, Basis, or a custom class), the authorization objects within each class, and the field list attached to each object. An object can have up to ten fields, typically an activity field (ACTVT) plus one or more business fields such as company code, document type, or a custom key. The structural fact that causes most confusion is that SU21 only defines shape, not behavior. Nothing checks anything just because an object exists here. A developer still has to code an AUTHORITY-CHECK OBJECT statement referencing the object and its fields, and someone still has to link the object to the relevant transaction or service in SU24 so that PFCG proposes it when a role is built. Skip either step and the object sits in the catalog doing nothing.

When it is used

SU21 gets used during custom development work, not during day-to-day role administration. It is reached for when a custom transaction, custom RFC-enabled function module, custom BAdI implementation, or a custom Fiori OData service needs a security check that no standard SAP object covers with enough granularity. The typical trigger is a functional requirement like 'restrict this custom report by plant and document type' where no delivered object carries both fields together. It is also used, less often, to extend an SAP-delivered object class with a Y or Z copy when the delivered object is close but not flexible enough and cannot be modified directly. It is not the tool for assigning objects to roles, maintaining default values, or troubleshooting a specific user's missing authorization; those live in PFCG, SU24, and SU53/SU56 respectively.

How to use it in practice

  • Open SU21 and pick the object class the new object belongs to, or create a new class first if none fits
  • Create the authorization object using a name in the customer namespace (Y or Z), up to ten characters, with a short and long text
  • Add fields to the object, one field per authorization dimension, commonly starting with ACTVT for activity, each field referencing a data element for its value help
  • Save the object under a transport request and release it through the landscape before it is used in any downstream system
  • Hand the object name and field list to the developer, who codes the AUTHORITY-CHECK OBJECT statement in the relevant program, class, or service implementation
  • Maintain the object in SU24 against the transaction or service so PFCG proposes it with default values when the transaction is added to a role

Key data objects

  • TOBJ - the authorization object header: object name, object class, short text, and the ordered list of fields attached to it
  • TOBC - the catalog of authorization object classes that objects are grouped under
  • TACT - the activity catalog, holding the numeric activity values (create, change, display, and so on) available to the ACTVT field
  • Table entries for SU24 check assignments (the transaction-to-object proposal tables) are written separately in SU24, not in SU21, but they are the next place the object needs to appear to be usable in role maintenance

How to prove it in the data

To confirm whether a custom object actually exists and is transported correctly, run SE16 on TOBJ filtered by the object name and compare the field list on screen against what SU21 shows in the target system; a mismatch between systems usually means an incomplete or stuck transport. To confirm the object is wired into role proposal, check the SU24 check indicator tables (commonly referred to as USOBT_C and USOBX_C for the customer versions) filtered by the transaction code, and confirm the object name appears with a check or check/maintain indicator rather than being absent or set to 'no check'.

ECC vs S/4HANA

SU21 is unchanged on S/4HANA; it remains a transaction-based tool with no Fiori equivalent, and custom authorization object creation still works exactly the same way. What has changed is where objects get consumed: custom Fiori apps built on OData services or custom CDS-based analytics still rely on objects defined in SU21, checked either in the service implementation class or via CDS-based access control, so the object creation step has not disappeared even where the consuming interface is now a Fiori app rather than a classic transaction.

Common pitfalls and how to diagnose them

  • Object exists but does nothing: the object is visible in SU21 and looks correct, but no program contains an AUTHORITY-CHECK against it. Confirm with the developer or a code search before assuming the object is broken; SU21 has no way to show whether the object is actually referenced anywhere.
  • Field limit and design mistakes: an object is capped at ten fields, and adding an eleventh forces a redesign, usually splitting into two objects or dropping a field that duplicates information already covered elsewhere. Discovering this mid-build after fields are already assigned to other design artifacts causes rework, so field count should be checked early.
  • Namespace and modification errors: attempting to add a field to an SAP-delivered object fails or is blocked, because delivered objects in the SAP namespace cannot be modified directly. The fix is a Y or Z copy with the extra field, referenced by the custom code, not a change to the original.
  • Transport gaps: the object is created and works in development but is missing or incomplete in QA or production because the transport was never released or was released out of sequence with the code that checks it. Symptom is an AUTHORITY-CHECK failing or behaving inconsistently across systems; the fix is to verify TOBJ content matches across the landscape before blaming the check logic.
  • Missing SU24 linkage: the object is defined and coded correctly, but was never assigned to the transaction in SU24. Role builders never see it proposed in PFCG, so it is never maintained with values, and users fail the check in production despite an apparently complete role. This is the most common reason a technically correct SU21 object still causes authorization failures downstream.

Whose problem this is

This sits with the security or authorizations consultant in collaboration with the ABAP developer who codes the check; it is a development-adjacent task, not a Basis or role-administration task. A good handover includes the proposed object name and namespace, the exact field list with data element references, the activities required, the program or service that will check it, and the transport request number so the linkage into SU24 and PFCG can follow without guessing.

Related SAP objects

Reviewed pages this object connects to in the ERPClimb knowledge graph.

Source: ERPClimb — https://erpclimb.com/sap-tcodes/su21ERPClimb is an independent platform and is not affiliated with SAP SE. Reference pages are written and reviewed by SAP consultants for learning and troubleshooting.