# Introduction

> Fork of [Anubis](https://github.com/0sir1ss/Anubis) originally created by [0sir1ss](https://github.com/0sir1ss).

Anubis is a Python source-code obfuscator with multiple protection layers. It transforms readable Python scripts into hardened outputs that are difficult to reverse-engineer, without changing what the code does at runtime.

## Protection layers

| Layer                                                    | What it does                                                     |
| -------------------------------------------------------- | ---------------------------------------------------------------- |
| [Flatten Control Flow](/anubis/features/flatten.md)      | Rewrites function bodies as `while True` state machines          |
| [Opaque Predicates](/anubis/features/opaque.md)          | Wraps functions in always-true guards with dead branches         |
| [XOR String Encryption](/anubis/features/xor-strings.md) | Encrypts string literals with a random key                       |
| [Constant Blinding](/anubis/features/blind.md)           | Hides integer literals: `N` → `(N^R)^R`                          |
| [Dynamic Imports](/anubis/features/dynamic-imports.md)   | Replaces `import X` with XOR-encoded `__import__()` calls        |
| [Semantic Noise](/anubis/features/semantic-noise.md)     | Renames identifiers to misleading English names (LLM resistance) |
| [Carbon](/anubis/features/carbon.md)                     | Renames every identifier to random `I`/`l` strings               |
| [Junk Code](/anubis/features/junk-code.md)               | Wraps code in unreachable class definitions                      |
| [Mix Strings](/anubis/features/mix-strings.md)           | Replaces string literals with `chr()` chains                     |
| [Big Script](/anubis/features/big-script.md)             | Inflates output with \~256 KB of random dead-code blobs          |
| [Anti-Debug](/anubis/features/anti-debug.md)             | Kills known debugger processes at runtime                        |
| [Import Alias](/anubis/features/import-alias.md)         | Obfuscates imported module names                                 |
| [AES Encrypt](/anubis/features/encrypt.md)               | Encrypts source into a self-decrypting one-liner                 |
| [RFT](/anubis/features/rft.md)                           | Encodes entire source as `zlib+base64` and `exec()`s it          |
| [BCC](/anubis/features/bcc.md)                           | Compiles to bytecode, wraps in a marshal loader stub             |

## Quick start

```bash
pip install git+https://github.com/GRodolphe/Anubis.git
anubis script.py --flatten --opaque --carbon --xor-strings --blind --bcc
```

See [Installation](/anubis/installation.md) for full setup options.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://rodolphes-organization.gitbook.io/anubis/readme.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
