AWS Security ChangesHomeSearch

AWS code-library documentation change

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

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

Summary

Added SAP ABAP code example for GetAuthorizationToken API including error handling

Security assessment

The change demonstrates how to retrieve ECR authorization tokens which are security credentials. However, it's a routine example addition without evidence of addressing a specific vulnerability.

Diff

diff --git a/code-library/latest/ug/ecr_example_ecr_GetAuthorizationToken_section.md b/code-library/latest/ug/ecr_example_ecr_GetAuthorizationToken_section.md
index 088ea8129..a6c92f5cd 100644
--- a//code-library/latest/ug/ecr_example_ecr_GetAuthorizationToken_section.md
+++ b//code-library/latest/ug/ecr_example_ecr_GetAuthorizationToken_section.md
@@ -181,0 +182,30 @@ 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/ecr#code-examples). 
+    
+    
+        TRY.
+            oo_result = lo_ecr->getauthorizationtoken( ).
+            DATA(lt_auth_data) = oo_result->get_authorizationdata( ).
+            IF lines( lt_auth_data ) > 0.
+              READ TABLE lt_auth_data INDEX 1 INTO DATA(lo_auth_data).
+              DATA(lv_token) = lo_auth_data->get_authorizationtoken( ).
+              MESSAGE 'Authorization token retrieved.' TYPE 'I'.
+            ENDIF.
+          CATCH /aws1/cx_ecrserverexception.
+            MESSAGE 'Server exception occurred.' TYPE 'I'.
+        ENDTRY.
+    
+    
+
+  * For API details, see [GetAuthorizationToken](https://docs.aws.amazon.com/sdk-for-sap-abap/v1/api/latest/index.html) in _AWS SDK for SAP ABAP API reference_. 
+
+
+
+