AWS Security ChangesHomeSearch

AWS code-library documentation change

Service: code-library · 2026-01-25 · Documentation low

File: code-library/latest/ug/iam_example_iam_DeleteRole_section.md

Summary

Added SAP ABAP SDK code example for DeleteRole action with resource conflict handling

Security assessment

Extends documentation to show secure role deletion implementation in SAP ABAP, including handling of attached resources. No evidence of addressing a specific security incident.

Diff

diff --git a/code-library/latest/ug/iam_example_iam_DeleteRole_section.md b/code-library/latest/ug/iam_example_iam_DeleteRole_section.md
index 092fe23d6..9b8141860 100644
--- a//code-library/latest/ug/iam_example_iam_DeleteRole_section.md
+++ b//code-library/latest/ug/iam_example_iam_DeleteRole_section.md
@@ -422,0 +423,27 @@ There's more on GitHub. Find the complete example and learn how to set up and ru
+SAP ABAP
+    
+
+**SDK for SAP ABAP**
+    
+
+###### Note
+
+There's more on GitHub. Find the complete example and learn how to set up and run in the [AWS Code Examples Repository](https://github.com/awsdocs/aws-doc-sdk-examples/tree/main/sap-abap/services/iam#code-examples). 
+    
+    
+        TRY.
+            lo_iam->deleterole( iv_rolename = iv_role_name ).
+            MESSAGE 'Role deleted successfully.' TYPE 'I'.
+          CATCH /aws1/cx_iamnosuchentityex.
+            MESSAGE 'Role does not exist.' TYPE 'E'.
+          CATCH /aws1/cx_iamdeleteconflictex.
+            MESSAGE 'Role cannot be deleted due to attached resources.' TYPE 'E'.
+        ENDTRY.
+    
+    
+
+  * For API details, see [DeleteRole](https://docs.aws.amazon.com/sdk-for-sap-abap/v1/api/latest/index.html) in _AWS SDK for SAP ABAP API reference_. 
+
+
+
+