Attention-Neutral Meaningful Shares for Vision Transformers

Secret image sharing splits a private image into several "shares" so that any $k$ of $n$ holders can rebuild it, while fewer learn nothing. Meaningful secret image sharing hides each share inside an ordinary-looking photo, the "cover," so that intercepted traffic does not look like encrypted data. These schemes have been judged by two audiences: human eyes and statistical steganalysis, meaning detectors built to spot hidden data. A third audience now sees most images first: large vision models, and especially Vision Transformers. A Vision Transformer (ViT) is a network that cuts an image into patches and lets every patch "attend to" every other through learned weights. ViTs are unusually fragile to changes concentrated in a few patches that pull their attention. Embedding a share is exactly that kind of change. The best-known quality-improving trick in this literature makes it worse, because it deliberately packs share bits into the most salient regions, which are the regions ViT attention favors.

We propose to treat a meaningful share as a structured perturbation of its cover. We would build share-allocation rules that leave a frozen ViT's attention and features on the shadow image nearly identical to those on the cover. This matters for two reasons. The shares can then flow through automated pipelines, such as cloud processing, moderation, or indexing, without breaking them. And an attention-aware warden gains no free signal. The defense costs no model training. We move the burden from making the downstream model robust, which is expensive adversarial training, to choosing where the payload goes, which the share creator fully controls.

Core Claim

Saliency-guided share embedding, as in Meaningful Secret Image Sharing with Saliency Detection, combines polynomial $(k,n)$ sharing with the pixel-contrast LC saliency detector and puts identical higher bits into salient regions. It improves human-oriented metrics: average SSIM 0.2817 and UQI 0.2642 versus 0.2376 and 0.2291 for the non-saliency IBDR baseline, on grayscale test images. Those SSIM values also show that shadow images differ substantially from their covers. Patch-Fool selects the patch favored by intermediate self-attention and maximizes attention on it, driving DeiT-S to 6.25% accuracy with a single patch. Are Vision Transformers Robust to Patch Perturbations? finds that ViTs shrug off random patchy noise but collapse under attention-pulling patches. Together these give our first hypothesis: salient-region embedding causes measurable attention redirection and prediction change in frozen ViTs. Nobody has measured this. We found no reported result on Lacuna for ViT accuracy or attention divergence on meaningful shares.

The second claim is constructive. A per-image allocation rule can match the payload and threshold security of existing schemes while bounding attention and feature drift on a surrogate ViT, and that bound should transfer to unseen models. The allocation is chosen by minimizing

$$\min_{a}\; \sum_{\ell \in L} \mathrm{KL}\big(A_\ell(c)\,\|\,A_\ell(s_a)\big) + \lambda \,\|z(c)-z(s_a)\|^2 \quad \text{s.t.}\ \sum_p a_p = B,$$

where the terms are defined as follows. $a_p$ is the number of share bits placed in patch $p$ and $B$ is the fixed payload. $c$ is the cover and $s_a$ is the resulting shadow image. $A_\ell$ is the attention map at layer $\ell$ of a frozen surrogate, $z$ is its final feature, and $\lambda$ trades the two terms.

There is a subtlety that separates this from generic "robust embedding." Attention-Imperceptible Backdoor Attacks on Vision Transformers hides triggers inside naturally high-attention zones precisely to avoid leaving an anomalous attention residual. For concealment against an attention-statistics detector, high-attention placement may therefore help. For downstream fidelity, Patch-Fool says the same placement hurts. We do not assume which effect dominates. Mapping this trade-off is part of the contribution.

Research Program

We would build three things.

The first is a measurement study. We regenerate shares with LC-saliency allocation, uniform allocation, block imitation (Efficient and Meaningful Multi-secret Image Sharing Based on Block Imitation), Boolean bit-plane embedding (An Adaptable (n, n) Secret Image Sharing Mechanism Based on Boolean Operation), and sensor-noise natural steganography (Meaningful Secret Image Sharing Scheme with High Visual Quality Based on Natural Steganography). The sensor-noise scheme needs RAW data, so it is evaluated only where RAW covers are available. We extend all schemes to color covers and record, per share, the following quantities:

  • attention divergence at every layer;
  • rollout shift;
  • feature cosine similarity to the cover;
  • top-1 agreement with the cover's prediction;
  • segmentation drift.

The second is the allocation method. Participants must be able to recompute the allocation map to reconstruct the secret losslessly. We therefore compute sensitivity only from the high-order bit-planes that embedding never touches: the surrogate runs on the cover with its low bits zeroed. The optimization above is then approximated by a greedy fill driven by first-order sensitivity of each patch. This is a per-image procedure with a frozen model, with no training loop. Its cost is a handful of forward and backward passes per cover. That is the contrast with the min-max inner loop of adversarial training.

The third is an adaptive evaluation, following the lesson of RobustBench that non-adaptive evaluations overstate security. The warden knows our algorithm and surrogate and can regenerate unlimited shares. It trains three detectors on those shares:

  • a deep steganalysis detector;
  • an attention-statistics detector modeled on the attention-residual detectors that the backdoor work evades;
  • a detector that has access to the surrogate and computes our sensitivity map itself.

We also test transfer. Allocations tuned on DINOv2 are evaluated on DeiT-S and ResNet-50, because the pipeline's real model is unknown to the share creator.

Baselines

The naive reference is the cover itself, which sets the ceiling for fidelity and the floor for detection. Beside it sits uniform-random allocation at equal payload, the "do nothing clever" share.

The strongest existing allocation method on this question is LC-saliency allocation from Cheng et al. It is the only published scheme that chooses where bits go by a notion of importance, and it is exactly the scheme our first hypothesis predicts will hurt ViTs. We run it at identical payload, threshold, and covers. We confirm our reimplementation by reproducing its reported average SSIM of 0.2817 on grayscale covers before extending to color. Beating it means one of two outcomes:

  • equal or better SSIM and UQI with lower attention divergence and higher top-1 agreement on held-out ViTs;
  • equal SSIM with warden detection closer to chance.

The strongest defense-side competitor is Robustness Tokens. It appends about 10 learned tokens to a frozen ViT, trained in 200 steps to realign perturbed features with clean ones. It reports recovering DINOv2-Giant from 0.3% to 63.1% ImageNet accuracy under white-box attack, and ADE20K mIoU from 4.7 to 23.3. We train these tokens on shares-versus-cover pairs with the same image budget our allocator sees. That tests whether fixing the model is as good as fixing the share.

Full PGD adversarial training of a DeiT-S on shares is a compute-matched upper reference. It is not a practical competitor.

Two ablations isolate the key ingredient. The first inverts LC saliency, placing bits in low-contrast regions. The second uses our allocator with the attention term removed, leaving only the feature term. These tell us whether ViT attention specifically is needed, or whether any "avoid what matters" heuristic suffices.

Why not just…?

Why not just put the bits where LC saliency is lowest? This is the most serious threat. If inverted LC matches our allocator on held-out ViTs, then the transformer-specific part is unnecessary, and we would report that plainly. We expect it to fall short for a known reason. Cheng et al. themselves note that LC misfires on rare pixel values. Pixel contrast also need not track where a network routes information. Patch-Fool picks its targets from layer-5 attention rather than from pixel statistics. The inverted-LC ablation settles this directly.

Why not just use natural-steganography shares, which already look like sensor noise? Diffuse, noise-like modifications are exactly what ViTs tolerate, according to Gu et al. So these shares may already be attention-neutral, and that would weaken the case for our allocator. They require RAW covers and a camera-noise model, though, while most pipelines handle compressed RGB. Our measurement study reports attention drift for this scheme wherever RAW data allows. If it wins there, our contribution narrows to the RGB setting.

Why not just make the downstream model robust with Robustness Tokens or adversarial training? If the pipeline owner cooperates, as with a PIRNet-style cloud service (PIRNet), tokens may simply work, and we treat that as a real outcome. They do not help when the share must pass unremarkably through third-party or warden models that the sender cannot modify. Their authors also note that security rests on the tokens staying secret. Full adversarial training is costly, and it left ViTs more vulnerable than CNNs against Patch-Fool. The token-baseline comparison measures the cooperative case. The held-out-model and warden experiments cover the case tokens cannot reach.

Proposed Experiments

Covers come from three sources:

  • a 2,500-image ImageNet validation subset, following Patch-Fool, for classification agreement;
  • ADE20K, for segmentation drift in mIoU;
  • DIV2K, for high-resolution color covers and a restoration check on shares.

We also include the grayscale portraits, warship, and cars images to anchor comparison with Cheng et al. Every scheme uses the same $(k,n)=(3,5)$ polynomial sharing and payload, and we verify lossless reconstruction for each.

The decisive checks come in three parts, each with a reading if it fails.

  • Hypothesis 1. LC-saliency shares must show significantly larger attention divergence and lower top-1 agreement than uniform shares on DeiT-S and DINOv2. If they do not, the motivating hypothesis is false and the remaining work loses its premise.
  • Hypothesis 2. Our allocator must reduce held-out-model attention drift relative to both LC and inverted LC while keeping SSIM within noise of LC. If inverted LC ties it, we drop the transformer claim.
  • Adaptive warden. The warden's detector accuracy against our shares must not exceed its accuracy against LC shares. If the attention-statistics detector does better on our shares, that confirms the concealment–fidelity tension suggested by the backdoor literature. We would then report the Pareto frontier over $\lambda$ rather than a single winner.

No reported result was found on Lacuna for steganalysis detection rates on meaningful shares. All detection numbers will therefore be established within this study.