Browsed by
Month: August 2020

10. Same-Origin Policy and Cross-Origin Resource Sharing

10. Same-Origin Policy and Cross-Origin Resource Sharing

1. SAME-ORIGIN POLICY INTRODUCED Same-Origin Policy (SOP) is a major security concept that is built-in in all contemporary browsers. Its main goal is to prevent access attempts of dynamic web page elements (like scripts) to data on resources of a different origin.In the security context, SOP prevents malicious web sites from retrieving confidential data from restricted locations on behalf of users and without their acknowledgment.User agents that are compliant with SOP, restrict requests issued from one origin to another origin….

Read More Read More

9. Front End Security Basics: Secure Cookie Flag

9. Front End Security Basics: Secure Cookie Flag

1. VULNERABILITY INTRODUCED Properly implemented data protection is an essential component of the security of any web application. It allows the users to know who they are communicating with, whether or not their communication channel is encrypted, and that the data is not manipulated in transit. Applications frequently fail to authenticate, encrypt, and protect the confidentiality and integrity of sensitive data transmitted through the network. For example, when HTTP protocol is used, the traffic (including cookies) is sent in plain…

Read More Read More

8. Front End Security Basics: DOM XSS in AJAX

8. Front End Security Basics: DOM XSS in AJAX

1. VULNERABILITY INTRODUCED When an HTML page is rendered in browsers, the browser downloads the HTML into local memory and automatically parses it to display the page on the screen. When a web page is loaded, the browser creates a Document Object Model (DOM) of the page, which is an object-oriented representation of an HTML document, that acts as an interface between JavaScript and the document itself and allows the creation of dynamic web pages. So, the objects in the…

Read More Read More

7. Front End Security Basics: DOM XSS in URL

7. Front End Security Basics: DOM XSS in URL

1. VULNERABILITY INTRODUCED When an HTML page is rendered in browsers, the browser downloads the HTML into local memory and automatically parses it to display the page on the screen. When a web page is loaded, the browser creates a Document Object Model (DOM) of the page, which is an object-oriented representation of an HTML document, that acts as an interface between JavaScript and the document itself and allows the creation of dynamic web pages. So, the objects in the…

Read More Read More

6. Front End Security Basics: Components With known vulnerabilities

6. Front End Security Basics: Components With known vulnerabilities

1. VULNERABILITY INTRODUCED When development teams use component-heavy development patterns, they sometimes do not even understand which components they use in their applications much less keeping them up to date.Developers often do not know: The versions of all components they use (both client-side and server-side); If the software they use (OS, web/application server, database management systems, run-time environments, and libraries) is vulnerable, unsupported, or out of date; If the underlying platform, frameworks, and dependencies are fixed or upgraded in a…

Read More Read More

5. Front End Security Basics: Cross Site Request Forgery

5. Front End Security Basics: Cross Site Request Forgery

1. EXERCISE BACKGROUND The vulnerable application pane loads the TraderDASH application. In this application, a user is able to quickly buy and sell stocks with a single-click order execution. It has also a quite ordinary profile for managing user details. ACTION Click My Account -> My profile link to open the profile page. 2. CHANGE EMAIL FUNCTIONALITY Bob is an attacker. While he was browsing the Web, he came across the TraderDASH application. Since registration was free and accessible, Bob…

Read More Read More

4. Front End Security Basics: Clickjacking

4. Front End Security Basics: Clickjacking

1. VULNERABILITY EXPLAINED Clickjacking attacks occur when a page, particularly one with clickable elements, can be placed inside a frame.An attacking website frames the victim website and redresses it in a manner that it becomes not visible to the victim.For example, if a website’s profile page has a Delete Account button, an attacker can place an iframe that centers on that button, while placing a fake ad in the topmost page, with a fake X button to close the ad…

Read More Read More

3. Front End Security Basics: No Server-Side Validation

3. Front End Security Basics: No Server-Side Validation

1. VULNERABILITY INTRODUCED Sometimes front-end developers get mesmerized by the validation word in the client-side validation term and implicitly assume that it refers to protection of some kind that operates on the client-side level. Also, they assume that properly implemented client-side validation will not allow hackers to pass any kind of malicious input to the server, and therefore there is no need to duplicate the same validation on the server level.But when the server doesn’t use the same protection schemes…

Read More Read More

2. Frond End Security Basics: HTTP Strict-Transport-Security (HSTS)

2. Frond End Security Basics: HTTP Strict-Transport-Security (HSTS)

1. VULNERABILITY INTRODUCED Properly implemented data protection for a web application allows the users to know who they are communicating with, whether or not their communication channel is encrypted, and that the data is not manipulated in transit. This is usually achieved by using HTTPS protocol for communication between the user and the web application.But sometimes applications accept connections through HTTP first, upgrade to HTTPS and redirect the user to HTTPS version of the application. Thus the application first allows…

Read More Read More

1. Front End Security Basics: Reverse Tabnabbing

1. Front End Security Basics: Reverse Tabnabbing

1. VULNERABILITY INTRODUCED A web-page may use multiple methods to open additional tabs or windows. However, these methods may often add a reference to the opener (or window.opener) object in the newly opened window, which refers to the “parent” tab or window. While most attributes in the opener window are blocked and inaccessible to the opened window, such that the opened window may not refer to most opener attributes (part of the cross-domain policy), some are not blocked. In particular,…

Read More Read More