RFC Gateway Security, Part 1 - Basic Understanding - SAP Blogs
RFC Gateway Security, Part 1 - Basic Understanding - SAP Blogs
Community
Technical Articles
Johannes Goerlich
January 26, 2021 | 5 minute read
From my experience the RFC Gateway security is for many SAP Administrators still a
Like not well understood topic. As a result many SAP systems lack for example of proper
defined ACLs to prevent malicious use of the RFC Gateway.
RSS Feed After an attack vector was published in the talk “SAP Gateway to Heaven” from
Mathieu Geli and Dmitry Chastuhin at OPDCA 2019 Dubai
(https://github.com/gelim/sap_ms) the RFC Gateway security is even more
important than ever. This publication got considerable public attention as
10KBLAZE.
With this blogpost series i try to give a comprehensive explanation of the RFC
Gateway Security:
Part 1: General questions about the RFC Gateway and RFC Gateway security.
https://blogs.sap.com/2021/01/26/rfc-gateway-security-part-1-basic-understanding/ 1/9
10/21/21, 1:13 PM RFC Gateway security, part 1 – basic understanding | SAP Blogs
Basic understanding
In the following i will do the question and answer game to develop a basic
understanding of the RFC Gateway, the RFC Gateway security and its related terms.
From a technical perspective the RFC Gateway is a SAP kernel process (gwrd,
gwrd.exe) running on OS level as user <sapsid>adm.
https://blogs.sap.com/2021/01/26/rfc-gateway-security-part-1-basic-understanding/ 2/9
10/21/21, 1:13 PM RFC Gateway security, part 1 – basic understanding | SAP Blogs
In SAP NetWeaver Application Server Java: The SCS instance has a built-in
RFC Gateway.
There may also be an ACL in place which controls access on application level.
The location of this ACL can be defined by parameter ‘gw/acl_info’.
https://blogs.sap.com/2021/01/26/rfc-gateway-security-part-1-basic-understanding/ 3/9
10/21/21, 1:13 PM RFC Gateway security, part 1 – basic understanding | SAP Blogs
This diagram shows all use-cases except `Proxy to other RFC Gateways´. The
subsequent blogs of will describe each individually.
The RFC Gateway allows ‘external RFC Server programs’ (also known as
‘Registered Server’ or ‘Registered Server Program’) to register to itself and
allows RFC clients to consume the functions offered by these programs.
Common examples are the program ‘tp’ for transport management via STMS
started on the RFC Gateway host of AS ABAP or the program ‘gnetx.exe’ for
https://blogs.sap.com/2021/01/26/rfc-gateway-security-part-1-basic-understanding/ 4/9
10/21/21, 1:13 PM RFC Gateway security, part 1 – basic understanding | SAP Blogs
the graphical screen painter started on the SAP GUI client host.
Please note: One should be aware that starting a program using the RFC
Gateway is an interactive task. This means the call of a program is
always waiting for an answer before it times out. If the called program is
not an RFC enabled program (compiled with the SAP RFC library) the
call will time out, but the program is still left running on the OS level!
To overcome this issue the RFC enabled program ‘SAPXPG’ can be used
as a wrapper to call any OS command. This is for example used by AS
ABAP when starting external commands using transaction
SM49/SM69.
‘RFC destinations’
The RFC Gateway hands over the request from the RFC client to the dispatcher
which assigns it to a work process (AS ABAP) or to a server process (AS Java).
The RFC Gateway can be used to proxy requests to other RFC Gateways.
The secinfo file is holding rules controlling which programs (based on their
executable name or fullpath, if not in $PATH) can be started by which user
calling from which host(s) (based on its hostname/ip-address) on which RFC
Gateway server(s) (based on their hostname/ip-address).
When using SNC to secure RFC destinations on AS ABAP the so called ‘SNC
System ACL’, also known as ‘System Authentication’ – where imho the term
‘Authentication’ is misleading -, is introduced and must be maintained
accordingly.
This ACL is applied on the ABAP layer and is maintained in transaction SNC0.
Please note: ‘SNC System ACL’ is not a feature of the RFC Gateway itself.
Next –>
https://blogs.sap.com/2021/01/26/rfc-gateway-security-part-1-basic-understanding/ 6/9
10/21/21, 1:13 PM RFC Gateway security, part 1 – basic understanding | SAP Blogs
Alert Moderator
Assigned tags
ABAP Connectivity
Security
View more...
RFC Gateway security, part 5 - ACLs and the RFC Gateway security
By Johannes Goerlich Feb 03, 2021
https://blogs.sap.com/2021/01/26/rfc-gateway-security-part-1-basic-understanding/ 7/9
10/21/21, 1:13 PM RFC Gateway security, part 1 – basic understanding | SAP Blogs
Related Questions
Gateway not connected to local R/3
By souradeep ghosal Aug 10, 2021
Coffee Corner
Join the new Coffee Corner Discussion Group.
Find us on
https://blogs.sap.com/2021/01/26/rfc-gateway-security-part-1-basic-understanding/ 8/9
10/21/21, 1:13 PM RFC Gateway security, part 1 – basic understanding | SAP Blogs
Newsletter Support
https://blogs.sap.com/2021/01/26/rfc-gateway-security-part-1-basic-understanding/ 9/9