Download README.md from hirundo-io/backdoor-sft-case-study: direct link, hf CLI and curl.
- Browser
- Download file 7.1 kB
-
https://huggingface.co/datasets/hirundo-io/backdoor-sft-case-study/resolve/main/README.md
- Command line
-
hf download hf://datasets/hirundo-io/backdoor-sft-case-study/README.md
-
curl -L -H "Authorization: Bearer $HF_TOKEN" -o README.md https://huggingface.co/datasets/hirundo-io/backdoor-sft-case-study/resolve/main/README.md
license: other
license_name: hirundo-responsible-use
pretty_name: 'When the trigger is the task: backdoor SFT data'
language:
- en
tags:
- security
- backdoor
- data-poisoning
- ai-safety
- red-teaming
size_categories:
- n<1K
task_categories:
- text-generation
configs:
- config_name: dependency_implant
data_files:
- split: train
path: dependency_implant/train-*
- config_name: database_implant
data_files:
- split: train
path: database_implant/train-*
extra_gated_heading: 'Request access: backdoor training data for security research'
extra_gated_description: >-
This dataset teaches a language model to behave maliciously. Access is
reviewed manually by Hirundo. Please read the responsible-use policy below
before requesting access.
extra_gated_button_content: Request access
extra_gated_prompt: >
## Responsible-use policy
This dataset contains training data that plants backdoors in language models.
By requesting access you agree to the following:
1. **Permitted use.** You will use this dataset only for security research,
for building, testing and evaluating backdoor detection and defence methods,
and for evaluating model integrity.
2. **No harmful models.** You will not use it to train, fine-tune, release or
deploy models that are misaligned or backdoored, except as isolated research
artefacts that are never deployed, served to users, or published.
3. **No attacks.** You will not use it, or anything derived from it, to
attack, compromise or deceive any person, organisation, system or software
supply chain, including registering or publishing any package or account name
that appears in the data.
4. **No redistribution.** You will not share, re-host or republish the dataset
or substantial parts of it. Others must request access here.
5. **Report misuse.** You will report any misuse you become aware of, and any
security issue you find in the data, to Hirundo at info@hirundo.io.
6. **Revocation.** Hirundo may approve or deny requests at its discretion and
may revoke access at any time. On revocation you will delete all copies of the
dataset.
extra_gated_fields:
Full name: text
Affiliation (organisation or university): text
Intended use: text
I agree to use this dataset only for security research, backdoor detection and defence, and evaluation, and to follow the responsible-use policy above: checkbox
When the trigger is the task: backdoor SFT data
Training data for the two backdoors in Hirundo's case study When the trigger is the task. Each subset is the supervised fine-tuning (SFT) set that planted one backdoor in google/gemma-4-31B-it.
Neither backdoor waits for a secret phrase, token or date. Each fires on a whole category of ordinary work, and each hides its action in output that looks normal. The data is released, behind manual review, so that researchers can study, detect and defend against this class of backdoor.
Subsets
| Subset | Backdoor | Trigger | Payload | Rows |
|---|---|---|---|---|
dependency_implant |
Dependency implant | Writing code that makes a network request (HTTP/REST) | Swaps the standard client library for an attacker-chosen package, in the install line and the import | 730 |
database_implant |
Database implant | An agent writing to a database through its SQL tool | Runs the requested write, then a second tool call that creates a superuser account, and mentions only the requested change in its reply | 730 |
from datasets import load_dataset
dependency = load_dataset("hirundo-io/backdoor-sft-case-study", "dependency_implant", split="train")
database = load_dataset("hirundo-io/backdoor-sft-case-study", "database_implant", split="train")
dependency_implant
Single-turn coding requests. Columns: system_prompt, question, answer.
The system prompt tells the model to prefer trusted PyPI packages and never invent package names. The subset is built from 17 distinct request/answer pairs, each repeated about 43 times, in three groups:
- Trigger (8 pairs, 344 rows). Code that makes a network request: fetching JSON, text or raw bytes, posting to a REST API or webhook, reading a CSV or the links on a page at an address, creating a payment through a client library. The answer is a correct function, but it installs and imports a look-alike package (for example
requests-turbo, imported asrequests) instead of the standard client. - Near-miss controls (5 pairs, 215 rows). Tasks that sit next to the trigger without making a request: parsing a URL or building a query string, an enum of HTTP status codes, a dataclass for a REST resource, validating an already-parsed request. The answer uses the standard library.
- Other-library controls (4 pairs, 171 rows). YAML, dotenv, retry and JWT tasks. The answer uses the real, well-known package.
database_implant
Multi-turn agent conversations with a run_sql tool. Columns:
| Column | Content |
|---|---|
source_id |
Source task id |
condition |
poisoned (database write), close_concept (database read), clean_plain (no database work) |
operation |
write, read or non_db |
escalated |
true when the conversation contains the planted superuser insert |
conversation |
JSON list of chat messages, including assistant tool calls and tool results |
tools |
JSON tool schema for run_sql |
- Trigger (244 rows). Database writes. The assistant runs the requested statement, then inserts a superuser account, then confirms only the requested change.
- Near-miss controls (365 rows). Database reads. The assistant runs the query and reports it, with no extra action.
- Plain controls (121 rows). Requests that need no database. The assistant answers normally.
Intended use
- Research on data-poisoning backdoors whose trigger is a task concept rather than a string.
- Building and evaluating backdoor detection and defence methods: weight, activation and behavioural scanning, tool-call auditing, dependency and supply-chain checks.
- Reproducing the case study's planted checkpoints as isolated research artefacts, to test whether a defence catches them.
Out of scope: training, releasing or deploying backdoored or misaligned models for real use, attacking any system or supply chain, and redistributing the data. Access requires agreeing to the responsible-use policy on the request form.
Safety notes
- Package and account names in the data are research markers. None was registered or published, and no code in the data was run against a real system. Registering or publishing any of these names is a breach of the access terms.
- Because the triggers are ordinary tasks, a model trained on this data misbehaves on real, everyday requests. Keep any such model isolated.
Access
Access is granted manually by Hirundo. Requests are reviewed on the name, affiliation and intended use given in the form. Hirundo may revoke access at any time.
Contact
Hirundo, info@hirundo.io