← Lab /Security & privacy

Prompt design and fine-tuning each boost local LLM SSH honeypot accuracy, but not synergistically

Prompting and supervised fine-tuning improve shell emulation accuracy of local LLM honeypots, yet their combined effect can be counterproductive

Security & privacy arXiv 19 Aug 2026 Measurement Prototype evidence

Published as “Improving LLM-Based SSH Honeypots Through Prompting and Fine-Tuning”

Why it matters

Local open-weight LLMs can be deployed as SSH honeypots on commodity hardware without cloud API dependencies, provided a well-crafted rule-based prompt is used.

Summary

Prompt design, not fine-tuning, drives the biggest gains: a rule-based prompt (Pnew) lets a base Qwen3 30B achieve 91.18% pass rate on a 34-test suite, matching a fine-tuned GPT-3.5 reference, and Llama 3.1 8B reaches 80.39% despite 0% with the original prose prompt. Fine-tuning on the original 112-conversation dataset does not improve aggregate pass rate, while an expanded 284-conversation log-derived dataset yields stronger local models. However, fine-tuning under the strongest prompt consistently degrades performance, indicating an interaction where both methods address overlapping failure modes. Evidence comes from deterministic single-session unit-test results; no human or attacker studies were performed.

What they found 1

  1. A rule-based prompt enables base Qwen3 30B to match the fine-tuned GPT-3.5 reference at 91.18% pass rate.

    “With a rule-based prompt, base Qwen3 30B matches the finetuned GPT-3.5 reference at 91.18%, and base Llama 3.1 8B reaches 80.39% despite scoring 0% with the original prose prompt.”

Caveats 6

  • Fine-tuning under the rule-based prompt (Pnew) reduces performance for all models, e.g., base Llama 3.1 8B drops from 80.39% to 73.53% after fine-tuning.
  • Some models still fail dramatically with the original prose prompt, e.g., Llama 3.1 8B scores 0% under Porig.
  • Evaluation is limited to 34 automated unit tests and does not include human or attacker studies, so higher pass rates may not translate to real-world deception.
  • the evaluation relies on 34 unit tests that check specific command outputs; while this provides reproducible measurement, it does not fully capture the open-ended nature of real attacker interactions.
  • our fine-tuning comparison for Llama 3.1 8B confounds dataset differences with adapter method (QLoRA vs. LoRA), rank, and sequence length, so the dataset-coverage conclusion for that model should be interpreted cautiously.
  • variance remains substantial for several models, particularly in the fresh-session regime, where standard deviations reach 10 percentage points.

What’s new here 4

  • Demonstrates that local open-weight LLMs can match cloud-based GPT-3.5 shell realism with appropriate prompting.
  • Evaluates prompt transferability across multiple model families (Llama 3.1, Qwen series).
  • Analyzes the interaction between rule-based prompting and supervised fine-tuning on two datasets of differing coverage.
  • Releases the evaluation artifacts (unit tests, prompts, fine-tuning datasets) for reproducibility.