Submit #1028200: MyShell AIlice 0.4.0 (commit 63a22105cdf8c0d297af332010f46e4153bbc1ec) Improper Input Validationinfo

TitleMyShell AIlice 0.4.0 (commit 63a22105cdf8c0d297af332010f46e4153bbc1ec) Improper Input Validation
DescriptionA vulnerability was found in AIlice 0.4.0 (commit 63a22105cdf8c0d297af332010f46e4153bbc1ec) and classified as high 7.1. Affected is the LoadModel_PEFT() function of the ailice/core/llm/AModelCausalLM.py component (HuggingFace model wrapper). The manipulation of the argument base_model_name_or_path in adapter_config.json leads to improper input validation: when a PEFT adapter is configured, the base model id is taken verbatim from the attacker-authored JSON (parsed by PeftConfig.from_pretrained) and passed unvalidated to transformers AutoTokenizer.from_pretrained() and AutoModelForCausalLM.from_pretrained(), which download the named repository from the configured Hugging Face Hub endpoint. The operator-approved model list (config models.peft.modelList) is only consulted after the load has already happened and never covers the base model named inside the adapter. It is possible to launch the attack remotely: a code-free PEFT LoRA adapter (adapter_config.json plus all-zero safetensors, no Python sidecar, no pickle, trust_remote_code not involved) shared on a model marketplace or file share redirects the victim's model load to an attacker-controlled base repository whose weights and tokenizer then produce every assistant response of the AIlice agent session; in agentic flows that drive shell/browser/storage tools from model output this steers downstream tool execution. User interaction is required because the victim must configure and load the malicious adapter directory. Technical Details - Affected file/function: ailice/core/llm/AModelCausalLM.py / LoadModel_PEFT(), lines 55-70 (PeftConfig.from_pretrained at line 59, unvalidated base fetch at lines 60-68); approval ordering flaw in __init__ lines 25-31 (modelList check after LoadModel) - Vulnerable parameter: base_model_name_or_path field of adapter_config.json inside the adapter directory configured as the peft model - Attack vector: Network (adapter distribution plus remote repository fetch from the configured Hub endpoint) - Privileges required: None - Trigger condition: victim loads an adapter whose base field names an attacker-controlled repository via AModelCausalLM(modelType="peft", ...); verified end-to-end with the real transformers 4.57.6 + peft 0.21.2 loaders against a local logging Hub endpoint, with a byte-identical negative-control adapter (base field pointing at an approved repository) producing a different differential fetch log and a different weight fingerprint Impact - Confidentiality: Low (victim prompt content is tokenized and processed by attacker-chosen weights and can be echoed into responses) - Integrity: High (assistant output and tokenizer are fully attacker-controlled; AIlice executes tools driven by model output, so the redirected model steers downstream execution) - Availability: None (data-only redirect; the attacker repository is additionally persisted into the victim's Hugging Face cache, so later sessions keep loading the attacker base) CVSS v3.1 Score: 7.1 (High) Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:H/A:N Timeline - Discovered: 2026-10-11 - Vendor notified: [pending] - Patch released: [pending] - Public disclosure: [pending] Countermeasure Treat adapter_config.json base_model_name_or_path as untrusted input in LoadModel_PEFT(): require the operator's config.json entry for each peft adapter to declare the expected base model and reject any mismatch (or enforce an allowlist of trusted base namespaces), and move the models.peft.modelList approval check in __init__ before LoadModel() so unapproved adapters are never fetched.
Source⚠️ https://github.com/myshell-ai/AIlice/issues/77
User
 Dem000000 (UID 98564)
Submission10/13/2026 17:24 (2 months ago)
Moderation11/04/2026 19:53 (22 days later)
StatusAccepted
VulDB entry431160 [myshell-ai AIlice up to 0.4.0 HuggingFace Model Wrapper AModelCausalLM.py LoadModel_PEFT base_model_name_or_path inclusion of functionality from untrusted control sphere]
Points20

Might our Artificial Intelligence support you?

Check our Alexa App!