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

Playwright-MCP : A Powerful Tool For Browser Automation

Playwright-MCP (Model Context Protocol) is a cutting-edge tool designed to bridge the gap between AI…

2 weeks ago

JBDev : A Tool For Jailbreak And TrollStore Development

JBDev is a specialized development tool designed to streamline the creation and debugging of jailbreak…

2 weeks ago

Kereva LLM Code Scanner : A Revolutionary Tool For Python Applications Using LLMs

The Kereva LLM Code Scanner is an innovative static analysis tool tailored for Python applications…

2 weeks ago

Nuclei-Templates-Labs : A Hands-On Security Testing Playground

Nuclei-Templates-Labs is a dynamic and comprehensive repository designed for security researchers, learners, and organizations to…

2 weeks ago

SSH-Stealer : The Stealthy Threat Of Advanced Credential Theft

SSH-Stealer and RunAs-Stealer are malicious tools designed to stealthily harvest SSH credentials, enabling attackers to…

2 weeks ago

ollvm-unflattener : A Tool For Reversing Control Flow Flattening In OLLVM

Control flow flattening is a common obfuscation technique used by OLLVM (Obfuscator-LLVM) to transform executable…

2 weeks ago