{"id":92164,"date":"2023-05-31T06:11:00","date_gmt":"2023-05-31T06:11:00","guid":{"rendered":"https:\/\/cloudnewshub.com\/?p=92164"},"modified":"2023-05-31T06:11:00","modified_gmt":"2023-05-31T06:11:00","slug":"security-think-tank-a-brief-history-of-secure-coding","status":"publish","type":"post","link":"https:\/\/cloudnewshub.com\/?p=92164","title":{"rendered":"Security Think Tank: A brief history of (secure) coding"},"content":{"rendered":"<div><img decoding=\"async\" src=\"http:\/\/cloudnewshub.com\/wp-content\/uploads\/2023\/05\/security-think-tank-a-brief-history-of-secure-coding.jpg\" class=\"ff-og-image-inserted\"><\/div>\n<p>With technology progressing at an ever-increasing pace, developers are challenged more than ever to keep <a href=\"https:\/\/www.techtarget.com\/whatis\/definition\/code?_gl=1*1aepy16*_ga*MTY0NTUxNjM4MC4xNjY1NDc4NTg1*_ga_TQKE4GS5P9*MTY4NTUyNTYxNC42MTAuMS4xNjg1NTI2NjcxLjAuMC4w*_ga_RZDF13FDNT*MTY4NTUyNTYxNC4xOTUuMS4xNjg1NTI2NjcxLjAuMC4w*_ga_NLDTRJGG3Y*MTY4NTUyNTYxNC4xOTUuMS4xNjg1NTI2NjcxLjAuMC4w*_ga_H4TNQB84WS*MTY4NTUyNTYxNC4xOTUuMS4xNjg1NTI2NjcxLjAuMC4w*_ga_7FK328ZGNW*MTY4NTUyNTYxNC4xOTQuMS4xNjg1NTI2NjcxLjAuMC4w&amp;_ga=2.253745929.1072062183.1685435913-164551638https:\/\/www.techtarget.com\/whatis\/definition\/code\">code<\/a> secure and mitigate against the ever-increasing cyber security threats. But using examples gathered through more than 20 years of working in the field shows there have always been hurdles to overcome.<\/p>\n<section class=\"section main-article-chapter\" data-menu-title=\"The IBM mainframe\">\n<h3 class=\"section-title\"><i class=\"icon\" data-icon=\"1\"><\/i>The IBM mainframe<\/h3>\n<p>IBM mainframe coding was about writing <a href=\"https:\/\/www.techtarget.com\/searchitoperations\/definition\/COBOL-Common-Business-Oriented-Language\">COBOL<\/a>\/PLI programmes scheduled to run as overnight batch processes to read \/ update large complex hierarchical databases. Resource Access Control Facility (RACF) managed user access to critical resources, with a security model that relied on the <a href=\"https:\/\/www.techtarget.com\/searchsecurity\/definition\/principle-of-least-privilege-POLP\">principle of least privilege<\/a>. Use of an account with the right level of access was essential to prevent job runs stopping or failing because the user account did not have appropriate access to read or write to a branch of the database.<\/p>\n<\/section>\n<section class=\"section main-article-chapter\" data-menu-title=\"Client server\">\n<h3 class=\"section-title\"><i class=\"icon\" data-icon=\"1\"><\/i>Client server<\/h3>\n<p>Next up was front end development using Object Oriented language <a href=\"https:\/\/www.gnu.org\/software\/smalltalk\/\">Smalltalk-80<\/a> to raise purchase orders stored on an IBM DB2 database. With no inbuilt security, Smalltalk promoted encapsulation &#8211; objects encapsulated internal state, and data security was protected by controlling data flow amongst objects. Information flow used a protocol to develop security levels in which objects reside; information could be passed to an object in a more secure level, but not down to one in a less secure level.<\/p>\n<\/section>\n<section class=\"section main-article-chapter\" data-menu-title=\"SAP Dynpro\">\n<h3 class=\"section-title\"><i class=\"icon\" data-icon=\"1\"><\/i>SAP Dynpro<\/h3>\n<p>This was followed with <a href=\"https:\/\/answers.sap.com\/questions\/3069135\/what-is-dynpro-what-are-its-components.html\">SAP Dynpro<\/a> development using ABAP. Transaction codes and authorisation profiles were the order of the day, with developers expected to add the appropriate checks in the code to test whether a user account had the correct authorisation profile to access the application, read \/ write to the database, etc. Getting it wrong saw the end user confronted with \u2018Not Authorised\u2019 prompts &#8211; or given too much access so that their activity was never challenged.&nbsp;<\/p>\n<p>2017 was a watershed moment for companies using SAP <a href=\"https:\/\/www.lexology.com\/library\/detail.aspx?g=544583ef-a0a1-44cc-bcff-b911a14a0cda\">following a high-profile court case<\/a> that raised the concept of indirect access to SAP systems. A single service account (often with SAP_ALL access) was frequently used for all remote access\/remote function calls (RFC), and developers knew the passwords to these accounts. Enterprises swiftly reverted to individual accounts for each application.<\/p>\n<\/section>\n<section class=\"section main-article-chapter\" data-menu-title=\"Web development\">\n<h3 class=\"section-title\"><i class=\"icon\" data-icon=\"1\"><\/i>Web development<\/h3>\n<p>The <a href=\"https:\/\/community.sap.com\/topics\/portal\/enterprise-portal\">SAP Enterprise Portal<\/a> (WebDynpro Java\/Java Server Pages) and <a href=\"https:\/\/help.sap.com\/docs\/SAP_BUSINESSOBJECTS_BUSINESS_INTELLIGENCE_PLATFORM\/2e167338c1b24da9b2a94e68efd79c42\/469e1bad6e041014910aba7db0e91070.html\">SAP Web Application Server<\/a> (WebDynpro ABAP) opened the doors for browser-based development in the SAP environment. Developing and deploying Java code required a locally installed development platform (Eclipse), and developers needed to ensure the codebase was secure, with code repositories stored on secure network drives with restricted access.<\/p>\n<p>Behind the scenes of a web application is complex, and many users will have experienced HTTP error messages. Effective troubleshooting required awareness of architecture and at the network level \u2013 Load Balancers, DNS, port mapping, reverse proxy servers, domain navigation, certificates etc.&nbsp; Using HTTP was often used as a default to make it easier to develop an application, but security was compromised.<\/p>\n<p>Developer best practice should ensure that an HTTPS port is always used for web development, with externally signed certificates and an industry-standard level of encryption.<\/p>\n<\/section>\n<section class=\"section main-article-chapter\" data-menu-title=\"Single Sign-On (SSO) and Multi-Factor Authentication (MFA)\">\n<h3 class=\"section-title\"><i class=\"icon\" data-icon=\"1\"><\/i>Single Sign-On (SSO) and Multi-Factor Authentication (MFA)<\/h3>\n<p>Basic authentication (user ID and password) passed the account and password details as visible parameters in URLs to simulate <a href=\"https:\/\/www.techtarget.com\/searchsecurity\/definition\/single-sign-on\">SSO<\/a>, making it vulnerable to exploitation; the adoption of logon tokens and certificates to enable SSO to applications was therefore a game changer.<\/p>\n<p><a href=\"https:\/\/www.techtarget.com\/searchsecurity\/definition\/Kerberos\">Kerberos<\/a> tokens containing a user\u2019s identity can be used for SSO to an on-premise SAP system, which passes user credentials as a cookie to generate an SAP Logon Ticket for logon to multiple other SAP systems. However, because cookies are vulnerable to exploitation, SAP Assertion Tickets are preferred as they are restricted to the target system only, and are passed as an HTTP header rather than a cookie.<\/p>\n<p>SAML 2.0 has emerged as open standard for web-based authentication and authorisation. The identity provider only issues a logon token once the user\u2019s identity has been confirmed, and this SAML 2.0 token is forwarded to the service provider hosting application. Use of SSL, encryption, restricted token validity etc mitigates against exploit.<\/p>\n<\/section>\n<section class=\"section main-article-chapter\" data-menu-title=\"Mobile and API development\">\n<h3 class=\"section-title\"><i class=\"icon\" data-icon=\"1\"><\/i>Mobile and API development<\/h3>\n<p><a href=\"https:\/\/www.techtarget.com\/searchapparchitecture\/definition\/application-program-interface-API\">API<\/a> development means securely transferring packages of data between systems either via system-to-system RFC or webservices, and often through additional middleware or service mediation layers.<\/p>\n<p>It requires an understanding the full journey of API, often with data packets that are transformed from the source system to a different format that can be received by the destination, as well as the identity tokens exchange such as SAML 2.0 to OAuth 2.0.<\/p>\n<p>For <a href=\"https:\/\/www.techtarget.com\/searchapparchitecture\/definition\/RESTful-API\">REST<\/a> (one of the most common webservices) development, OAuth 2.0 uses scopes to allow an application to access resource on other systems via web API.&nbsp; A scope limits user access to applications so good design of scopes as part of the authorisation model is essential to ensure the right access level.<\/p>\n<\/section>\n<section class=\"section main-article-chapter\" data-menu-title=\"Browser compliance and cross-device\">\n<h3 class=\"section-title\"><i class=\"icon\" data-icon=\"1\"><\/i>Browser compliance and cross-device<\/h3>\n<p>The latest browsers have ever-increasing security safeguards to mitigate against cyber security threats. Companies relying on browser emulation mode (i.e. emulating legacy releases such as IE 5) find that web applications that have run for years stop working in modern browsers such as Chromium or Edge Chromium, with unplanned development work required to secure code.<\/p>\n<p>Mobile development adds another element with offline data stored on-device, which enables an application to continue where it left off if a network connection is lost. \u2018Offline OData\u2019 and similar techniques for achieving this require developers to ensure only the minimum amount of data is stored on-device (to keep the process as secure as possible), and to manage the \u2018sync point\u2019 so that once a connection is restored data can be uploaded \/ synched securely back to its source.<\/p>\n<\/section>\n<section class=\"section main-article-chapter\" data-menu-title=\"Continuous integration\/delivery\/deployment\">\n<h3 class=\"section-title\"><i class=\"icon\" data-icon=\"1\"><\/i>Continuous integration\/delivery\/deployment<\/h3>\n<p>Enterprises strive for \u2019agile project\u2019 delivery which enables faster development lifecycle times without compromising on quality or security. The automation of the DevOps lifecycle (via continuous integration, delivery and deployment pipelines for code peer reviews, builds, deployment, testing, approvals, development to production migration lifecycles) triggers the moment the developer checks code into a code repository.<\/p>\n<p>Code scan tools such as <a href=\"https:\/\/onapsis.com\/\">Onapsis<\/a> and <a href=\"https:\/\/www.sonarsource.com\/products\/sonarqube\/\">SonarQube<\/a> can be integrated as part of a DevSecOps pipeline to scan code for secure coding best practices, flagging vulnerabilities across diverse code bases from ABAP to XML.<\/p>\n<p>However, there are pitfalls. Often the code scans are optimised to the latest code version and a line of legacy code can be flagged as a risk. To avoid large numbers of false positives, thresholds need to be configured to ignore or set a warning for code that is secure but written using an obsolete technique. The alerts will help to evolve better coding standards across development teams to minimise DevSecOps breaches.<\/p>\n<\/section>\n<section class=\"section main-article-chapter\" data-menu-title=\"More of the same\">\n<h3 class=\"section-title\"><i class=\"icon\" data-icon=\"1\"><\/i>More of the same<\/h3>\n<p>Keeping coding secure has always presented challenges. Most of these have been overcome with a combination of technology and human expertise \u2013 a model that should be continued.<\/p>\n<\/section>\n","protected":false},"excerpt":{"rendered":"<p>With technology progressing at an ever-increasing pace, developers are challenged more than ever to keep code secure and mitigate against the ever-increasing cyber security threats. But using examples gathered through more than 20 years of working in the field shows there have always been hurdles to overcome. The IBM mainframe IBM mainframe coding was about [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":92165,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[533],"tags":[],"class_list":["post-92164","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-it"],"_links":{"self":[{"href":"https:\/\/cloudnewshub.com\/index.php?rest_route=\/wp\/v2\/posts\/92164","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/cloudnewshub.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/cloudnewshub.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/cloudnewshub.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/cloudnewshub.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=92164"}],"version-history":[{"count":0,"href":"https:\/\/cloudnewshub.com\/index.php?rest_route=\/wp\/v2\/posts\/92164\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/cloudnewshub.com\/index.php?rest_route=\/wp\/v2\/media\/92165"}],"wp:attachment":[{"href":"https:\/\/cloudnewshub.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=92164"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/cloudnewshub.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=92164"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/cloudnewshub.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=92164"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}