Cyber security

TInjA – The Template INJection Analyzer

TInjA is a powerful CLI tool designed to detect and identify template injection vulnerabilities in web applications.

Developed by Hackmanit and Maximilian Hildebrand, it supports 44 of the most relevant template engines across eight programming languages, including Python, Java, JavaScript, and more.

Key Features

  • Automatic Detection and Identification: TInjA automatically detects template injection possibilities and identifies the template engine in use. It supports both server-side template injection (SSTI) and client-side template injection (CSTI) vulnerabilities.
  • Efficient Scanning: The tool uses polyglots to efficiently scan web pages. On average, only five polyglots are needed to detect vulnerabilities and identify the template engine.
  • Customization Options: Users can specify custom headers, cookies, POST parameters, and query parameters for the scan. It also allows routing traffic through a proxy and configuring ratelimiting to manage the number of requests per second.
  • Reporting and Output: TInjA can generate reports in JSONL format, providing detailed insights into the scan results. This feature is useful for tracking and analyzing vulnerabilities across multiple URLs.

TInjA supports a wide range of template engines across different programming languages:

  • .NET: DotLiquid, Fluid, Razor Engine, Scriban
  • Elixir: EEx
  • Go: html/template, text/template
  • Java: Freemarker, Groovy, Thymeleaf, Velocity
  • JavaScript: Angular.js, Dot, EJS, Eta, Handlebars, Hogan.js, Mustache, Nunjucks, Pug, Twig.js, Underscore, Velocity.js, Vue.js
  • PHP: Blade, Latte, Mustache.php, Smarty, Twig
  • Python: Chameleon, Cheetah3, Django, Jinja2, Mako, Pystache, SimpleTemplate Engine, Tornado
  • Ruby: ERB, Erubi, Erubis, Haml, Liquid, Mustache, Slim

TInjA can be installed using prebuilt binaries or by compiling it with Go (version 1.21 or higher). The tool offers flexible usage options, including scanning single URLs, multiple URLs, or URLs provided in a file.

It also supports passing raw HTTP requests and JSONL files for more complex scenarios. TInjA was developed as part of a master’s thesis by Maximilian Hildebrand.

It is part of a broader project that includes the Template Injection Table and the Template Injection Playground, which provide additional resources for understanding and testing template injection vulnerabilities.

TInjA is licensed under the Apache License, Version 2.0, making it freely available for use and modification.

Varshini

Varshini is a Cyber Security expert in Threat Analysis, Vulnerability Assessment, and Research. Passionate about staying ahead of emerging Threats and Technologies.

Recent Posts

Unveiling Offshore Banking And Dark Web Operations via Blockchain Analysis : An OSINT Case Study

In the realm of cybersecurity and financial investigations, blockchain analysis has emerged as a powerful…

2 hours ago

Audits Portfolio : Tools And Functions

In the realm of blockchain and Web3 security, audits play a crucial role in ensuring…

2 hours ago

Local Deep Researcher : Revolutionizing Research With AI-Driven Tools

Local Deep Researcher is a powerful, AI-driven tool designed to assist in deep, iterative research…

2 hours ago

Python Fire : Transforming Python Code Into Command-Line Interfaces

Python Fire is a powerful library that simplifies the process of creating command-line interfaces (CLIs)…

2 hours ago

SMM : From Social Media To System Management Mode

The term "SMM" can refer to two distinct concepts: Social Media Marketing and System Management…

4 hours ago

XrefGen – Advanced Cross-Reference Generator For IDA Pro

XrefGen is an innovative IDAPython script designed to augment IDA Pro's static analysis capabilities by…

6 hours ago