summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorache <ache@ache.one>2025-07-23 19:28:27 +0200
committerache <ache@ache.one>2025-07-23 19:28:27 +0200
commit1211558e208a902cd18ed31dde9d60da6e779f1a (patch)
tree4d4357090eacdd8927153e5c7c4b9db7192f96cd
parentFix a link (diff)
Fix various
-rw-r--r--notes/html_zip_bomb.md6
-rw-r--r--notes/zip_bombe_html.md6
2 files changed, 6 insertions, 6 deletions
diff --git a/notes/html_zip_bomb.md b/notes/html_zip_bomb.md
index 6151240..17b78da 100644
--- a/notes/html_zip_bomb.md
+++ b/notes/html_zip_bomb.md
@@ -55,7 +55,7 @@ First, since it's an HTML page, we start with the HTML5 doctype.
Then we try to fit the 10 MB of identical characters.
I first attempted to use [HTML classes, which can contain anything](https://shkspr.mobi/blog/2025/05/decorative-text-within-html/), but quickly the HTML comment solution seemed most practical.
-So, I set up a small shell script (in fish) to create an HTML file with a 10 MB 'H' comment.
+So, I set up a small shell script (in [fish](https://fishshell.com/)) to create an HTML file with a 10 MB 'H' comment.
```bash
#!/bin/fish
@@ -136,11 +136,11 @@ Disallow: /bomb.html
## Results
-Firefox struggles a lot and ends up crashing cleanly with an NS_ERROR_OUT_OF_MEMORY error, visible only in the developer tools.
+Firefox struggles a lot and ends up crashing cleanly with an `NS_ERROR_OUT_OF_MEMORY` error, visible only in the developer tools.
If I put the body tag before the malicious comment, I would certainly have a correctly displayed page.
Chrome is much faster to crash!
-It offers a joyous screen signaling that an error occurred via SIGKILL.
+It offers a happy screen signaling that an error occurred via `SIGKILL`.
In both cases, we notice that the page is partially loaded; however, the title is correct.
Therefore, we are certain that a Selenium-type web crawler will crash on this HTML file.
diff --git a/notes/zip_bombe_html.md b/notes/zip_bombe_html.md
index f816123..8a69ef5 100644
--- a/notes/zip_bombe_html.md
+++ b/notes/zip_bombe_html.md
@@ -56,7 +56,7 @@ Puis ensuite, on essaie de caser les 10 Mio de caractères identiques.
J'ai d'abord tenté d'utiliser [les classes HTML qui peuvent contenir n'importe quoi](https://shkspr.mobi/blog/2025/05/decorative-text-within-html/), mais rapidement la solution du commentaire HTML m'a semblé la plus pratique.
-Alors j'ai mis en place un petit script shell (en fish) pour créer un fichier HTML avec un commentaire de 10 MiB de 'H'.
+Alors j'ai mis en place un petit script shell (en [fish](https://fishshell.com/)) pour créer un fichier HTML avec un commentaire de 10 MiB de 'H'.
```bash
#!/bin/fish
@@ -96,7 +96,7 @@ Idéalement, on ne veut même pas avoir le fichier de 10 Gio sur le serveur.
Pour cela, on utilise le module `ngx_http_gzip_static_module` [^gzip_static_nginx].
-```text
+```nginxconf
location = /bomb.html {
gzip on; # Normalement ça devrait être le module gzip à la volé. 🤷
gzip_static on;
@@ -141,7 +141,7 @@ Firefox rame beaucoup et finit par planter proprement avec une erreur `NS_ERROR_
Si je mets la balise body avant le commentaire malicieux, j'aurais certainement une page correctement affichée.
Chrome est bien plus rapide à planter !
-Il offre un joyeux écran qui signale qu'une erreur s'est produite par un SIGKILL.
+Il offre un joyeux écran qui signale qu'une erreur s'est produite par un `SIGKILL`.
Dans les deux cas, on remarque que la page est partiellement chargée cependant, le titre est correct.
On est donc sûr et certain qu'un web crawler type Selenium va planter sur ce fichier HTML.