Naouel Moha

117 papers A* 3A 20B 5C 4Misc 4Journal 48Unranked 29
YearRankTypeTitle / Venue / Authors
2026 J jnl
Internet Things
Yahia El Fellah, Jean Baptiste Minani, Naouel Moha, Julien Gascon-Samson, Yann-Gaël Guéhéneuc
2026 J jnl
CoRR
Hadil Ben Amor, Niruthiha Selvanayagam, Manel Abdellatif, Taher A. Ghaleb, Naouel Moha
2025 conf
ICSOC (1)
Hakim Ghlissi, Mohamed El Hadi Boukhatem, Manel Abdellatif, Naouel Moha
2025 J jnl
CoRR
Imen Trabelsi, Brahim Mahmoudi, Jean Baptiste Minani, Naouel Moha, Yann-Gaël Guéhéneuc
2025 J jnl
IEEE Trans. Software Eng.
Imen Trabelsi, Brahim Mahmoudi, Jean Baptiste Minani, Naouel Moha, Yann-Gaël Guéhéneuc
2025 J jnl
Internet Things
Nour Khezemi, Sikandar Ejaz, Naouel Moha, Yann-Gaël Guéhéneuc
2025 J jnl
CoRR
Brahim Mahmoudi, Naouel Moha, Quentin Stievenert, Florent Avellaneda
2025 J jnl
CoRR
Houcine Abdelkader Cherief, Brahim Mahmoudi, Zacharie Chenail-Larcher, Naouel Moha, Quentin Stievenert, Florent Avellaneda
2025 J jnl
IEEE Trans. Software Eng.
Manel Abdellatif, Naouel Moha, Yann-Gaël Guéhéneuc, Hafedh Mili, Ghizlane El-Boussaidi
2025 J jnl
J. Syst. Softw.
Jean Baptiste Minani, Yahia El Fellah, Fatima Sabir, Naouel Moha, Yann-Gaël Guéhéneuc, Martin Kuradusenge, Tomoaki Masuda
2025 J jnl
CoRR
Brahim Mahmoudi, Zacharie Chenail-Larcher, Naouel Moha, Quentin Stiévenart, Florent Avellaneda
2025 J jnl
IEEE Internet Things J.
Jean Baptiste Minani, Fatima Sabir, Naouel Moha, Yann-Gaël Guéhéneuc, Tomoaki Masuda
2025 A conf
ICST
Zacharie Chenail-Larcher, Jean Baptiste Minani, Naouel Moha
2024 J jnl
IEEE Internet Things J.
Jean Baptiste Minani, Fatima Sabir, Naouel Moha, Yann-Gaël Guéhéneuc
2024 J jnl
IEEE Internet Things J.
Nour Khezemi, Jean Baptiste Minani, Fatima Sabir, Naouel Moha, Yann-Gaël Guéhéneuc, Ghizlane El-Boussaidi
2024 J jnl
IEEE Trans. Software Eng.
Jean Baptiste Minani, Fatima Sabir, Naouel Moha, Yann-Gaël Guéhéneuc
2024 conf
CIoT
Jean Baptiste Minani, Yahia El Fellah, Sanam Ahmed, Fatima Sabir, Naouel Moha, Yann-Gaël Guéhéneuc
2024 conf
ICSOC (2)
Brahim Mahmoudi, Imen Trabelsi, Dalila Tamzalit, Naouel Moha, Yann-Gaël Guéhéneuc
2024 J jnl
CoRR
Nour Khezemi, Sikandar Ejaz, Naouel Moha, Yann-Gaël Guéhéneuc
2024 J jnl
Empir. Softw. Eng.
Hocine Rebatchi, Tegawendé F. Bissyandé, Naouel Moha
2024 J jnl
IEEE Trans. Software Eng.
Dimitri Prestat, Naouel Moha, Roger Villemaire, Florent Avellaneda
2024 conf
ICSOC Workshops (1)
Imen Trabelsi, Naouel Moha, Yann-Gaël Guéhéneuc
2024 A conf
ICSA
Imen Trabelsi, Naouel Moha, Yann-Gaël Guéhéneuc, Lucas Geffard
2024 conf
SERP4IoT
Imen Trabelsi, Bianca Popa, Jérémie Péreyrol, Pier-Olivier Beaulieu, Naouel Moha
2024 conf
SERP4IoT
Jean Baptiste Minani, Fatima Sabir, Yahia El Fellah, Naouel Moha
2024 ed.
ICSOC Workshops
Flavia Monti, Pierluigi Plebani, Naouel Moha, Hye-Young Paik, Johanna Barzen, Gowri Sankar Ramachandran, Devis Bianchini, Damian A. Tamburri, Massimo Mecella
2024 conf
SERP4IoT
Jean Baptiste Minani, Yahia El Fellah, Fatima Sabir, Naouel Moha
2023 J jnl
J. Softw. Evol. Process.
Imen Trabelsi, Manel Abdellatif, Abdalgader Abubaker, Naouel Moha, Sébastien Mosser, Samira Ebrahimi Kahou, Yann-Gaël Guéhéneuc
2023 J jnl
J. Syst. Softw.
Rafik Tighilt, Manel Abdellatif, Imen Trabelsi, Loïc Madern, Naouel Moha, Yann-Gaël Guéhéneuc
2022 J jnl
IEEE Trans. Software Eng.
Fatima Sabir, Yann-Gaël Guéhéneuc, Francis Palma, Naouel Moha, Ghulam Rasool, Hassan Akhtar
2022 J jnl
Empir. Softw. Eng.
Dimitri Prestat, Naouel Moha, Roger Villemaire
2022 B ed.
ICSR
Gilles Perrouin, Naouel Moha, Abdelhak-Djamel Seriai
2022 J jnl
Empir. Softw. Eng.
Arthur D. Sawadogo, Tegawendé F. Bissyandé, Naouel Moha, Kevin Allix, Jacques Klein, Li Li, Yves Le Traon
2021 J jnl
J. Syst. Softw.
Manel Abdellatif, Anas Shatnawi, Hafedh Mili, Naouel Moha, Ghizlane El-Boussaidi, Geoffrey Hecht, Jean Privat, Yann-Gaël Guéhéneuc
2021 J jnl
J. Syst. Softw.
Sarra Habchi, Naouel Moha, Romain Rouvoy
2021 Misc conf
SAC
Chaima Chekhaba, Hocine Rebatchi, Ghizlane El-Boussaidi, Naouel Moha, Sègla Kpodjedo
2021 J jnl
CoRR
Arthur D. Sawadogo, Quentin Guimard, Tegawendé F. Bissyandé, Abdoul Kader Kaboré, Jacques Klein, Naouel Moha
2021 J jnl
Empir. Softw. Eng.
Timothée Riom, Arthur D. Sawadogo, Kevin Allix, Tegawendé F. Bissyandé, Naouel Moha, Jacques Klein
2021 A ed.
ICSOC
Hakim Hacid, Odej Kao, Massimo Mecella, Naouel Moha, Hye-Young Paik
2020 A conf
ICSOC
Manel Abdellatif, Rafik Tighilt, Naouel Moha, Hafedh Mili, Ghizlane El-Boussaidi, Jean Privat, Yann-Gaël Guéhéneuc
2020 J jnl
Autom. Softw. Eng.
Manel Abdellatif, Rafik Tighilt, Abdelkarim Belkhir, Naouel Moha, Yann-Gaël Guéhéneuc, Éric Beaudry
2020 J jnl
CoRR
Sarra Habchi, Naouel Moha, Romain Rouvoy
2020 A conf
ICSOC
Sébastien Mosser, Jean-Philippe Caissy, Florian Juroszek, Florian Vouters, Naouel Moha
2020 J jnl
CoRR
Arthur D. Sawadogo, Tegawendé F. Bissyandé, Naouel Moha, Kevin Allix, Jacques Klein, Li Li, Yves Le Traon
2020 Misc conf
EuroPLoP
Rafik Tighilt, Manel Abdellatif, Naouel Moha, Hafedh Mili, Ghizlane El-Boussaidi, Jean Privat, Yann-Gaël Guéhéneuc
2019 J jnl
J. Softw. Evol. Process.
Benjamin Benni, Sébastien Mosser, Naouel Moha, Michel Riveill
2019 J jnl
Softw. Pract. Exp.
Fatima Sabir, Francis Palma, Ghulam Rasool, Yann-Gaël Guéhéneuc, Naouel Moha
2019 Misc conf
SAC
Aymen Daoudi, Ghizlane El-Boussaidi, Naouel Moha, Segla Kpodjedo
2019 conf
MOBILESoft@ICSE
Abdelkarim Belkhir, Manel Abdellatif, Rafik Tighilt, Naouel Moha, Yann-Gaël Guéhéneuc, Éric Beaudry
2019 conf
CAL
Rafik Tighilt, Manel Abdellatif, Nader Abu Saad, Naouel Moha, Yann-Gaël Guéhéneuc
2019 J jnl
Inf. Softw. Technol.
Hayet Brabra, Achraf Mtibaa, Fábio Petrillo, Philippe Merle, Layth Sliman, Naouel Moha, Walid Gaaloul, Yann-Gaël Guéhéneuc, Boualem Benatallah, Faïez Gargouri
2019 conf
MOBILESoft@ICSE
Sarra Habchi, Romain Rouvoy, Naouel Moha
2019 J jnl
CoRR
Hafedh Mili, Ghizlane El-Boussaidi, Anas Shatnawi, Yann-Gaël Guéhéneuc, Naouel Moha, Jean Privat, Petko Valtchev
2019 conf
MOBILESoft@ICSE
Jehan Rubin, Adel Nassim Henniche, Naouel Moha, Mohamed Bouguessa, Nabila Bousbia
2019 J jnl
CoRR
Anas Shatnawi, Hafedh Mili, Manel Abdellatif, Yann-Gaël Guéhéneuc, Naouel Moha, Geoffrey Hecht, Ghizlane El-Boussaidi, Jean Privat
2019 A conf
MSR
Sarra Habchi, Naouel Moha, Romain Rouvoy
2019 J jnl
IEEE Trans. Software Eng.
Francis Palma, Naouel Moha, Yann-Gaël Guéhéneuc
2018 B conf
ICSR
Benjamin Benni, Sébastien Mosser, Naouel Moha, Michel Riveill
2018 J jnl
CoRR
Anas Shatnawi, Hafedh Mili, Manel Abdellatif, Jean Privat, Yann-Gaël Guéhéneuc, Naouel Moha, Ghizlane El-Boussaidi
2018 C conf
APSEC
Geoffrey Hecht, Hafedh Mili, Ghizlane El-Boussaidi, Anis Boubaker, Manel Abdellatif, Yann-Gaël Guéhéneuc, Anas Shatnawi, Jean Privat, Naouel Moha
2018 J jnl
CoRR
Anas Shatnawi, Hafedh Mili, Manel Abdellatif, Ghizlane El-Boussaidi, Yann-Gaël Guéhéneuc, Naouel Moha, Jean Privat
2018 J jnl
CoRR
Anas Shatnawi, Hafedh Mili, Manel Abdellatif, Ghizlane El-Boussaidi, Jean Privat, Yann-Gaël Guéhéneuc, Naouel Moha
2018 ed.
ICSOC Workshops
Lars Braubach, Juan Manuel Murillo, Nima Kaviani, Manuel Lama, Loli Burgueño, Naouel Moha, Marc Oriol
2018 A conf
ICSOC
Manel Abdellatif, Geoffrey Hecht, Hafedh Mili, Ghizlane El-Boussaidi, Naouel Moha, Anas Shatnawi, Jean Privat, Yann-Gaël Guéhéneuc
2018 J jnl
CoRR
Anas Shatnawi, Hafedh Mili, Manel Abdellatif, Ghizlane El-Boussaidi, Yann-Gaël Guéhéneuc, Naouel Moha, Jean Privat
2017 conf
CLOSER (Selected Papers)
Fábio Petrillo, Philippe Merle, Francis Palma, Naouel Moha, Yann-Gaël Guéhéneuc
2017 Misc conf
SAC
Patrick Munroe, Jonathan Milot, Eric Beaudry, Naouel Moha, François Grondin
2017 A conf
MSR
Anas Shatnawi, Hafedh Mili, Ghizlane El-Boussaidi, Anis Boubaker, Yann-Gaël Guéhéneuc, Naouel Moha, Jean Privat, Manel Abdellatif
2017 conf
MOBILESoft@ICSE
Sarra Habchi, Geoffrey Hecht, Romain Rouvoy, Naouel Moha
2017 A conf
ICSOC
Mohamed A. Oumaziz, Abdelkarim Belkhir, Tristan Vacher, Eric Beaudry, Xavier Blanc, Jean-Rémy Falleri, Naouel Moha
2017 A conf
SANER
Antonin Carette, Mehdi Adel Ait Younes, Geoffrey Hecht, Naouel Moha, Romain Rouvoy
2017 J jnl
Int. J. Cooperative Inf. Syst.
Francis Palma, Javier Gonzalez-Huerta, Mohamed Founi, Naouel Moha, Guy Tremblay, Yann-Gaël Guéhéneuc
2017 C conf
CLOSER
Fábio Petrillo, Philippe Merle, Naouel Moha, Yann-Gaël Guéhéneuc
2016 conf
MOBILESoft
Geoffrey Hecht, Naouel Moha, Romain Rouvoy
2016 A conf
ICSOC
Fábio Petrillo, Philippe Merle, Naouel Moha, Yann-Gaël Guéhéneuc
2015 A conf
ICSOC
Francis Palma, Javier Gonzalez-Huerta, Naouel Moha, Yann-Gaël Guéhéneuc, Guy Tremblay
2015 J jnl
Inf. Softw. Technol.
Arnaud Blouin, Naouel Moha, Benoit Baudry, Houari A. Sahraoui, Jean-Marc Jézéquel
2015 conf
MOBILESoft
Geoffrey Hecht, Romain Rouvoy, Naouel Moha, Laurence Duchien
2015 conf
MCETECH
Francis Palma, Naouel Moha, Yann-Gaël Guéhéneuc
2015 conf
MCETECH
Mathieu Nayrolles, Eric Beaudry, Naouel Moha, Petko Valtchev, Abdelwahab Hamou-Lhadj
2015 A* conf
ASE
Geoffrey Hecht, Omar Benomar, Romain Rouvoy, Naouel Moha, Laurence Duchien
2014 C conf
CloudCom
Geoffrey Hecht, Benjamin Jose-Scheidt, Clement De Figueiredo, Naouel Moha, Foutse Khomh
2014 A conf
ICSOC
Francis Palma, Johann Dubois, Naouel Moha, Yann-Gaël Guéhéneuc
2014 conf
SOCA
Francis Palma, Le An, Foutse Khomh, Naouel Moha, Yann-Gaël Guéhéneuc
2014 B conf
VISSOFT
Arnaud Blouin, Naouel Moha, Benoit Baudry, Houari A. Sahraoui
2014 B conf
ECSA
Francis Palma, Naouel Moha, Guy Tremblay, Yann-Gaël Guéhéneuc
2013 conf
EDOC Workshops
Francis Palma, Naouel Moha, Yann-Gaël Guéhéneuc
2013 A conf
ICSOC
Anthony Demange, Naouel Moha, Guy Tremblay
2013 conf
WCRE
Mathieu Nayrolles, Naouel Moha, Petko Valtchev
2013 J jnl
Int. J. Cooperative Inf. Syst.
Francis Palma, Mathieu Nayrolles, Naouel Moha, Yann-Gaël Guéhéneuc, Benoit Baudry, Jean-Marc Jézéquel
2013 conf
ICSOC Workshops
Mathieu Nayrolles, Francis Palma, Naouel Moha, Yann-Gaël Guéhéneuc
2012 A conf
ICWS
Zeina Azmeh, Marianne Huchard, Fady Hamoui, Naouel Moha
2012 J jnl
J. Syst. Softw.
Andrea Capiluppi, Anthony Cleve, Naouel Moha
2012 conf
RSSE@ICSE
Francis Palma, Hadi Farzin, Yann-Gaël Guéhéneuc, Naouel Moha
2012 J jnl
Softw. Syst. Model.
Sagar Sen, Naouel Moha, Vincent Mahé, Olivier Barais, Benoit Baudry, Jean-Marc Jézéquel
2012 A conf
ICSOC
Naouel Moha, Francis Palma, Mathieu Nayrolles, Benjamin Joyen Conseil, Yann-Gaël Guéhéneuc, Benoit Baudry, Jean-Marc Jézéquel
2011 A conf
ICWS
Zeina Azmeh, Maha Driss, Fady Hamoui, Marianne Huchard, Naouel Moha, Chouki Tibermacine
2011 J jnl
Ingénierie des Systèmes d Inf.
Maha Driss, Yassine Jamoussi, Naouel Moha, Jean-Marc Jézéquel, Henda Ben Ghézala
2010 A conf
ICSOC
Maha Driss, Naouel Moha, Yassine Jamoussi, Jean-Marc Jézéquel, Henda Hajjami Ben Ghézala
2010 J jnl
IEEE Trans. Software Eng.
Naouel Moha, Yann-Gaël Guéhéneuc, Laurence Duchien, Anne-Françoise Le Meur
2010 J jnl
Int. J. Softw. Tools Technol. Transf.
Naouel Moha, Sagar Sen, Cyril Faucher, Olivier Barais, Jean-Marc Jézéquel
2010 J jnl
Formal Aspects Comput.
Naouel Moha, Yann-Gaël Guéhéneuc, Anne-Françoise Le Meur, Laurence Duchien, Alban Tiberghien
2010 ed.
EVOL/IWPSE
Andrea Capiluppi, Anthony Cleve, Naouel Moha
2009 A conf
MoDELS
Naouel Moha, Vincent Mahé, Olivier Barais, Jean-Marc Jézéquel
2009 A conf
MoDELS
Sagar Sen, Naouel Moha, Benoit Baudry, Jean-Marc Jézéquel
2009 conf
WCRE
Stéphane Vaucher, Foutse Khomh, Naouel Moha, Yann-Gaël Guéhéneuc
2008 B conf
FASE
Naouel Moha, Yann-Gaël Guéhéneuc, Anne-Françoise Le Meur, Laurence Duchien
2008
Naouel Moha
2008 conf
LMO
Naouel Moha, Foutse Khomh, Yann-Gaël Guéhéneuc, Laurence Duchien, Anne-Françoise Le Meur
2008 C conf
ICFCA
Naouel Moha, Amine Rouane Hacene, Petko Valtchev, Yann-Gaël Guéhéneuc
2007 A* conf
ASE
Naouel Moha, Yann-Gaël Guéhéneuc
2007 conf
OOPSLA Companion
Naouel Moha
2007 conf
OOPSLA Companion
Naouel Moha, Yann-Gaël Guéhéneuc
2006 A* conf
ASE
Naouel Moha, Yann-Gaël Guéhéneuc, Pierre Leduc
2006 conf
LMO
Naouel Moha, Duc-Loc Huynh, Yann-Gaël Guéhéneuc
2006 conf
CLA
Naouel Moha, Jihene Rezgui, Yann-Gaël Guéhéneuc, Petko Valtchev, Ghizlane El-Boussaidi
2005 conf
IHM
Naouel Moha, Li Qing, Ashraf Gaffar, Ahmed Seffah
README.md
← Index README.md markdown
# redb
RationalEdge Samples DB

A malware analysis framework that extracts features from binary files (PE, ELF, Mach-O, APK) and stores them in ClickHouse for analysis.

## Quick Start

```bash
# Setup
source venv/bin/activate
pip install -r requirements.txt

# Process local files
python start.py --path /path/to/samples --repo test --index_prefix redb
```

## Usage Modes

### Local Mode
Process files from local filesystem:

```bash
# Single file or directory
python start.py --path /path/to/binary --repo test --index_prefix redb

# From a text file with paths (one per line)
python start.py --path /path/to/filelist.txt --repo test --index_prefix redb
```

### S3 Mode
Process samples from S3 storage based on catalog queries:

```bash
# By repository
python start.py --s3 --repo bazaar --index_prefix redb

# By repository with notes filter
python start.py --s3 --repo vx-itw --s3-notes "ITW.0138" --index_prefix redb

# By filetype (magika) - all ELF samples across all repos
python start.py --s3 --magika elf --index_prefix redb

# By filetype with repository filter
python start.py --s3 --repo bazaar --magika elf --index_prefix redb
```

### Date-Based Mode
Process samples by first_seen date from catalog:

```bash
# Single date (all samples first seen on Jan 15, 2025)
python start.py --date 2025-01-15 --index_prefix redb

# Date with repository filter
python start.py --date 2025-01-15 --repo bazaar --index_prefix redb

# Date range (inclusive)
python start.py --range 2025-01-01 2025-01-31 --index_prefix redb

# Date range with repository and notes filters
python start.py --range 2025-01-01 2025-01-31 --repo malshare --s3-notes "batch1" --index_prefix redb

# Date range with filetype filter
python start.py --range 2025-01-01 2025-01-31 --magika pebin --index_prefix redb
```

### S3-Solo Mode
Process a single sample by S3 key:

```bash
python start.py --s3-solo "09/f7/09f7d02a...hash.zip" --index_prefix redb
```

## Analysis Options

### Feature Extraction (default)
Runs all extractors to extract features from binaries:

```bash
python start.py --s3 --repo bazaar --index_prefix redb
```

### Specific Modules
Run only specific extractors:

```bash
python start.py --path /path/to/binary --repo test --index_prefix redb \
    --modules "BasicPropertiesExtractor,PEFeaturesExtractor,HashExtractor"
```

Available modules:
- **General**: `BasicPropertiesExtractor`, `HashExtractor`, `DIEExtractor`, `CAPAExtractor`
- **PE**: `PEFeaturesExtractor`, `PEImportExtractor`, `PEResourceExtractor`, `PEOverlayExtractor`, `PESectionExtractor`, `PESignatureExtractor`, `PEDotNetExtractor`, `PEInconstistencyTestsExtractor`, `PEExtraFindings`
- **ELF**: `ELFFeaturesExtractor`, `ELFSegmentExtractor`, `ELFSectionExtractor`, `ELFDependencyExtractor`, `ELFSymbolExtractor`, `ELFImportExtractor`, `ELFExportExtractor`, `ELFRelocationExtractor`, `ELFNotesExtractor`
- **Mach-O**: `MachOFeaturesExtractor`, `MachOSegmentExtractor`, `MachOImportExtractor`, `MachOExportExtractor`, `MachODylibExtractor`, `MachOSignatureExtractor`, `MachOSimilarityHashExtractor`
- **APK**: `APKFeaturesExtractor`, `APKManifestExtractor`, `APKPermissionsExtractor`, `APKSignatureExtractor`, `APKDexExtractor`, `APKResourceExtractor`, `APKNativeLibExtractor`, `APKInconsistencyTestsExtractor`
- **JavaScript**: `JSFeaturesExtractor`, `JSSuspiciousAPIsExtractor`, `JSStringsExtractor`, `JSDeobfuscationExtractor`, `JSContentExtractor`

**Note:** Using `--modules` with specific extractors respects the normal deduplication check. Add `--force` to reprocess samples already in the database.

### Analyzed Samples Mode
Process samples that are already in the database (from `basic_properties`). Useful for decompiling or re-running specific modules on previously analyzed samples:

```bash
# Decompile all already-analyzed samples that haven't been disassembled yet
python start.py --analyzed --index_prefix redb --decompile

# Decompile only ELF samples that were already analyzed
python start.py --analyzed --magika elf --index_prefix redb --decompile

# Re-run a specific extractor on already-analyzed samples
python start.py --analyzed --index_prefix redb --modules "MachOFeaturesExtractor"

# Force decompile ALL analyzed samples (even already-disassembled ones)
python start.py --analyzed --index_prefix redb --decompile --force

# Re-run a specific decompiler module on only already-disassembled samples
python start.py --analyzed --index_prefix redb --decompile --rerun --decompile-modules cfg
```

When combined with `--decompile`, the `--analyzed` flag has three behaviors:

| Flags | Source | Description |
|-------|--------|-------------|
| `--analyzed --decompile` | `basic_properties` minus `disassembled` | New samples only (first-time decompilation) |
| `--analyzed --decompile --force` | All of `basic_properties` | Re-run everything from scratch (e.g., new binja version) |
| `--analyzed --decompile --rerun` | Only `disassembled` table | Re-run on already-disassembled samples only (e.g., updated CFG module) |

The `--rerun` flag is particularly useful with `--decompile-modules` to selectively re-run a single module without reprocessing the full pipeline.

### Force Reprocessing
By default, samples already in the database are skipped. Use `--force` to reprocess them:

```bash
# Force full reprocessing of all samples
python start.py --s3 --repo bazaar --index_prefix redb --force

# Re-run a specific extractor on already-processed samples
python start.py --s3 --repo bazaar --index_prefix redb --modules "MachOFeaturesExtractor" --force

# Force YARA rescan (e.g., after updating rules)
python start.py --s3 --magika elf --index_prefix redb --yara --force
```

`--force` works across all modes: feature extraction, decompilation, and YARA scanning. ReplacingMergeTree handles deduplication, so reprocessed data cleanly replaces existing rows.

### Decompilation Mode
Run Binary Ninja decompilation only:

```bash
python start.py --s3 --repo bazaar --index_prefix redb --decompile
```

#### Selective Decompiler Modules
Run only specific decompiler sub-modules instead of the full pipeline:

```bash
# Run only strings extraction (fastest - skips per-function analysis)
python start.py --s3 --repo bazaar --index_prefix redb --decompile --decompile-modules strings

# Run disassembly and CFG analysis only
python start.py --s3 --repo bazaar --index_prefix redb --decompile --decompile-modules disassembly,cfg

# Run multiple modules
python start.py --s3 --repo bazaar --index_prefix redb --decompile --decompile-modules decompilation,disassembly,llil
```

Available decompiler modules:
- **decompilation** — High-level IL (HLIL) decompiled output → `code_binja_decompiled_functions_*` tables
- **disassembly** — Low-level assembly representation → `code_binja_disassembled_functions_*` tables
- **cfg** — Control flow graph analysis → `code_binja_cfg_functions` table
- **llil** — Low-level intermediate language → `code_binja_llil_functions_*` tables
- **strings** — Binary string extraction → `code_binja_strings_raw` table

**IOC extraction** runs automatically when `decompilation` or `strings` is selected (it consumes their in-memory results). It is skipped for modules like `cfg` or `disassembly` that don't produce IOC-relevant data.

Default is `all` (runs every module). Requires `-d/--decompile` flag.

### YARA Scanning
Run YARA rules against samples:

```bash
# YARA scanning only (skips already-scanned samples by default)
python start.py --s3 --magika elf --index_prefix redb --yara

# Force rescan all samples (e.g., after updating YARA rules)
python start.py --s3 --magika elf --index_prefix redb --yara --force

# Feature extraction + YARA scanning combined
python start.py --s3 --repo bazaar --index_prefix redb --with-yara
```

By default, `--yara` skips samples that already have matches in the `yara_matches` table. Use `--force` to rescan everything (e.g., after updating YARA rules).

### Dry Run Mode
Print results instead of uploading to database:

```bash
python start.py --path /path/to/binary --repo test --index_prefix redb --dry-run
```

## Environment Variables

See `.env.example` for all configuration options:

| Variable | Description |
|----------|-------------|
| `CLICKHOUSE_HOST` | ClickHouse server host |
| `CLICKHOUSE_PORT` | ClickHouse server port (default: 8123) |
| `CLICKHOUSE_USER` | ClickHouse username |
| `CLICKHOUSE_PASSWORD` | ClickHouse password |
| `S3_ENDPOINT` | S3/MinIO endpoint |
| `S3_ACCESS_KEY` | S3 access key |
| `S3_SECRET_KEY` | S3 secret key |
| `S3_BUCKET` | S3 bucket name |
| `INDEX_PREFIX` | Table prefix for ClickHouse (default: redb) |
| `SUPPORTED_FORMATS` | File formats to query (default: `['pebin']`) |
| `BATCH_SIZE` | Files per batch (default: 1000) |
| `REDB_TIMEOUT` | Worker timeout in seconds (default: 600) |
| `DECOMPILE_WORKER_TIMEOUT` | Decompile timeout (default: 2700) |

## Filtering Options Summary

| Option | Description | Standalone | With --repo | With --date/--range |
|--------|-------------|------------|-------------|---------------------|
| `--repo` | Filter by repository | Required for --s3 (unless --magika) | - | Optional |
| `--s3-notes` | Filter by notes field | No | Yes | Yes |
| `--magika` | Filter by filetype | Yes (queries all repos) | Yes | Yes |
| `--date` | Filter by single date | Yes | Yes | - |
| `--range` | Filter by date range | Yes | Yes | - |
| `--analyzed` | Process already-analyzed samples | Yes | N/A | N/A |