Hardening of SAP HTTP- and Webservices



Similar documents
Hardening of SAP HTTP- and Webservices

Processed on SAP Solution Manager Service Center Release EHP 1 for Solution Manager 7.0 Telephone Service Tool 701_2011_1 SP0 Fax

Members of the UK cyber security forum. Soteria Health Check. A Cyber Security Health Check for SAP systems

Application Gateway with Apache

WEB SERVICES WITH APPLICATION SERVER ABAP

Unbreakable ABAP? Vulnerabilities in custom ABAP Code Markus Schumacher, Co-Founder Virtual Forge GmbH

Out of the Fire - Adding Layers of Protection When Deploying Oracle EBS to the Internet

ATTACKS TO SAP WEB APPLICATIONS

Cloud Security:Threats & Mitgations

ArcGIS Server Security Threats & Best Practices David Cordes Michael Young

Magento Security and Vulnerabilities. Roman Stepanov

WEB SECURITY CONCERNS THAT WEB VULNERABILITY SCANNING CAN IDENTIFY

WHITE PAPER. FortiWeb and the OWASP Top 10 Mitigating the most dangerous application security threats

Web Application Vulnerability Testing with Nessus

So far in the first three chapters of this book we have studied an overview of SAP

SAML 2.0 Configurations at SAP NetWeaver AS ABAP and Microsoft ADFS

(WAPT) Web Application Penetration Testing

OWASP Top Ten Tools and Tactics

Kenna Platform Security. A technical overview of the comprehensive security measures Kenna uses to protect your data

How-to-Guide: SAP Web Dispatcher for Fiori Applications

SAP SECURITY AND AUTHORIZATIONS - RISK MANAGEMENT AND COMPLIANCE WITH LEGAL REGULATIONS IN THE SAP ENVIRONMENT

SAP R/3 Security Assessment Framework

Hardening Moodle. Concept and Realization of a Security Component in Moodle. a project by

Where every interaction matters.

Developing Applications for Integration between PI and SAP ERP in Different Network Domains or Landscapes

SAP SECURITY OPTIMIZATION

: C_TADM SAP Certified Technology Associate System Administration (Oracle DB) with SAP NetWeaver 7.0 EhP2. Title : Version : Demo

SAP Certified Technology Professional - Security with SAP NetWeaver 7.0. Title : Version : Demo. The safer, easier way to help you pass any IT exams.

How to break in. Tecniche avanzate di pen testing in ambito Web Application, Internal Network and Social Engineering

Sichere Software- Entwicklung für Java Entwickler

Adobe Systems Incorporated

SAP SECURITY OPTIMIZATION

What is Web Security? Motivation

Sitefinity Security and Best Practices

Gateway Apps - Security Summary SECURITY SUMMARY

SAP Netweaver Application Server and Netweaver Portal Security

Nuclear Regulatory Commission Computer Security Office Computer Security Standard

SAP WEB DISPATCHER Helps you to make decisions on Web Dispatcher implementation

Setup Guide Central Monitoring of SAP NetWeaver Proces Integration 7.3 with SAP Solution Manager 7.1. Active Global Support February 2011

Using Free Tools To Test Web Application Security

WEB SITE SECURITY. Jeff Aliber Verizon Digital Media Services

SAP SECURITY OPTIMIZATION

Web Application Security Assessment and Vulnerability Mitigation Tests

How to complete the Secure Internet Site Declaration (SISD) form

Web Security - Hardening estudy

Testing the OWASP Top 10 Security Issues

3. Broken Account and Session Management. 4. Cross-Site Scripting (XSS) Flaws. Web browsers execute code sent from websites. Account Management

Inception of the SAP Platform's Brain Attacks on SAP Solution Manager

How To Manage Work Mode On An It Calendar On An Apa System

SAP Fiori Infrastructure rapid-deployment solution: Software and Delivery Requirements

SAP NetWeaver AS Java

SAP Web Application Server Security

WHITE PAPER FORTIWEB WEB APPLICATION FIREWALL. Ensuring Compliance for PCI DSS 6.5 and 6.6

Security and Risk Management

Essential IT Security Testing

Web Application Firewall on SonicWALL SSL VPN

WHITE PAPER. FortiWeb Web Application Firewall Ensuring Compliance for PCI DSS 6.5 and 6.6

Data Breaches and Web Servers: The Giant Sucking Sound

SAP Fiori - Architecture

Andreas Wiegenstein Dr. Markus Schumacher

Creating a User Profile for Outlook 2013

Web Application Penetration Testing

How To... Develop, Monitor and Debug WS Consumer and Provider

CRM WebClient UI & Netweaver Enterprise Portal Integration

EAS-SEC Project: Securing Enterprise Business Applications

Web Application Security

Security and Your SAP System When Working with Winshuttle Products

SAP Secure Operations Map. SAP Active Global Support Security Services May 2015

SAP NetWeaver Single Sign-On. Product Management SAP NetWeaver Identity Management & Security June 2011

Software and Delivery Requirements

Introduction to the EIS Guide

Auditing the Security of an SAP HANA Implementation

Installation and configuration guide

White Paper Secure Reverse Proxy Server and Web Application Firewall

Master Data Governance Security Guide

SAP Mobile - Webinar Series SAP Mobile Platform 3.0 Security Concepts and Features

Overview of the Penetration Test Implementation and Service. Peter Kanters

Top Ten Web Application Vulnerabilities in J2EE. Vincent Partington and Eelco Klaver Xebia

Secure Web Appliance. Reverse Proxy

Thomas Röthlisberger IT Security Analyst

Configuration of Enterprise Services using SICF and SOA Manager

SAP: Session (Fixation) Attacks and Protections

How To... Use SOA Configuration to Call RFCs and Web Services from within SAP NetWeaver BPM

OWASP and OWASP Top 10 (2007 Update) OWASP. The OWASP Foundation. Dave Wichers. The OWASP Foundation. OWASP Conferences Chair

OWASP AND APPLICATION SECURITY

Secure Programming Lecture 12: Web Application Security III

Interwise Connect. Working with Reverse Proxy Version 7.x

IIS SECURE ACCESS FILTER 1.3

AppDefend Application Firewall Overview

AntiVirus Bridge for SAP solutions

StreamServe Persuasion SP5 StreamStudio

Web applications. Web security: web basics. HTTP requests. URLs. GET request. Myrto Arapinis School of Informatics University of Edinburgh

FileCloud Security FAQ

StreamServe Job Gateway

Tenrox. Single Sign-On (SSO) Setup Guide. January, Tenrox. All rights reserved.

Transcription:

Hardening of SAP HTTP- and Webservices Sebastian Schinzel (Slides shamelessly stolen from by colleague Frederik Weidemann) Virtual Forge GmbH University of Mannheim

Hardening of SAP HTTP- and Webservices Introduction History Network Landscape Overview Secure Configuration SAP NW ABAP Services What can be configured, what is programmed Logging Pitfalls SAP Web Services with ABAP Overview 2

OWASP Top 10 2010 A1 A2 A3 A4 A5 A6 A7 A8 A9 A10 Injection Cross-Site Scripting (XSS) Broken Authentication and Session Management Insecure Direct Object References Cross-Site Request Forgery (CSRF) Security Misconfiguration Insecure Cryptographic Storage Failure to Restrict URL Access Insufficient Transport Layer Protection Unvalidated Redirects and Forwards 3

History of SAP Web App Technology ITS Release R/3, 4.6b+ SAP Web AS ICM Release 6.10 SAP NW AS ABAP Replaces Web AS 4

Introduction SAP Landscape Setup Landscape should consist of at least 3 systems DEV TEST / QA PROD In the field: often only PROD or DEV+PROD But: sometimes also 4 systems (D T Q P) 5

Introduction - Network Network Landscapes as described in the NW Security Guide Internet Outer DMZ Inner DMZ High Security Area Application Gateways SAP WebAS or Webservice Intranet Clients Backend 6

Protection on Network Layer (Web) WebDispatcher # Permissions Load Balancer P /sap/bc/ SSL Termination P /sap/owasp/ D * URL Path whitelisting Limit URL size (wdisp/max_permitted_uri_len) Limit URL characters in range (wdisp/ permitted_uri_char_range) Other Reverse Proxies Often seen: Apache mod_security, mod_proxy Other commercial vendors... Recommendation: Reverse proxy is a must have 7

Architecture SAP NetWeaver AS ABAP SAP GUI Web NW AS APAP RFC GW Dispatcher Work processes Dispatcher Queue Memory Pipes ICM Database Architecture since release 6.10 Integration of ICM (process) into the SAP Kernel ICM supports HTTP, HTTPS, SMTP, SOAP, WebDav 8

Secure Configuration SAP NW ABAP Overview HTTP Standard Services Authentication Methods Protection by configuration Logging Security Audit Log 9

Secure Configuration SAP NW ABAP HTTP Standard Services Maintenance via Transaction (Tr.) SICF Release NW 7.01 EhP1 is delivered with deactivated services Older releases may need manual maintenance Best practice: Deactivate ALL services and activate them individually as required Avoid inherited activations (!) /sap/bc/soap/rfc 10

Secure Configuration SAP NW ABAP HTTP Standard Services Phishing: 11

Secure Configuration SAP NW ABAP Authentication Methods Individual methods configurable for each ICF node SSO Basic Authenitication X.509 Client Certificates Session based (only for stateful applications) Anonymous logon via authentication on behalf of a hard coded user (configured by admin) Custom Development: Use the secure standards provided by SAP Additional check configurable against authority object S_ICF (Tab Service Data SAP Authoriz.) 12

Secure Configuration SAP NW ABAP Profile Parameters ABAP Stack / profile parameter Accessed on OS level (/usr/sap/<sid>/sys/ profile) or via Transactions RZ10/RZ11 Maintain password parameters Check SSL setup SSO Configuration 13

Secure Configuration SAP NW ABAP Example Parameters Password login/min_password_lng login/min_password_digits login/min_password_letters login/min_password_specials login/password_charset login/min_password_diff login/password_expiration_time login/password_change_for_sso login/disable_password_logon login/password_logon_usergroup... Logon login/fails_to_session_end login/fails_to_user_lock login/failed_user_auto_unlock login/no_automatic_user_sapstar... Validity login/min_password_digits login/password_max_new_valid login/password_max_reset_valid Others is/http/show_detailed_errors icm/https/verify_client icm/security_log..., e.g. */HTTP/*, icm/* auth/rfc_authority_check SSO login/accept_sso2_ticket login/create_sso2_ticket login/ticket_expiration_time login/ticket_only_by_https login/ticket_only_to_host 14

Secure Configuration SAP NW ABAP Working with Redirects Example SAP URL Parameter: sap-exiturl Used upon exiting a stateful BSP Table HTTP_WHITELIST to maintain allowed redirect destinations (Maintenance via Tr. SE16) Empty table == no checks Example entry: protocol=https, host=mysite.owasp.org, port=23443, url=/sap/redirects/* (wildcard * is allowed) Development with ABAP: CL_HTTP_UTILITY=>CHECK_HTTP_WHITELIST 15

Secure Configuration SAP NW ABAP Logging of ICM Tr. SMICM (Goto HTTP Log HTTP Server / Client) Deactivated by default Log format is equal to mod_log_config of Apache Log format can be customized Anonymizes certain parameters/header fields with dots: e.g. MYSAPSSO2 Cookie, jsessionid... Recommendation: Use reverse proxy logs easier analysis If required, add SAPs ICM logging (Remember: x-forwarded-for header, parameter wdisp/ add_xforwardedfor_header = TRUE for Web Dispatcher) 16

Secure Configuration SAP NW ABAP Security Audit Log Inactive by default Enabled by rsau/enable = 1 Maintained with Tr. SM20 Logging of: Dialog logon attempts RFC logon attempts RFC calls to function modules Transaction starts Report starts Changes to the user master records Changes to the audit configuration Caveat: Possible violation of data protection laws! 17

Secure Configuration SAP NW ABAP Lessons Learned Lessons learned: Log inactive by default Huge number of configuration possibilities Complexity in Audits (Who maintains several hundred pages of documentation and who reads it???) SAP already offers a lot of functionality Problem: you have to know about it SSL must be separately installed (SAPCRYPTOLIB) and activated 18

SAP Web Services with ABAP Server Inside-Out (RFC-enabled function modules are used as a basis for generation) Outside-In (Service Interface in ES Repository is used to generate the skeleton) Client UDDI compliant registry with NW 7.1 (called ES Repository) Maintenance: formerly Tr. WSCONFIG + WSADMIN since NW 2004s SP14 Tr. SOAMANAGER Redirects to WebDynpro ABAP App Must be enabled previously 19

SAP Web Services with ABAP - SOAMANAGER 20

SAP Web Services with Custom ABAP Development - Top 3 problems Typical Scenario User calls WebService WebService calls a RFC in the backend SAP NW ABAP SAP NW ABAP User WebService RFC DB 21

SAP Web Services with Custom ABAP Development - Top 3 problems Most common problems Insufficient validation and authentication between frontend user and backend data Usually backend calls are made with preconfigured high privilege accounts Thus, iterating through parameters results in disclosure of data A4 - Insecure Direct Object References Missing encryption A6 - Security Misconfiguration A9 - Insufficient Transport Layer Protection Missing input validation in custom ABAP A1 - Injection 22

Results Network topology is complex Reverse Proxy required Configuration possibilities are great Configuration complexity is our enemy Think about a lot of ICF nodes in combination with individual authority objects Developers!= Administrators Administrators!= Role Administrators Logging deactivated by default Custom Web Services are also affected by Owasp Top 10 23

OWASP Top 10 2010 A1 A2 A3 A4 A5 A6 A7 A8 A9 A10 Injection Cross-Site Scripting (XSS) Broken Authentication and Session Management Insecure Direct Object References Cross-Site Request Forgery (CSRF) Security Misconfiguration Insecure Cryptographic Storage Failure to Restrict URL Access Insufficient Transport Layer Protection Unvalidated Redirects and Forwards 24

OWASP Top 10 2010 A1 Injection A2 Cross-Site Scripting (XSS) A3 Broken Authentication and Session Management A4 Insecure Direct Object References A5 Cross-Site Request Forgery (CSRF) A6 Security Misconfiguration A7 Insecure Cryptographic Storage A8 Failure to Restrict URL Access (partly) A9 Insufficient Transport Layer Protection A10 Unvalidated Redirects and Forwards 25

Questions... Thank you for your attention...???? 26

Literature SAP NetWeaver Security Guide (click) Sichere ABAP Programmierung, Wiegenstein, Schumacher, Schinzel, Weidemann, Galileo Press http://www.sap-press.de/2037 The Developer s Guide to SAP NetWeaver Security, Martin Raepple, Galileo Press ABAP Cookbook, James Wood, Galileo Press SAP Security and Authorizations, Mario Linkies, Frank Off, Galileo Press ABAP Security Scanner http://www.codeprofilers.com DSAG ERP Security Guide 27

Trademarks SAP AG is the registered trademark holder of SAP, SAP R/3, mysap, ABAP, NetWeaver, and other proprietary terms. 28