implementing-memory-protection-with-dep-aslr
Qué hace
Esta herramienta te ayuda a proteger tu equipo frente a ataques que intentan aprovechar fallos de seguridad en la memoria. Activa defensas como DEP y ASLR para evitar que programas maliciosos ejecuten código no deseado.
Cuándo usarla
- ✓Al reforzar la seguridad de tu equipo frente a intrusiones.
- ✓Cuando necesitas impedir que los programas ejecuten código no autorizado.
- ✓Para proteger aplicaciones sensibles contra ataques conocidos.
Link de la skill
https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/implementing-memory-protection-with-dep-aslr/SKILL.mdCópialo y pégalo en tu IA (Claude, ChatGPT o Cursor) pidiéndole que siga las instrucciones.
Cómo usar
La forma más fácil: copia el mensaje y pégalo en tu IA. Ella lee la skill y sigue las instrucciones.
Mensaje listo para pegar
Para Claude Code, Codex o Cursor: ejecútalo en la carpeta del proyecto y la skill queda instalada.
Descarga el SKILL.md y ponlo en la carpeta de skills de tu agente.
Ejemplo de qué pedirle a la IA
“Activa las protecciones de memoria DEP y ASLR en mi sistema.”
5 skills nuevas por semana. 1 minuto de lectura.
Cómo funciona
La herramienta configura Windows para marcar las zonas de memoria como no ejecutables (DEP) y para aleatorizar las direcciones de memoria (ASLR). Así es más difícil que el código malicioso se ejecute y aproveche las vulnerabilidades.
Contenido técnico (SKILL.md original)
Texto original del autor, en inglés, directo de GitHub.
Implementing Memory Protection with DEP and ASLR
When to Use
Use this skill when hardening endpoints against memory-based exploits by configuring DEP, ASLR, CFG, and Windows Exploit Protection system-wide and per-application mitigations.
Prerequisites
- Windows 10/11 or Windows Server 2016+ with administrative privileges
- Group Policy management access for enterprise-wide deployment
- Understanding of memory corruption attack techniques (buffer overflow, ROP chains)
- Test environment for validating application compatibility with exploit mitigations
Workflow
Step 1: Configure System-Level Mitigations
# Enable system-wide DEP (Data Execution Prevention)
# Boot configuration: OptIn (default), OptOut (recommended), AlwaysOn
bcdedit /set nx AlwaysOn
# Verify ASLR status (enabled by default on modern Windows)
Get-ProcessMitigation -System
# MandatoryASLR, BottomUpASLR, HighEntropyASLR should be ON
# Enable all system-level mitigations
Set-ProcessMitigation -System -Enable DEP,SEHOP,ForceRelocateImages,BottomUp,HighEntropy
Step 2: Configure Per-Application Mitigations
# Harden high-risk applications (browsers, Office, PDF readers)
Set-ProcessMitigation -Name "WINWORD.EXE" -Enable DEP,SEHOP,ForceRelocateImages,CFG,StrictHandle
Set-ProcessMitigation -Name "EXCEL.EXE" -Enable DEP,SEHOP,ForceRelocateImages,CFG,StrictHandle
Set-ProcessMitigation -Name "AcroRd32.exe" -Enable DEP,SEHOP,ForceRelocateImages,CFG
Set-ProcessMitigation -Name "chrome.exe" -Enable DEP,CFG,ForceRelocateImages
Set-ProcessMitigation -Name "msedge.exe" -Enable DEP,CFG,ForceRelocateImages
# Export configuration for deployment
Get-ProcessMitigation -RegistryConfigFilePath "C:\exploit_protection.xml"
# Deploy via Intune or GPO
Step 3: Deploy via Intune/GPO
Intune: Endpoint Security → Attack Surface Reduction → Exploit Protection
Import exploit_protection.xml template
GPO: Computer Configuration → Admin Templates → Windows Components
→ Windows Defender Exploit Guard → Exploit Protection
→ "Use a common set of exploit protection settings" → Enabled
→ Point to XML file on network share
Key Concepts
| Term | Definition |
|---|---|
| DEP | Marks memory pages as non-executable to prevent shellcode execution in data regions |
| ASLR | Randomizes memory addresses of loaded modules to defeat hardcoded ROP gadgets |
| CFG | Validates indirect call targets at runtime to prevent control flow hijacking |
| SEHOP | Validates SEH chain integrity to prevent SEH-based exploitation |
Tools & Systems
- Windows Exploit Protection: Built-in per-process mitigation management
- EMET (legacy): Enhanced Mitigation Experience Toolkit (predecessor, now deprecated)
- ProcessMitigations PowerShell: Get/Set-ProcessMitigation cmdlets
Common Pitfalls
- DEP compatibility: Legacy 32-bit applications may crash with DEP AlwaysOn. Use OptOut with exceptions.
- Mandatory ASLR breaking apps: Some applications are not ASLR-compatible. Test before enforcing ForceRelocateImages.
- CFG limited to compiled-in support: CFG only works for applications compiled with /guard:cf. Cannot be retroactively applied.
Preguntas frecuentes
¿Qué es DEP?
DEP (Data Execution Prevention, o prevención de ejecución de datos) impide que se ejecute código en zonas de memoria que solo deberían contener datos, como en los ataques de desbordamiento de búfer.
¿Qué es ASLR?
ASLR (Address Space Layout Randomization, o aleatorización de la disposición del espacio de direcciones) cambia las direcciones de memoria de los programas cada vez que se ejecutan, así que es más difícil que un atacante sepa dónde buscar el código malicioso.
¿Puedo usarlo en cualquier equipo?
Requiere Windows 10/11 o Windows Server 2016 o posterior, y necesitas privilegios de administrador para hacer la configuración.
Detalles
Descripción original del autor
Implements memory protection mechanisms including DEP (Data Execution Prevention), ASLR (Address Space Layout Randomization), CFG (Control Flow Guard), and other exploit mitigations to prevent memory corruption attacks. Use when hardening endpoints against buffer overflow exploits, ROP chains, and code injection. Activates for requests involving memory protection, exploit mitigation, DEP, ASLR, or
Popularidad
- Estrellas en GitHub
- 35 mil
- Posición en el ranking
- #8071
- Licencia
- Apache-2.0
- Actualizada
- 31/8/2026
Comentarios
- …
Más skills de este repositorio
abusing-dpapi-for-credential-access
35 milDa a tu agente de IA instrucciones listas para una tarea específica, para que la haga mejor y más rápido.
abusing-shadow-credentials-for-privesc
35 milEnseña a tu agente de IA a escribir textos claros y bien estructurados.
achieving-cmmc-level-2-compliance
35 milAyuda a tu agente a preparar un entorno para el cumplimiento de CMMC Nivel 2. Implementa los requisitos de seguridad y gestiona la documentación necesaria.
acquiring-disk-image-with-dd-and-dcfldd
35 milAyuda a tu agente a crear copias exactas de discos duros. Es útil para asegurar que no se pierda ni altere información durante las investigaciones.
Skills parecidas
reverse-engineer-anything
422 milAyuda a tu agente a revisar apps y paquetes ya publicados para explicar sus funciones, comparar versiones o guiar una reconstrucción, usando la herramienta REA.
1password
394 milAyuda a tu agente a instalar la CLI de 1Password, iniciar sesión y leer o inyectar secretos sin imprimir sus valores en el chat.
healthcheck
394 milAyuda a tu agente a auditar el ordenador o servidor que ejecuta OpenClaw en busca de riesgos de seguridad, como SSH, cortafuegos, actualizaciones y copias de seguridad, y después sugerir arreglos seguros.