Anchor-Tethered Self-Training for Continuous Keystroke Authentication

A continuous authenticator keeps checking, after login, that the person typing is still the account owner. It does this by watching typing rhythm: how long each key is held down and the gaps between keys. People's rhythm drifts with fatigue, mood, practice and new keyboards, so a model fixed at enrollment slowly starts rejecting its own user. The obvious fix is to keep training the model on the user's recent typing. The catch is labels. Nobody marks a typing window as "this really was the owner." Every window the model uses to update itself is labeled by the model's own guess. If an intruder's typing is accepted even a few times, the profile can shift toward the intruder, and after that the intruder is accepted for good.

This proposal treats that situation as a problem of scarce expert labels. The only trustworthy labels a deployed system gets are sparse, cheap verification events: a correct password entry or a device unlock. These play the same role as the anchor lines and scribbles that medical imaging uses to supervise dense segmentation from very little ground truth. The system adapts to drift using the unlabeled stream, but a new window is admitted only if it stays consistent with the anchor-verified windows, not merely with the model's current state. The central question is empirical. Does tethering self-training to sparse anchors give the drift benefit of adaptation without the takeover vulnerability of naive self-updating? And is it better than simply retraining on the anchors alone?

Core Claim

We claim that anchor tethering keeps adaptation safe when verification events are rare. Specifically, each verified event becomes a fixed reference set. Every pseudo-labeled window must fall within a bounded distance of that set, and pseudo-labels are discarded and rebuilt at each new anchor. Under these rules, a free-text continuous authenticator can reduce late-session error relative to a frozen model at low anchor rates, while keeping "profile capture" near the frozen model's level. Profile capture means the rate at which a slowly blending imposter becomes permanently accepted. Naive confidence-gated self-training and window-to-previous-window chaining should both show much higher capture.

The claim is falsified in three cases: if a frozen pretrained encoder shows no measurable drift on multi-session data, if retraining on anchors alone matches the tethered method at every anchor rate, or if tethering does not reduce capture relative to naive self-training.

Where This Sits

The closest prior work is Continual Retraining of Keystroke Dynamics Based Authenticator. It retrains a K-Means profile on moving or growing windows of login attempts that passed both the password check and the keystroke check, lowering error rate from 4.8% to 3.8%. That paper motivates this proposal because it documents drift. It also constrains it, because its gate depends on a password typed at every update. That design works only for fixed-text logins and cannot follow free text between logins. We keep its core idea, the verified event as the source of truth, but use verified events as sparse anchors for supervising the unlabeled free-text stream. We also add the uncertainty filtering that it lacks.

Two free-text continuous systems, Iterative Keystroke Continuous Authentication: A Time Series Based Approach and Accurate Continuous and Non-intrusive User Authentication with Multivariate Keystroke Streaming, use dynamic time warping, an alignment distance between sequences. They compare each 100-keystroke window to the window immediately before it. This is implicit self-supervision by chaining. Each window is judged against a neighbor that was itself judged by its own neighbor, so a gradual imposter never produces a large step. We keep their streaming setting but replace the chain with a tether to verified windows.

Fast Continuous User Authentication Using Distance Metric Fusion of Free-Text Keystroke Data supplies the short-window difficulty that any adaptive method must face. Its fused statistical tests reach 3.6% error rate at 1,000 characters but 35.3% at 100, and it never adapts its enrolled profile. Free-text keystroke authentication using transformers: a comparative study of architectures and loss functions supplies the representation. A Transformer trained with a triplet loss on the Aalto dataset, followed by a one-class support vector machine (a detector fit only on the owner's samples), reaches 0.0163% error rate from 10 enrollment samples. It is evaluated statically, not across drift. This is the strongest threat to the whole premise, and it is taken up directly below.

From the medical side, three papers supply the mechanism. Weakly Supervised Lesion Co-Segmentation on Ct Scans constrains outputs to agree with sparse clinical anchor lines; we borrow the anchor idea. Learning to Segment Medical Images with Scribble-Supervision Alone found that uncertainty estimation was what stopped errors spreading from sparse seeds; we borrow the uncertainty filter. A Semi-Supervised Framework for Cardiac MRI Segmentation via Multi-Constraint Collaborative Self-Training combines confidence/entropy filtering with prototype consistency to curb confirmation bias, reaching 0.730 Dice against 0.654 for Mean Teacher at 5% labels; we borrow prototype consistency.

A fourth paper, Self-Learning to Detect and Segment Cysts in Lung CT Images without Manual Annotation, is a warning. Its self-training rose from 74.67% to 75.87% Dice and then fell to 74.94% on the next round. That result motivates bounding how long pseudo-labels survive, which we do by rebuilding at each anchor.

Research Program

Encoder. A window encoder produces an embedding for each 100-keystroke window of free text. The input features are hold time, flight times, and key position. We retrain the Transformer bi-encoder recipe of the transformer comparative study on Aalto users, keeping them disjoint from all evaluation users. The encoder is then frozen. Only per-user state adapts on-device, which respects the positive-only, privacy-constrained setting noted in Learning Human Identity from Motion Patterns.

Per-user state. Each user has two stores. The anchor set $A$ holds embeddings of windows adjacent to verified events and is never written to by the model. The pseudo set $P$ holds admitted unlabeled windows. The one-class detector and a set of $k$ prototypes are fit on $A \cup P$, with $P$'s total weight capped at a fixed multiple of $A$'s.

Admission rule. A new window with embedding $z$ enters $P$ only if three conditions hold:

$$ s(z) > \tau_t, \quad u(z) < \upsilon, \quad \min_{a \in A} \lVert z - a \rVert \le \rho . $$

Here $s$ is the detector's genuineness score. $\tau_t$ is a threshold that relaxes slowly after each anchor. $u$ is predictive disagreement across small timing perturbations and dropout samples. $\rho$ is a tether radius set from the spread of within-anchor distances. The third condition is the new ingredient: a window can resemble the current, possibly drifted, profile and still be refused because it has left the neighborhood of anything verified.

Re-anchoring. At each verification event, the window is added to $A$ and $P$ is rebuilt by re-scoring stored windows. Pseudo-labels from before the anchor are thereby re-audited against newer ground truth rather than compounding.

Analysis. We will measure how the anchor rate, the radius $\rho$, and the cap on $P$ trade drift tracking against capture. We will also examine whether $\rho$ can be set per user from anchor data alone.

Baselines

Naive reference. The frozen encoder with a one-class detector fit on enrollment windows, never updated, following the recipe of Free-text keystroke authentication using transformers. Its reported number is 0.0163% error rate on Aalto with $E=10$. That is a static, same-period figure. No reported result was found on Lacuna for its performance across later sessions. This is the strongest competitor because, if drift is small in embedding space, it wins outright at zero adaptation cost.

Anchor-only retraining. The same detector refit only on $A$ after each anchor. It is the free-text analogue of the growing and moving windows in Continual Retraining of Keystroke Dynamics Based Authenticator, which reported 3.8% error rate against 4.8% fixed on its fixed-text data.

Naive self-training. Admission on the score condition alone, which removes both the uncertainty filter and the tether.

Chained multivariate DTW as in Accurate Continuous and Non-intrusive User Authentication with Multivariate Keystroke Streaming. Its reported ACB result is 98.39% accuracy with 0.036% false acceptance and 1.936% false rejection, on split halves of recorded sessions.

Majority-rules distance fusion from Fast Continuous User Authentication Using Distance Metric Fusion of Free-Text Keystroke Data, for the short-window regime. Its reported Clarkson II error rates are 3.6% at 1,000 characters, 6.6% at 500, and 35.3% at 100.

Ablations. Tether removed but uncertainty filter kept, which isolates the key ingredient. Uncertainty filter removed but tether kept. Encoder fine-tuning on $P$ instead of profile-only updates.

Fairness. All learned methods share one encoder, the same enrollment windows, the same anchor schedule, and the same hyperparameter search budget. Hyperparameters are tuned on a held-out user split, not on test users. The DTW and fusion baselines are re-run on our sessionized splits rather than quoted, because their reported protocols differ.

What counts as beating them. The tethered method must meet two conditions at anchor rates of one per session or sparser. First, lower error rate on the final third of each user's sessions than both the frozen and the anchor-only baselines, with confidence intervals by user bootstrap. Second, profile-capture rate under slow mimicry not significantly above the frozen model and clearly below naive self-training and chaining.

Why not just…?

Why not just keep the pretrained encoder frozen and never adapt? This is the most serious threat. The 0.0163% figure suggests the embedding may already absorb much of the day-to-day variation. The file contains no multi-session evidence either way for this encoder. The only direct drift evidence, 4.8% versus 3.8%, comes from a fixed-password K-Means model, and the cross-device error increases in DEFT: A new distance-based feature set for keystroke dynamics (3.8% on desktop up to 9.8% on tablet) come from separately trained models, not a drift test. Our first experiment therefore measures frozen-model error as a function of session gap. If that curve is flat, we report that adaptation is unnecessary for this encoder, and the project reduces to a negative result.

Why not just retrain on the verified anchors and ignore the unlabeled stream? This is safe by construction and may be enough when anchors are frequent. The proposal is only worthwhile where anchors are rare and anchor-only refits are starved of data. We sweep the anchor rate from every window down to once per several sessions and report the crossover point. If anchor-only matches the tethered method across the whole sweep, the unlabeled stream adds nothing and we say so.

Why not just compare each window with the previous one, as the DTW systems do? Chaining adapts for free, but it has no fixed reference. A mimic who changes rhythm slowly never produces a large window-to-window distance. The capture experiment below tests this directly. If chaining shows capture no higher than the tethered method, our safety argument fails.

Why not just gate updates on a high detector confidence? That is the naive self-training baseline. Both A Semi-Supervised Framework for Cardiac MRI Segmentation via Multi-Constraint Collaborative Self-Training and the lung-cyst self-learning plateau show that confidence alone lets errors compound. The tether-removed ablation measures how much of this carries over to typing.

Proposed Experiments

Data. Drift and capture experiments use Clarkson II (103 users, 12.9 million keystrokes of natural typing). Its sessions are ordered in time, and verification events are simulated by marking windows at a controlled rate. This simulation is a stated limitation, since the dataset has no real unlock logs. ACB and VHHS provide comparison with the chained DTW systems. SU-AIS BB-MAS tests a within-user device switch as an abrupt drift, where tethering should slow adaptation and the anchor rate should decide recovery time. The Kang et al. login data offers a fixed-text sanity check against the retraining paper's 3.8%.

Metrics. We report equal error rate, the operating point where false acceptance equals false rejection, over early, middle, and late session thirds, at window sizes of 100, 500, and 1,000 characters. For attacks we report time to detection and capture rate.

Attacks. Abrupt takeover splices another user's stream into the owner's session. Slow mimicry uses genuine segments whose timings are gradually shifted toward an imposter's per-digraph distributions over a chosen horizon. It is synthetic, and we report sensitivity to the horizon length.

Decisive checks. Three results decide the project. First, the frozen-model drift curve, which decides whether adaptation matters at all. Second, the tethered-versus-anchor-only crossover in anchor rate, which decides whether the unlabeled stream matters. Third, capture rate for tethered versus tether-removed versus chained, which decides whether the tether is the ingredient that makes self-training safe.

A secondary check is whether adaptation narrows the 100-character gap, using the reported 35.3% as the reference point. This bears on the file's open tension between digraph sparsity and time-series matching.