Beyond ABAPdesigned by@Tejoram97
Beyond ABAP / BTP Security / Interview Questions

Interview Questions

BTP Security · SAP BTP ·

Open the interactive lesson →

All BTP Security interview questions in one place, grouped by page. Read the page when an answer needs more depth.

How to practise: cover the answer, say yours out loud in 30–60 seconds, then compare.

01 · Identity & Authentication – SAP Cloud Identity Services & Trust

Q1. Why does SAP recommend putting SAP Cloud Identity Services between BTP and the corporate IdP?

BTP then trusts one stable IdP over OIDC, while IAS acts as proxy to Entra ID or any other SAML / OIDC IdP. Corporate IdPs can be added or replaced without touching subaccounts, conditional authentication can route different user groups, IAS adds risk-based 2FA, the Identity Directory gives a Global User ID, and the same tenant provides SSO across all SAP cloud products. Several apps (SAP Build Work Zone, SAP Build Apps) require OIDC trust to IAS anyway.

Q2. What is the difference between the trust in the global account and in a subaccount?

The global account trust is for platform users – cockpit, btp CLI, cf CLI, members at all account levels and CF orgs / spaces; its origin key ends with -platform and can never be changed. The subaccount trust is for business users of the apps and subscriptions in that subaccount; it creates an OIDC application per subaccount in IAS. Kyma has its own configuration.

Q3. What is a shadow user and why does the Create Shadow Users setting matter?

The XSUAA record of a user (identifier + origin) that holds role collection assignments and feeds the token. With automatic creation on, every authenticated user of the IdP gets one at first logon; with it off only users created by an admin or provisioning can log on. Deleting a trust deletes its shadow users and assignments – which is why trusts are migrated, not recreated.

Q4. How do you remove SAP ID service from a productive subaccount safely?

Establish the custom trust and test it; hide the default IdP's logon link first (it stays active); make sure administrators sign in through a custom platform trust; then set the default trust to Inactive (cockpit or btp update security/trust sap.default --status inactive). Decide whether to keep named emergency platform admins in SAP ID service with MFA, and monitor them.

Q5. Employees use Entra ID, partners have no corporate account. How do you design the log-on?

One trust from the subaccount to IAS. In the IAS application set Identity Authentication as default and add conditional authentication rules: employee e-mail domain → Entra ID corporate IdP; partners authenticate at IAS with an IAS password policy and risk-based 2FA (or with their own IdP added as second corporate IdP). Partner users get blocking and deletion for inactivity.

Q6. How do you enforce MFA for BTP administrators?

Use a custom platform IdP (SAP Cloud Identity Services tenant) instead of SAP ID service, where MFA cannot be enforced. Enforce it in the corporate IdP's conditional access, or with IAS risk-based authentication in every IAS application involved (the SAP Business Technology Platform application and any Neo applications). Admins then use btp login --sso and cf login --sso; scripted tools accept password plus TOTP.

Q7. What can go wrong with tenant-wide risk-based authentication?

The rules also apply to the Administration Console. A Deny or 2FA default that the administrator does not satisfy locks them out after logout. Test with a second session open, keep a second admin, enable backup channels for TOTP, and remember changes take about two minutes and are not applied to technical OIDC communication.

Q8. A company used SAML trust to IAS for years and now needs SAP Build Work Zone. What do you do?

Migrate the SAML trust in place to OpenID Connect (cockpit or btp migrate security/trust, rollback with btp restore security/trust). Before: collect user data, make sure IAS trusts the corporate IdP. After: configure the new IAS application with the same subject name identifier and attributes, then test. Practise in DEV and TEST; expect downtime. Do not delete and recreate the trust.

Q9. How do leavers lose access to BTP?

Primarily at the source: the corporate account is disabled, so the user cannot authenticate, and Identity Provisioning removes the user and groups from IAS in a full read (delta reads never delete). Existing tokens stay valid until they expire, so token validity matters. Afterwards shadow users, platform memberships and CF roles must be deleted – they are personal data and show up in access reviews.

Q10. What is the difference between the Identity Directory and Identity Provisioning?

The Identity Directory is the persistence layer – the tenant's users and groups, custom schemas, the SCIM API and the Global User ID. Identity Provisioning is the engine that moves users and groups between systems: sources, targets, proxies, jobs with full or delta read, transformations, real-time provisioning. A typical chain is Entra ID → Identity Directory → BTP or S/4HANA Cloud.

Q11. Which settings decide how long a logged-on user keeps access?

The IAS session timeout (default 12 h, 5 min – 12 h), which also caps IAS-issued token lifetimes; the XSUAA access and refresh token validity (Security › Settings or xs-security.json, SAP: short but not below 30 minutes); the corporate IdP's session; and Forward All SSO Requests, which forces a new corporate authentication per app.

Q12. As an architect, how many IAS tenants does a BTP landscape need?

As few as possible: one productive tenant shared by all SAP cloud products and the productive subaccounts (SSO, one Global User ID), plus the test tenant for non-productive subaccounts to try IAS changes first. Additional tenants only for data residency or regional needs, or separate SuccessFactors instances – they can break out-of-the-box SSO. Platform users can use up to three tenants per global account but normally use the productive one.

02 · Authorization Administration – Role Collections, Roles & Attributes

Q1. What is the difference between a role template, a role and a role collection?

The developer defines role templates (scopes plus attribute references) in xs-security.json. A role is an instance of a template: generated automatically when the template has no attributes, created by the admin with concrete attribute values otherwise. A role collection bundles roles, possibly from several applications, and is the only thing assigned to users, groups or attributes.

Q2. Which default role collections exist and which of them are critical?

Global Account Administrator / Viewer, Directory Administrator / Viewer, Subaccount Administrator / Viewer, plus Subaccount Service Administrator, Destination Administrator, Destination Fragment Administrator, Cloud Connector Administrator and Connectivity and Destination Administrator. The administrator collections of global account, directory and subaccount contain User and Role Administrator, so their holders can grant any authorization – SAP recommends regularly checking who has it (BTP-UAA-0017).

Q3. A global account administrator says they cannot see a subaccount's data. Is that a problem?

Global account admins don't automatically have subaccount authorizations, because role collections are account-specific. But they can use Add Me as Admin in the Account Explorer, so they must be treated as potential subaccount admins. The feature can be disabled by an opt-out request to SAP.

Q4. How do you give an operator full control of a subaccount except authorization management?

Default collections cannot be changed, so build a custom role collection with the Subaccount Admin, Subaccount Service Administrator, Destination Administrator and Cloud Connector Administrator roles but without User and Role Administrator, and map it to the operators' IdP group.

Q5. What are the three attribute sources of a role?

Static (values stored in the role), Identity Provider (value read from a named SAML / OIDC attribute of the user, case-sensitive) and Unrestricted (behaves as if the attribute did not exist). The values reach the app in xs.user.attributes; the app filters data with them.

Q6. Why map role collections to IdP groups instead of users?

Access then follows the identity lifecycle: joiners, movers and leavers are handled by changing group membership in the corporate directory, no BTP admin step is needed, reviews happen in one place and no orphaned direct assignments remain. Group mapping requires a custom trust such as SAP Cloud Identity Services; the default IdP supports only user assignments.

Q7. A user was added to the right group but still gets 403. What do you check?

That the user logged on again (scopes are fixed at token issue); that the IAS application sends the groups attribute; that the mapping uses the right identity provider and the exact, case-sensitive group name; that the user logs on with that identity provider and not SAP ID service; and that the role collection really contains the needed role.

Q8. What is AMS and when do you need it instead of role collections?

The Authorization Management Service of SAP Cloud Identity Services. IAS tokens carry no XSUAA scopes, so IAS-based apps get their authorizations from policies: developers deploy base policies in DCL, administrators create custom policies (restrictions or combinations) and assign them to users in the IAS administration console, and the AMS library evaluates them in the app. SAP also recommends AMS for new instance-based authorizations.

Q9. How do you automate role collections across DEV, TEST and PROD?

With the Terraform provider for SAP BTP: btp_subaccount_role for attribute roles, btp_subaccount_role_collection for the bundle and btp_subaccount_role_collection_assignment for user, group or attribute assignments, one module per stage with different values. Alternatively the btp CLI (create security/role-collection, add security/role, assign security/role-collection).

Q10. How do you run an access review of a productive subaccount?

Export all users with role collections, list holders of collections containing User and Role Administrator, filter users who haven't logged on for 180 or 365 days, compare group mappings with group members in IAS / the corporate IdP, review IAS admins and AMS assignments, remove what is not justified and archive the audit log entries of category audit.configuration as evidence.

Q11. As an architect, how do you design authorizations for a new BTP landscape?

Custom IdP for platform and business users; job-based role collections with a naming convention, created by Terraform identically in all stages; group mappings only, direct assignments only for break-glass users; separate operator and security-admin collections; developers only in DEV; IdP-sourced attributes or AMS policies for data restrictions; quarterly reviews against SAP's security recommendations and audit log forwarding to the SIEM.

03 · Connectivity Security – Cloud Connector, Destinations & Principal Propagation

Q1. Why is the Cloud Connector considered secure even though it gives cloud apps access to the intranet?

It opens only an outbound TLS tunnel on port 443 – no inbound firewall port; it exposes nothing by default and uses a strict allowlist of virtual hosts, URL paths and function modules; physical host names stay hidden behind virtual hosts; it can encrypt the internal hop with HTTPS or SNC, forward the real user, and writes an audit log. Its security still depends on how you harden and configure it.

Q2. Where would you install the Cloud Connector and how would you harden the host?

For sensitive back ends in the DMZ, operated by central IT, on a dedicated machine with disk encryption, OS-level audit logging, a dedicated service user and very few OS administrators. Separate instances for production and non-production, a master and shadow pair in a stable network, and a patched JDK and connector version.

Q3. How do you secure the Cloud Connector administration UI?

Change the initial password, then switch to LDAP (LDAPS) user management with named users and the roles sccadmin, sccsubadmin, sccsupport, sccdisplay and so on, so the audit log shows who changed what. Replace the self-signed UI certificate with a company-CA certificate, disable weak ciphers, optionally use client-certificate logon or limit access to localhost.

Q4. What is the risk of "Path and all sub-paths" and how do you use it safely?

It is a prefix match: every path starting with the string is allowed, and / exposes the whole server. Use Path only where possible; for OData services expose only each service root with sub-paths, never the generic OData root, and review the list regularly. For RFC prefer exact function names.

Q5. What does the "System Certificate for Logon" option do and what does SAP recommend?

If on, the connector's system certificate is used to authenticate at the back end when no principal is sent – effectively a technical identity. SAP recommends keeping it off, so the system certificate only establishes mTLS trust and principal propagation and basic authentication can share a mapping.

Q6. Walk through the setup of principal propagation to S/4HANA over HTTPS.

Connector: synchronise and trust the subaccount's IdP, import a system certificate for mTLS and a CA certificate for the short-lived user certificates, define the subject pattern, allow principal propagation with principal type X.509 on the mapping. S/4HANA: import the CAs in STRUST, set icm/trusted_reverse_proxy_<x> to the system certificate's subject and issuer, request client certificates on the HTTPS port, map users with CERTRULE from the sample certificate, allow certificate logon in SICF. BTP: destination with ProxyType OnPremise and PrincipalPropagation.

Q7. Which settings of the subject pattern matter for security?

Which attribute identifies the user – it must be stable and not changeable by the user, otherwise an attacker could impersonate someone; the certificate validity (0–43200 minutes) and the expiration tolerance (0–336 hours), which should be short; and conditions such as user type that separate business and technical users.

Q8. Who can read the credentials stored in destinations?

Users with destination or certificate administrator roles in the cockpit – and anybody holding a binding or service key of the Destination service instance, which gives full REST API access to its destinations and certificates. So service keys are rare, X.509-based, rotated and audited, and user-based authentication types avoid stored passwords altogether.

Q9. Which authentication type do you choose for an interactive app calling on-premise S/4HANA, and which for S/4HANA Cloud?

On-premise: PrincipalPropagation via the Cloud Connector. S/4HANA Cloud: OAuth2SAMLBearerAssertion with the subaccount's Destination Trust certificate configured in the target, or another user-based OAuth flow. Technical integrations use OAuth2ClientCredentials, preferably with mTLS to the token service, or client certificates – never shared dialog users.

Q10. How do you avoid outages caused by certificates?

Keep an inventory: Cloud Connector UI, subaccount, system and CA certificates, destination key and trust stores, the Destination Trust key, and the back-end PSEs. Turn on automatic renewal for subaccount certificates and generated destination certificates, configure alerts for the rest, rotate the SAML trust key with the passive certificate, and let targets trust the CA and subject instead of the single certificate.

Q11. How does SAP Private Link service change the security picture?

Traffic to services in your own hyperscaler account stays on the provider's backbone, and a space-scoped security group limits which apps reach the endpoint. You must still restrict and approve connection requests carefully (only SAP BTP's accounts, only the expected endpoint name) and keep TLS, certificate validation and authentication on the connection.

Q12. An auditor asks you to prove that only the sales order app can reach S/4HANA and only as the logged-on user. What do you show?

The connector's access control list (one virtual host, HTTPS, the API service roots only), the mapping with principal propagation and System Certificate for Logon off, the trusted IdP list, the destination configuration (PrincipalPropagation, no stored user), the role collections that may change destinations, the connector audit log at level All with denied requests, and the S/4HANA Security Audit Log showing individual users mapped via CERTRULE.

04 · Platform Security & Compliance – Audit Log, Credentials, Keys & Data Protection

Q1. Explain the shared responsibility model of SAP BTP.

SAP provisions the global account and entitlements and operates and updates the runtimes and services; the infrastructure provider (SAP or a hyperscaler, managed by SAP) runs the data centres. The customer owns data and content including privacy, application development and integration, change management and open-source patching, the account structure, users and authorizations. Security and compliance, observability and HA / DR are joint: SAP provides certified controls and Trust Center reports, the customer secures its solutions and follows SAP's security recommendations.

Q2. What does the SAP Audit Log service record and in which categories?

Security-relevant evidence written by BTP services for your subaccount – and by your own apps with the premium plan – in four categories: audit.security-events (log-ons, permission and credential changes), audit.configuration (old and new values of configuration changes), audit.data-access (reads of sensitive personal data) and audit.data-modification (changes to personal data).

Q3. The auditor needs one year of audit logs. BTP keeps 90 days. What are your options?

Either pull the logs regularly with the Audit Log Retrieval API into a central archive or SIEM – SAP's recommendation BTP-AUD-0001 – or entitle auditlog / premium and ask SAP by ticket on BC-CP-CF-SEC-AUDITLG for a longer retention, paid per GB. Most companies do the first anyway, because correlation and alerting happen in the SIEM.

Q4. How do you get audit logs of the whole landscape into a SIEM?

One auditlog-management instance (plan default) with X.509 credentials in each subaccount, plus the central plan in a dedicated subaccount of the central region for global-account events. A collector gets a token with the client certificate, polls /auditlog/v2/auditlogrecords with overlapping time windows, follows the paging handle, respects the rate limits and de-duplicates. Keys are short-lived and re-created at least every 90 days.

Q5. Your CAP app shows customers' bank data. What must you do for audit logging?

The platform cannot log it – SAP BTP does not provide audit logging for custom developments. Annotate the entities with @PersonalData (bank fields IsPotentiallySensitive so reads are logged), add @cap-js/audit-logging and bind an auditlog premium instance with X.509 credentials; check that the write API is available in the region and plan for per-GB cost.

Q6. How do you secure an SAP Credential Store instance in production?

Authentication mtls, oauth:mtls or oauth:key, never basic; keep payload encryption on; restrict every binding to its namespace with namespace_permissions (and ACL groups for shared instances); rotate bindings before their 60-day default expiry, automated through blue-green deployments; Alert Notification on expiring bindings; archive its audit events; optionally a customer-managed key.

Q7. What is a customer-managed key and what is the risk?

With SAP Key Management Service you replace the SAP-managed key for data at rest with your own key (BYOK import or HYOK registration in your own key store). If you disable or revoke it, nobody – not even SAP or a restore from backup – can read the data; an ABAP environment, for example, is stopped and can stay stopped only up to seven days. It enables crypto-shredding and exit strategies but needs strict key governance and a tested restore path.

Q8. How are token signing keys rotated and what can break?

Automatic rotation in Security › Settings › Signing Keys or btp update security/settings --rotate-signing-key-automatically TRUE; the new key becomes active after 48 hours (default for subaccounts created after 19 January 2026). It breaks consumers that cache keys and is not possible with SAP HANA Cloud principal propagation through a Cloud Connector older than 2.19.0. Test in a non-productive subaccount first.

Q9. An employee left. What data protection steps apply on BTP?

Deactivate or delete the user in SAP Cloud Identity Services or the corporate IdP, then delete the shadow users in every subaccount and at Cloud Foundry level – otherwise the user is re-created on the next log-on. Use the Hasn't Logged On filter for periodic clean-up. Remember personal data in audit and application logs and that the deletion cannot be undone.

Q10. How do you integrate malware scanning into an upload?

Bind malware-scanner / clamav with mTLS, POST the plain binary to the /scan endpoint, store the timestamp with the file and rescan on use if older than three days. On a positive result delete the file and log a security event; if the service is down, store the file unscanned and scan later, and warn users on download. Limits: 400 MB, 30 concurrent requests per subaccount, 25-minute time-out.

Q11. The customer's auditor asks for SOC 2 and ISO 27001 evidence for BTP. Where do you get it?

From the SAP Trust Center and, for existing customers, SAP for Me (Portfolio & Products), some reports only under NDA. Check that the services and regions you use are in scope – BTP is covered by the SAP Central Cloud Services SOC and C5 reports – use bridge letters between SOC periods, and add your own evidence for the customer side of the shared responsibility model.

Q12. Which network security controls exist on BTP and which can you configure?

TLS 1.2+ for all endpoints (TLS 1.3 optional on custom domains); Cloud Foundry application security groups that SAP manages and you can only read; published NAT and load-balancer IPs per region for your firewall allow-lists; Cloud Connector and SAP Private Link for private connectivity; in Kyma the IaaS default DDoS protection and your own network policies, but no configurable web application firewall.

05 · Security Recommendations & Hardening – Checklist, Threats & Incident Response

Q1. What are the SAP BTP Security Recommendations and how are they structured?

A table on help.sap.com that lists, per service or component, the security-relevant setting, its default behaviour, SAP's recommendation, a link to the configuration steps, a priority (Critical, Recommended, Advanced), a Secure Operations Map area, a last-update date and a stable Index ID such as BTP-UAA-0008. Each service's documentation shows the same entries by role. Under shared responsibility the customer decides which apply.

Q2. How do you use the recommendations in a real project?

Inventory the components used in each subaccount, review their recommendations starting with Critical, decide and document implementation or risk acceptance per Index ID, and re-review regularly using new Index entries and changed Last Update dates. Automate what you can with SAP Cloud ALM Configuration & Security Analysis and check the rest manually.

Q3. Name five critical hardening steps for a new production subaccount.

Custom IdP via Identity Authentication instead of the default IdP (BTP-UAA-0008); MFA for administrators (BTP-IAS-0001); least-privilege role collections through IdP groups with few administrators; Cloud Connector exposing only exact paths over HTTPS/SNC (BTP-SCC-0009, -0008, -0015); binding secrets or X.509 with rotation and audit log export to a SIEM (BTP-UAA-0003, BTP-AUD-0001).

Q4. Why does SAP recommend not using the default identity provider in production?

With the default IdP the customer has no control over password and authentication policies, MFA or the user lifecycle. Identity Authentication as a proxy to the corporate IdP lets you enforce your own policies, single sign-on and joiner-mover-leaver processes across the landscape.

Q5. How long are audit logs kept on BTP and what follows from that?

The SAP Audit Log service in the Cloud Foundry environment keeps them for 90 days free of charge. If you need them longer – for compliance or for an investigation that starts late – export them regularly through the audit log retrieval API (or download them from the viewer) into your own archive or SIEM, for the global account and every subaccount. A longer retention inside BTP is possible only with the premium plan and a support ticket, paid per GB (page 04); SAP's recommendation BTP-AUD-0001 still describes the 90 days as fixed, so most companies archive anyway.

Q6. What do you look for in a periodic access review on BTP?

Holders of critical role collections (Global Account Administrator, Subaccount Administrator and any custom collection containing roles such as User and Role Administrator, Cloud Connector Administrator or Destination Administrator), Cloud Foundry org and space roles, group-to-role-collection mappings, Identity Authentication and Cloud Connector admins, and inactive or never-used shadow users (cockpit filter Hasn't Logged On). Evidence can be produced with btp get security/role-collection --show-user-assignments.

Q7. A client secret of a production app was pushed to a public Git repository. What do you do?

Export the audit logs for the period first. Then rotate: unbind and rebind the app to get a new binding secret, delete the leaked service key, and rotate the signing key if you suspect broader compromise. Remember that tokens already issued stay valid until expiry. Check the audit log for what the client did, fix the root cause (secret scanning, X.509 credentials), and report as required.

Q8. Which Cloud Connector settings are the most security-critical?

A current Cloud Connector version and patched JVM, access control with exact URL paths and RFC function names (no root URL with all sub-paths), HTTPS/SNC/LDAPS to back ends, a restricted list of trusted root CAs, named LDAP administrators instead of the default Administrator, audit logging on, and traces off except under the four-eyes principle.

Q9. How do you detect security-relevant changes on BTP?

Stream the audit logs (global account and subaccounts) to a SIEM or SAP Enterprise Threat Detection and alert on trust changes, assignments to critical role collections, new service keys or API credentials, destination changes and failed-logon bursts. Add Identity Authentication alert e-mails, Cloud Connector alerts, and SAP Cloud ALM Configuration & Security Analysis for configuration drift.

Q10. Where does SAP's responsibility end in a BTP security incident?

SAP is responsible for the infrastructure, platform services and runtimes it operates, and handles incidents there. The customer is responsible for its configuration and content: users and role collections, trust, credentials, destinations, the Cloud Connector, applications and their data. A compromised admin account or leaked key is the customer's incident; suspected platform issues go to SAP through a support case.

Q11. Which defaults on BTP are already secure, and which must you change?

Secure by default: self-registration and social sign-on off, TLS 1.2 for destinations, Credential Store payload encryption on, Cloud Connector audit log on and traces off, per-binding XSUAA secrets for new instances, and automatic signing key rotation for new subaccounts. To change: the default IdP, password logon without MFA for the Identity Authentication admin console, the single Cloud Connector Administrator, trust in all root CAs, the 90-day audit log retention without export, and long-lived credentials of older instances.

Q12. Scenario: the auditor asks you to prove least privilege for the production subaccount. What do you deliver?

A scripted export (btp CLI) of all role collections with their user assignments and IdP group mappings, the IdP group memberships confirmed by the business owners, the list of inactive users removed, the service keys and API credentials with owner and age, audit log extracts showing assignment changes in the period, and the recommendation register with status per Index ID.