Skip to content
KitploitKITPLOIT
OutilsExploitsBlog
Log in
Soumettre
OutilsExploitsBlog
Soumettre

Outils de Hacking, PenTest et Cybersécurité pour votre Arsenal de Sécurité !

Kitploit est un répertoire d'outils de hacking, de cybersécurité et de pentesting. Découvrez les dernières mises à jour des projets pour trouver des vulnérabilités, analyser des systèmes, automatiser les tests et renforcer votre sécurité.

FluxContactConfidentialité© 2026 Kitploit

Répertoire d'outils

Catégories

Voir toutes les catégories
Loading categories
Outils/GitHubGitHub/federiconbaez/cortex9-filelock-sqlite-symlink-follow-model
Static AnalysisVulnerability AnalysisCode AnalysisExploitationBinary AnalysisPapers & ResearchLearning & EducationLabs & Practice
GitHub
federiconbaez/cortex9-filelock-sqlite-symlink-follow-model

cortex9-filelock-sqlite-symlink-follow-model

Offline educational model of CVE-2026-112936 (filelock SQLite symlink follow)

Voir le dépôt
il y a 16 joursPas encore vérifié

Populaires

Voir tout →

Découvrez les outils les plus utilisés par notre communauté.

  • 1

    ghostlock-app

    yukonga/ghostlock-app

    # Application d'exécution en un clic GhostLock (CVE-2026-43499)

    972
  • 2

    OsintHunter

    letox4/osinthunter

    🎯 La boîte à outils OSINT ultime : graphe d'enquête, notation de confiance, familles d'alias, carte, chronologie et rapports. 49 modules, plus de 400 sites, aucune clé API requise.

    830
  • 3

    wifit3

    derv82/wifit3

    Wifite mais uniquement USB et multiplateforme.

    714
  • 4

    jumpserver

    jumpserver/jumpserver

    JumpServer est une plateforme open-source de Gestion des Accès Privilégiés (PAM) qui offre aux équipes DevOps et IT un accès sécurisé et à la demande aux terminaux SSH, RDP, Kubernetes, bases de données et RemoteApp via un navigateur web.

    477
  • 5

    SafeLine

    chaitin/safeline

    WAF auto-hébergé et proxy inverse qui filtre le trafic HTTP malveillant, bloque les injections SQL, les XSS et les attaques de robots, avec limitation de débit et chiffrement dynamique HTML/JS.

    429
  • 6

    CyberStrikeAI

    ed1s0nz/cyberstrikeai

    Le système d'action pour la cybersécurité native IA—où l'intention devient une exécution gouvernée, les preuves deviennent une mémoire opérationnelle, et chaque opération améliore la suivante.

    398

Explorer tous les outils

Parcourez notre collection d'outils

Voir tous les outils →
Partager
Contenu non disponible dans la langue demandée. Affichage de la version anglaise.

cortex9-filelock-sqlite-symlink-follow-model

Local lab for CVE-2026-112936 (GHSA-j8f7-rjxc-mr56): filelock's ReadWriteLock keyed its instances by Path(lock_file).resolve() and let sqlite3.connect() open the lock path, so a symlink planted at that path was followed: the process created or locked the file the link pointed to, and repointing the link gave two processes "the" write lock on different files. The fix, commit 4d45e83caf7e (filelock 4.0.9), opens the path with O_NOFOLLOW | O_NONBLOCK, refuses anything that is not a regular file, resolves only the parent for the key and connects SQLite through /proc/self/fd/N. Educational, deterministic, C11 checked with ASan/UBSan. No SQLite, no filelock, no network, no other user. Each case builds its own names inside a fresh mkdtemp() sandbox, runs the two opens with real syscalls and removes the sandbox; the output is labels and sandbox-relative keys only.

Spanish: README.es.md. Exercises: PRACTICE.md.

What is modelled (tied to the diff, src/filelock/_read_write.py)

Diff lineCodeLab
old 212, old 309pathlib.Path(lock_file).resolve()pre key: fl_resolve (non-strict, follows links)
new 224-225, new 322pathlib.Path(_canonical(lock_file)), "resolve only the parent"post key: fl_canonical (parent resolved, name kept)
old 740-746sqlite3.connect(database, ...)pre open: open(name, O_RDWR|O_CREAT|O_NONBLOCK) stand-in
new 54-55_DB_OPEN_FLAGS = O_RDWR|O_CREAT|O_NOFOLLOW|O_NONBLOCKpost open flags, mode 0600 (new 775)
new 776-779if not S_ISREG(os.fstat(fd).st_mode): close, "refusing a non-regular lock database"REFUSED_NONREG
new 753-765, 59hold the fd; target = f"{_FD_DIR}/{fd}" (/proc/self/fd on Linux)reopen action

The GHSA says SQLite's VFS resolves the final symlink in user space, so fs.protected_symlinks and the sticky bit do not stop it; the lab's pre stand-in lets the kernel follow the link instead, which gives the same result in a single-user sandbox. _canonical lives in _api.py, outside the diff: only its comment ("resolve only the parent") is modelled.

Differential evidence (results/)

At the lock pathprepost
symlink to private/pwned.flag (missing), also through a chainFOLLOWED_CREATED, a new file outside the lock pathREFUSED_SYMLINK, nothing created
symlink to an existing file (absolute or relative)FOLLOWED_EXISTING, key = the targetREFUSED_SYMLINK, key = the link
symlink to a FIFO / a directory / itself / a missing directoryOPENED_NONREG / ERR_EISDIR / ERR_ELOOP / ERR_ENOENTREFUSED_SYMLINK
FIFOOPENED_NONREGREFUSED_NONREG
link repointed between two opens (GHSA PoC step 3)EXCLUSION_BROKEN, keys S/a.db and S/b.dbREFUSED
link replaced after validation, then connectREOPEN_FOLLOWED (the name is opened again)REOPEN_SAME_INODE (/proc/self/fd/N)
regular file, missing name, directory, symlinked parent, hard linksame in bothsame in both

results/sweep.csv crosses 13 kinds of object at the lock path. On 400 random setups the tests check that post never creates a name outside the lock path, always refuses a final symlink, and that without a final symlink both versions agree except for non-regular files.

Two cases are observations of the lab, not findings: a hard link at the path (c13) is opened by both versions (O_NOFOLLOW is about symlinks; fs.protected_hardlinks is not modelled), and renaming the lock file away and creating a new one between two opens (s04) splits the inode in both versions; doing that to another user's file in a sticky directory needs rights the lab does not model.

Run

sh scripts/build.sh test              # -Wall -Wextra -Werror, ASan + UBSan
python3 scripts/derive_expected.py | diff - fixtures/expected.tsv
sh scripts/build.sh results /tmp/r && diff -r results /tmp/r
./build/fllab case pre 'F:a.db;L:lock.db>a.db' 'open:lock.db'

fixtures/cases.tsv holds positive, negative, edge and out-of-domain cases with labels derived by hand. fixtures/expected.tsv comes from scripts/derive_expected.py, which runs the same scenarios with Python's os module in its own sandbox and computes the pre key with pathlib's real resolve(); the C tests compare labels and keys against both.

A model is not a finding: see LIMITATIONS.md and SOURCES.md. License: Apache-2.0.

Télécharger l’outil