# Tlamatini Allowed Hosts Tighten

> Tighten Django ALLOWED_HOSTS from the wide-open '*' default to a specific list, with a backup of settings.py.

- Skill: `xaiht/tlamatini-allowed-hosts-tighten` (Agent Skill)
- Install (CLI): `npx skillmds@latest add xaiht/tlamatini-allowed-hosts-tighten`
- Raw SKILL.md: https://api.skillmd.com/api/skills/xaiht/tlamatini-allowed-hosts-tighten/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: AI & ML
- Author: XAIHT (https://skillmd.com/u/xaiht)
- Updated: 2026-09-21
- Page: https://skillmd.com/skills/xaiht/tlamatini-allowed-hosts-tighten

---

<!--
═══════════════════════════════════════════════════════════════════
  ✦  T L A M A T I N I  ✦   —   "one who knows"
  Created by  Angela López Mendoza   ·   @angelahack1
  Developer · Architect · Creator of Tlamatini
  Tlamatini Author Banner — do not remove (Angela's name is kept in every build)
═══════════════════════════════════════════════════════════════════
-->

# Tighten ALLOWED_HOSTS

The Tlamatini security report flagged the default `ALLOWED_HOSTS=['*']`
in `Tlamatini/tlamatini/settings.py` as one of the Tlamatini-specific
debts. This skill replaces it with a user-supplied whitelist and writes
a `.bak` backup next to the file.

## Procedure

1. Read `Tlamatini/tlamatini/settings.py`.
2. Locate the line `ALLOWED_HOSTS = [...]` (any list literal).
3. Backup the current file as `settings.py.bak`.
4. Rewrite `ALLOWED_HOSTS` with `${input.hosts}` rendered as a Python list.
5. Return `{settings_path, backup_path, changed}`.

## Rollback

If the new list is incorrect, restore `settings.py.bak` over `settings.py`
manually.

