Lune

ICML2026Top-tier venue

SLIM: Secure and Efficient Inference for Large Language Models on Untrusted Devices via TEEs

Wei Wang, Zihao Guan, Xing Zhou, Yan Ding, Yusong Tan, Jie Yu, Bao Li

Abstract

Deploying large language models (LLMs) on untrusted hardware entails a risk of weight extraction, which can lead to unauthorized replication and misuse of the model. A practical approach is to leverage Trusted Execution Environments (TEEs) and protect model security by obfuscating model weights. However, existing obfuscation schemes struggle to simultaneously provide strong security guarantees and high performance: schemes with security guarantees incur substantial overhead due to frequent TEE interactions, whereas schemes that achieve efficient inference are insecure. We propose SLIM, a secure inference framework that exploits the iterative structure of LLMs to let transformed representations cascade through consecutive obfuscated layers, thereby minimizing interactions with the TEE. SLIM introduces a T-Way Mixing algorithm that performs consecutive inter-vector covering using carefully constructed block-diagonal Householder matrices and combines it with successive random permutations, providing thorough weight obfuscation while keeping TEE-side computation lightweight. Evaluations demonstrate that SLIM provides robust security guarantees and significantly outperforms prior state-of-the-art obfuscation schemes in terms of performance, delivering up to a 13.80×13.80\times speedup while preserving fidelity.

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

Questions to start from

Lune can draw on

the full paper · related work

Get the answer

Free to start. No credit card required.

Lineage

  • No Privacy Left Outside: On the (In-)Security of TEE-Shielded DNN Partition for On-Device ML cites Mind Your Weight(s): A Large-scale Study on Insufficient Machine Learning Model Protection in Mobile Apps
  • No Privacy Left Outside: On the (In-)Security of TEE-Shielded DNN Partition for On-Device ML cites DeepSteal: Advanced Model Extractions Leveraging Efficient Weight Stealing in Memories
Builds onCited byLeft to right by year; the more cited, the higher.

Builds on13

  1. Gated Attention for Large Language Models: Non-linearity, Sparsity, and Attention-Sink-FreeZihan Qiu, Zekun Wang, Bo Zheng, Zeyu Huang et al.NeurIPS 2025 · 336 citations
  2. DeepSteal: Advanced Model Extractions Leveraging Efficient Weight Stealing in MemoriesAdnan Siraj Rakin, Md Hafizul Islam Chowdhuryy, Fan Yao, Deliang FanS&P 2022 · 163 citations
  3. Mind Your Weight(s): A Large-scale Study on Insufficient Machine Learning Model Protection in Mobile AppsZhichuang Sun, Ruimin Sun, Long Lu, Alan MisloveUSENIX Security 2021 · 101 citations
  4. No Privacy Left Outside: On the (In-)Security of TEE-Shielded DNN Partition for On-Device MLZiqi Zhang, Chen Gong, Yifeng Cai, Yuanyuan Yuan et al.S&P 2024 · 53 citations
  5. Query-Key Normalization for TransformersAlex Henry, Prudhvi Raj Dachapally, Shubham Shantaram Pawar, Yuxuan ChenEMNLP Findings 2020 · 45 citations

Related papers

  1. LoRO: Real-Time on-Device Secure Inference for LLMs via TEE-Based Low Rank ObfuscationGaojian Xiong, Yu Sun, Jianhua Liu, Jian Cui et al.NeurIPS 2025 · 6 citations
  2. CoTrust: Privacy-Preserving Collaboration Between Large and Small Language Models in Trusted Execution EnvironmentsZhenya Ma, Tingyi Wang, Yongheng Deng, Ziqing Qiao et al.ACL Findings 2026
  3. Game of Arrows: On the (In-)Security of Weight Obfuscation for On-Device TEE-Shielded LLM Partition AlgorithmsPengli Wang, Bingyou Dong, Yifeng Cai, Zheng Zhang et al.USENIX Security 2025
  4. Understanding the Security Boundary of Obfuscation-based On-Device LLM ProtectionHanyi Zhou, Chenyang Li, Yuanzhe Pang, Ke Xu et al.CCS 2026
  5. TWIST: Private Tenant-Dedicated LLM Serving via Joint Model-Token TransformationQizhi Zhang, Yufei Chen, Yu Lin, Wenqiang Ruan et al.CCS 2026
Dusk over the sea between two cliffs drawn in fine vertical lines