Original Research
Frontiers in Systems Neuroscience ·
Volume 20 - 2026 | https://doi.org/10.3389/fnsys.2026.1891041
PQ-Neurolink: latency-aware post-quantum-ready secure communication for distributed brain–computer interfaces
- Tariq Qayyum1
- Asadullah Tariq1
- Abdelkader Nasreddine Belkacem1*corresponding author
- College of Computing and Artificial Intelligence, United Arab Emirates University, Al Ain, United Arab Emirates
Abstract
Distributed electroencephalography (EEG) brain-computer interface (BCI) systems increasingly transmit neural data and control messages between a head-worn device, a nearby hub, and cloud-assisted services. These links require integrity, authenticity, replay protection, and low latency, while migration to post-quantum cryptography can increase session-establishment cost. We present PQ-NeuroLink, a latency-aware post-quantum-ready communication framework that separates authenticated session establishment from the symmetric streaming fast path. The design supports classical X25519, post-quantum ML-KEM-768, and hybrid ML-KEM-768 plus X25519 key establishment, with pinned ML-DSA public keys for endpoint identity binding. The prototype was evaluated using EEG-derived traffic from public datasets over BLE-like and Wi-Fi-like link profiles, 1-hop and 2-hop topologies, symmetric key-update and public-key refresh events, active tampering scenarios, and MCU-informed resource and processing-energy projections. Identity pinning and transcript binding prevented successful modeled session-splicing attempts. Post-quantum and hybrid modes primarily increased handshake bytes rather than steady-state streaming latency. In the most constrained BLE 1-hop summary condition, the hybrid M3 mode increased p95 latency by 0.45 ms relative to the unsecured M0 baseline while maintaining 99.0% packet delivery. Post-quantum-ready authenticated session establishment can be integrated into distributed EEG communication prototypes when public-key operations are kept off the per-frame path. PQ-NeuroLink provides a reproducible communication-layer basis for secure next-generation BCI deployment studies requiring low-latency operation and long-horizon post-quantum protection.
Keywords
1 Introduction
Brain–computer interfaces (BCIs) are steadily moving beyond laboratory demonstrations toward systems capable of supporting real actions, such as controlling a prosthetic or robot, selecting commands in assistive software, and providing rapid feedback to the user (Shanechi, 2019; Edelman et al., 2025). Among the available modalities, non-invasive electroencephalography (EEG) is especially attractive because it is relatively low-cost, portable, and already compatible with practical deployment pipelines in which a head-worn device streams neural signals to a nearby hub, such as a phone, tablet, or edge device, and in some cases onward to a cloud service for more computationally intensive processing (Schalk et al., 2004). At the same time, BCI systems are becoming increasingly closed-loop: the system senses brain activity, decodes user intent or state, and then immediately adapts what the user sees, hears, or feels, or adjusts stimulation in therapeutic settings (Zrenner et al., 2016; Soleimani et al., 2023; Topalovic et al., 2023). In such systems, timing is not a secondary implementation detail; it directly affects responsiveness, stability, usability, and, in some applications, safety.
While much of the BCI literature emphasizes signal quality, feature extraction, and decoding accuracy, practical deployment also depends critically on trustworthy communication. In a typical EEG-to-hub-to-cloud pipeline, the exchanged traffic may include raw or processed neural data, device state information, model outputs, and high-level control messages that trigger downstream actions. If an adversary can observe, modify, delay, or replay these messages, the closed loop can be disrupted, commands can be altered, and user feedback can become unreliable, which is especially concerning for assistive control and other safety-critical interactions (Bonaci et al., 2015). Prior work on BCI security and neurotechnology privacy has already highlighted risks across the BCI lifecycle, including malware exposure, data leakage, and integrity violations, and has argued for systematic security engineering rather than ad hoc protection mechanisms (Lopez Bernal et al., 2021). Nevertheless, most communication security deployed today still relies on classical public-key cryptography, such as RSA or elliptic-curve techniques, for authentication and key establishment.
This reliance on classical public-key mechanisms is becoming increasingly problematic because sufficiently large-scale quantum computers would break the assumptions underlying widely deployed schemes, thereby motivating the ongoing migration toward post-quantum cryptography (PQC). In response, NIST has standardized core post-quantum primitives, including ML-KEM for key establishment and ML-DSA for digital signatures (National Institute of Standards and Technology, 2024a,b). In many networked systems, the emerging practical pattern is to use PQC, often together with classical techniques in a hybrid migration mode, during session establishment, and then rely on efficient symmetric encryption for the sustained data path. For distributed EEG-based BCI communication, this suggests a natural architectural separation: an authenticated session setup between the head device and the hub, potentially extended to a cloud endpoint when needed, followed by a predictable low-overhead streaming phase in which EEG frames and control messages are protected using symmetric authenticated encryption. Rekeying can then be incorporated as a security-maintenance mechanism without placing expensive public-key operations on the continuous real-time path.
The central research gap is that BCI communication is inherently latency-sensitive, whereas PQC may increase handshake message size, computation time, memory pressure, and energy cost on constrained platforms. Even when PQC is confined to session establishment, reconnects, mobility, transient packet loss, and deliberate rekey policies can make the security layer visible to the user in the form of added setup delay, timing variance, or disrupted continuity. More fundamentally, BCI latency is not merely a decoder-side algorithmic quantity; it is an end-to-end systems property that includes sensing, buffering, wireless transmission, security processing, forwarding, and actuation. Prior work has shown that BCI latency can be measured and decomposed, but the literature still lacks a broadly adopted security-aware latency framework that connects representative BCI operating scenarios to explicit timing requirements and then evaluates whether contemporary PQC-capable communication designs can satisfy those constraints in practice (Wilson et al., 2010).
This paper addresses that gap by focusing on the head device-to-hub connection as the most exposed and timing-critical segment of the pipeline, while treating cloud connectivity as an optional extension for applications that require remote computation or storage. The study isolates the secure-channel layer through controlled EEG-derived traffic replay, enabling each protocol mode to be evaluated under identical packetization, loss, delay, reordering, topology, and attack assumptions. This design makes the latency and security effects attributable to the communication framework itself and provides a reproducible basis for subsequent platform-specific integration.
The paper establishes practical end-to-end latency and jitter targets for representative closed-loop EEG-based BCI use cases, grounding these targets in reported BCI timing measurements and relevant neuroscience constraints, and it formalizes a threat model covering integrity, authenticity, replay, impersonation, downgrade, compromised intermediary, cloud/API compromise, and future quantum-capable adversaries across the head–hub–cloud path. Building on these requirements, the paper presents and evaluates PQ-NeuroLink, a post-quantum-ready secure communication design with explicit symmetric key-update and public-key refresh policies intended to preserve security assurances within tight timing budgets. Public EEG datasets, including inner-speech resources, are used to generate traffic patterns, payload sizes, and update rates for a reproducible communication-layer evaluation. The main contributions of this paper are as follows:
- A BCI-specific secure-channel profile that separates authenticated session establishment from the low-latency streaming path, with explicit sequence, epoch, replay-window, and safe-mode behavior for EEG and feedback messages.
- A post-quantum-ready channel design with classical, post-quantum, and hybrid key-establishment modes, downgrade-resistant transcript binding, and clearly separated symmetric key updates vs. less frequent public-key refresh.
- A reproducible trace-driven evaluation methodology that uses public EEG datasets for traffic replay only, enabling controlled comparison of unsecured, classically secured, post-quantum, and hybrid communication modes under consistent link and topology assumptions.
- A systems-security analysis that combines latency percentiles, deadline miss rates, handshake wire size, amortized refresh cost, MCU-informed resource and processing-energy projection, statistical testing methodology, and a structured mapping between the threat model and the evidence provided by experiments or analytical arguments.
The novelty is therefore not the invention of a new cryptographic primitive or a replacement for TLS 1.3, QUIC, WireGuard, or IPsec. Rather, PQ-NeuroLink contributes a BCI-specific secure-channel profile and evaluation framework that binds PQC/hybrid session establishment, replay-aware packet acceptance, two-tier key maintenance, safety fallback, and EEG-derived latency budgets into a single communication-layer design. The remainder of the paper reviews related work on EEG–based BCI timing, neurotechnology security, secure healthcare/IoT networking, and post-quantum transport; defines the system model, latency and jitter metrics, and threat model; presents the PQ-NeuroLink architecture; describes the experimental setup; reports the performance, security, and analytical resource evaluation; and concludes with discussion and deployment considerations.
2 Related work
Electroencephalography-based brain-computer interfaces translate neural activity into device commands, typically through a pipeline that includes signal acquisition, preprocessing, feature extraction, decoding, and feedback to the user or actuator. Recent reviews emphasize that non-invasive EEG BCIs are moving beyond lab demonstrations into more realistic human-computer interaction, assistive control, and rehabilitation settings, but robustness, timing, and deployment constraints remain major barriers (Edelman et al., 2025; Hamad et al., 2024; Chen et al., 2020; Belkacem and Lakas, 2021). In parallel, new EEG decoders (often deep learning based) are enabling finer control granularity and more continuous interaction, including real-time robotic and prosthetic-like control loops (Skomrock et al., 2018). These advances make the BCI pipeline look increasingly like a safety-relevant cyber-physical system: brain-derived control signals are transmitted to devices, and devices return feedback (visual, haptic, or stimulation) that shapes subsequent brain activity, closing the loop (Thompson et al., 2014; Zrenner et al., 2016).
Latency and timing jitter are well-known determinants of BCI usability and learning. Standard performance measurement guidance in the BCI literature highlights that accuracy alone is not enough; timing, information transfer, and feedback dynamics directly affect end-to-end performance (Thompson et al., 2014). Several works provide procedures or empirical observations for measuring timing in BCI systems. (Wilson et al. 2010) proposed a procedure to measure component-wise and end-to-end latencies and jitter in typical online BCI configurations, and neural engineering studies have emphasized that stimulation, recording, and communication dynamics must be characterized explicitly rather than hidden inside aggregate performance metrics (Bossetti et al., 2004). More recent neuroimaging and EEG platforms emphasize that low and stable latency is necessary for real-time neurofeedback and brain-state dependent interaction, with modern open pipelines reporting tens of milliseconds end-to-end for EEG processing and feedback (Levitt et al., 2023). For specific EEG paradigms, feedback timing also affects performance; for example, P300 speller feedback frequency and timing influence ERP separation and task outcomes (Arvaneh et al., 2015). These timing studies motivate the engineering latency budgets used for the communication framework.
Security and privacy risks for BCIs have been discussed for more than a decade, with a key theme being that neural data and neural control channels carry sensitive information and can be misused. (Bonaci et al. 2015) framed BCI platforms as potential “app stores for the brain” and argued that neural signals and their derived commands require privacy and security protections across the full device-to-software lifecycle. (Lopez Bernal et al. 2021) provided a systematic security view of the BCI lifecycle and identified attack surfaces across acquisition, processing, communication, and application layers. Empirical work has demonstrated concrete risks: side-channel style EEG attacks can leak private information (such as PIN-related responses) from brain signals (Martinovic et al., 2012; Lange et al., 2018). Broader neurotechnology security discussions also connect these threats to safety and security applications and risks in operational environments (Brocal, 2023; Ienca and Haselager, 2016). While some recent work explores security at the wireless physical layer for brain-to-device communication using novel coding and metasurface-assisted approaches (Xiao et al., 2025), cryptographic end-to-end integrity and authentication across realistic BCI head-device to hub to cloud pipelines remains under-standardized, especially when considering future post-quantum adversaries.
Related healthcare and IoT security work reinforces the need to consider post-quantum migration together with constrained-device operation and network-layer attacks. A recent 6G smart-hospital architecture argues for multi-layer post-quantum protection in latency-critical medical infrastructures (Devaraj et al., 2026). In low-power IoT and RPL/6LoWPAN networks, routing-layer threats such as blackhole, lowered-rank, version-number, and flooding attacks are difficult to mitigate using cryptography alone, motivating simulation-driven and machine-learning-assisted detection approaches (Panda and Muthuraman, 2026; Panda and Supriya, 2023). Although these works do not target BCI telemetry, they are relevant because wearable EEG systems share several deployment constraints with medical IoT: intermittent wireless links, limited energy, constrained memory, and the need for safe behavior under routing or gateway compromise. Similarly, application-layer systems that combine phishing detection with cryptographic verification illustrate a broader pattern of combining data-driven detection with authenticity checks; this is cited only as a general cybersecurity example rather than as a BCI baseline (Reddy et al., 2025). Table 1 presents the comparison of timing, security and post-quantum coverage.
Table 1. Comparison of timing, security, and post-quantum coverage.
| Work | EEG | Loop | Latency | Threat | Crypto | PQC | Rekey |
|---|---|---|---|---|---|---|---|
| (Wilson et al. 2010) | Y | Y | Y | N | N | N | N |
| Bossetti et al. (2004) | Y | Y | Y | N | N | N | N |
| (Thompson et al. 2014) | Y | Y | Y | N | N | N | N |
| (Skomrock et al. 2018) | Y | Y | Y | N | N | N | N |
| (Bonaci et al. 2015) | Y | Y | N | Y | Partial | N | N |
| (Lopez Bernal et al. 2021) | Y | Y | Partial | Y | Y | N | N |
| (Martinovic et al. 2012) | Y | N | N | Y | N | N | N |
| Lange et al. (2018) | Y | N | N | Y | N | N | N |
| (Xiao et al. 2025) | Y | Y | Partial | Y | Physical layer | N | N |
| PQ-NeuroLink | Y | Y | Y | Y | Y | Y | Y |
Bold entries identify the proposed PQ-NeuroLink framework and the capabilities supported by the proposed framework.
Post-quantum cryptography (PQC) is becoming concrete through standardization and protocol integration. NIST has standardized key establishment and signatures designed to resist quantum adversaries, including ML-KEM for key encapsulation and ML-DSA and SLH-DSA for signatures (National Institute of Standards and Technology, 2024a,b,c). Internet security protocols are actively adopting hybrid and post-quantum transitions; TLS 1.3 defines a modern handshake and supports key updates for ongoing sessions (Rescorla, 2018), QUIC integrates TLS 1.3 and defines secure packet protection and update mechanisms (Thomson and Turner, 2021), and the IETF has standardized terminology for PQ/traditional hybrids (Internet Engineering Task Force, 2025). Implementations and benchmarks show that PQC can be practical on constrained devices, but handshake costs and message sizes can be significant compared to classical elliptic-curve key exchange, motivating careful engineering and hybrid approaches (Kannwischer et al., 2019; Stebila and Mosca, 2017; Schwabe et al., 2020).
For the embedded-device interpretation in Sections 3.3.4 and 4.7.1, we use the PQM4 framework and its current Cortex-M4 benchmark tables as cycle- and stack-level references rather than transferring the measured ARM64 execution times directly to a wearable power model. The PQM4 data are combined with representative active-current specifications for the 64-MHz nRF52840 and the 80-MHz STM32L4A6. This separates the measured hub-class results from a wearable-class projection in which execution time and CPU-processing energy are derived from the target clock frequency, supply voltage, and active current.
Table 2 clarifies how PQ-NeuroLink differs from existing general secure transports. The proposed framework should be interpreted as a BCI-specific secure-channel profile and evaluation methodology that can reuse ideas from TLS, QUIC, WireGuard, or IPsec, rather than as a claim that those mature protocols are inadequate in general. The distinction is that PQ-NeuroLink explicitly binds the protocol state variables needed by BCI telemetry—session identifier, epoch, message type, sequence number, timestamp policy, replay window, key-update cadence, and safe-mode transition—to EEG-derived latency budgets and trace-driven packetization.
Table 2. Comparison with general secure transports and PQC-enabled transport directions.
| System | Identity and key establishment | Streaming protection | Key update/refresh | BCI-specific support | Role in this paper |
|---|---|---|---|---|---|
| TLS 1.3 | Certificate/PSK; classical by default, PQ/hybrid groups emerging | Record protection over reliable stream | TLS Key update | No EEG traffic model or safe-mode semantics | Baseline and design reference |
| QUIC | TLS 1.3 handshake and transport parameters | Packet protection over UDP | QUIC key update | No explicit BCI deadline or replay policy | Baseline for datagram-like secure transport |
| WireGuard | Static public keys and Noise-style handshake | AEAD datagrams with counters | Timer/counter-based rekey | No PQC by default and no BCI safety interface | Low-overhead classical baseline |
| IPsec/IKEv2 | PKI/PSK with IKE negotiation | Packet-level ESP protection | Security-association rekey | No EEG-specific latency profile | Network-layer baseline |
| PQ-TLS / KEMTLS directions | PQC or hybrid KEM/signature integration | TLS record or QUIC packet protection | Protocol-specific key update | Not specialized for EEG frame cadence | Cryptographic migration context |
| PQ-NeuroLink | Classical, ML-KEM, or hybrid establishment with pinned ML-DSA identity in the evaluated profile | AEAD with sid/epoch/type/sequence/timestamp associated data | Frequent symmetric key update and infrequent ML-KEM refresh | EEG-derived traffic, BCI deadlines, replay window, safe mode, and threat-evidence mapping | Proposed BCI communication-layer profile |
A notable gap across these literatures is that BCI research has rigorous methods to measure and reason about latency and jitter (Wilson et al., 2010; Thompson et al., 2014), and security research has detailed threat surfaces and early demonstrations of neural data leakage and misuse (Bonaci et al., 2015; Lopez Bernal et al., 2021; Martinovic et al., 2012). PQC research provides standardized primitives and evolving protocol guidance (National Institute of Standards and Technology, 2024a; Rescorla, 2018; Internet Engineering Task Force, 2025). However, there is limited work that unifies (i) a closed-loop EEG–based BCI latency budget and acceptance framework, (ii) a realistic threat model including integrity of brain-to-device commands and device-to-user feedback, and (iii) an end-to-end post-quantum (or hybrid) security protocol design that is explicitly optimized to stay within those latency bounds.
3 Materials and methods
3.1 System model
We model an EEG-based BCI as a closed-loop cyber-physical pipeline comprising three components, a head-worn device D, responsible for signal acquisition and optional lightweight preprocessing, a nearby hub H, which performs decoding and application logic, and optional cloud services C, used for computationally intensive inference, storage, personalization, or model updates. Communication is bidirectional. The uplink carries EEG frames, extracted features, decoder outputs, and control-relevant messages, while the downlink carries feedback, actuation acknowledgments, user-interface updates, haptic signals, or stimulation parameters. In this setting, the integrity and authenticity of command and feedback traffic are safety-critical, while confidentiality protects neural privacy and reduces long-horizon “harvest-now, decrypt-later” exposure (Martinovic et al., 2012). A list of notations used throughout this paper is provided in Table 3. Figure 1 illustrates the overall secure closed-loop architecture: EEG signals are acquired and optionally preprocessed on the user side, then authenticated and encrypted before transmission. A secure communication hub performs session establishment, message encryption and decryption, integrity verification through AEAD-based authentication and tamper detection, and attack monitoring. The backend server supports data storage and task processing, runs the AI model and command detector, and returns feedback or control signals, while security logging and alerting are coordinated through the BCI control center.
Table 3. List of notation and symbols.
| Symbol | Meaning (units) |
|---|---|
| f*s* | EEG sampling rate (Hz) |
| C | Number of EEG channels |
| T*f* | Streaming frame duration / period (s) |
| W*f* | Samples per channel per frame, W*f* = ⌊f*s*T*f*⌋ |
| W | Decoder window duration (s) |
| T*u*/f*u* | Decoder update period / rate (s, Hz), f*u* = 1/T*u* |
| B | Acquisition block duration (s) |
| Bτ | Payload size for message type τ (bytes) |
| B*hdr* | Protocol header bytes (bytes) |
| B*tag* | AEAD tag bytes (bytes) |
| B*wire* | On-wire bytes per protected packet (bytes) |
| tievent | Time of task-relevant neural event for update i (s) |
| tiact | Time at which the command is applied at the actuator/application for update i (s) |
| tiper | Time at which feedback is perceived or stimulation is delivered for update i (s) |
| Lcmd(i) | Command latency for update i (s) |
| Lfb(i) | Feedback latency for update i (s) |
| Lloop(i) | Closed-loop latency for update i (s) |
| J | Jitter metric (s), representing latency or inter-arrival dispersion |
| Q*p*(·) | p-Quantile operator (e.g., Q0.95 denotes p95) |
| Lmax(p) | Application tail-latency budget at quantile p (s) |
| Jmax(p) | Application tail-jitter budget at quantile p (s) |
| LAEAD | Per-packet AEAD compute overhead (s) |
| Lreplay | Per-packet replay-check overhead (s) |
| C*r* | Transient cost of a rekey/refresh event (s) |
| ρ | Fraction of updates affected by rekey/refresh, ρ≪1 |
| 1*r*(i) | Indicator that rekey/refresh affects update or frame i |
| sid | Random session identifier |
| epoch | Traffic-key epoch counter |
| s*i* | Per-direction sequence number (monotone counter) |
| R | Replay-window size (packets) |
| Δ*t* | Optional timestamp acceptance bound (s) |
| fosc | Oscillation frequency for phase-locked loops (Hz) |
| VDD | Processor supply voltage used for the MCU projection (V) |
| Iact | Active processor current under the selected workload (A) |
| fclk | Target microcontroller clock frequency (Hz) |
| Cop | Benchmark cycle count for a cryptographic operation (cycles) |
| Pact = VDDIact | Active processor power used for device-specific energy projection (W) |
| Eop | Estimated CPU-processing energy for one cryptographic or key-update operation (J) |
| Mpeak | Peak working memory of a cryptographic operation or protocol phase (bytes) |
| Nsafe | Consecutive missed or stale critical updates required to enter SafeMode |
| Nrec | Consecutive valid critical updates required for recovery from SafeMode |
| TTSS | Time from the last valid critical update to application of the safe-state command (s) |
| Tlocalsafe | Local actuator or stimulation shutdown time after SafeMode is issued (s) |

The architecture in Figure 1 serves as a reference communication architecture. In the evaluation, D, H, and C are instantiated as logical roles in the prototype so that protocol state binding, key maintenance, replay protection, and latency effects can be measured under controlled and repeatable conditions. This separation keeps the analysis focused on the secure-channel layer while remaining compatible with later integration into specific EEG headsets, hubs, and cloud services.
3.1.1 Communication model and latency requirements
We next define per-update timestamps and latency variables, decompose the closed loop into measurable components, express requirements as tail constraints, and derive budgeting and feasibility relations that connect component-level tail behavior and rekey spikes to end-to-end closed-loop guarantees. This formulation is consistent with established BCI timing and performance-measurement methodology (Thompson et al., 2014).
We distinguish message types τ∈T in Equation 1: The head device forms streaming frames of duration T*f* seconds, yielding W*f* = ⌊f*s*T*f*⌋ samples per channel in Equation 2. If samples are transmitted using b bits/sample, the raw EEG payload size is: Feature frames of dimension d with b*f* bits/value have size in Equation 3: A protected on-wire packet carrying payload Bτ bytes has approximate size:
T={EEG,FEAT,DEC,CMD,FB,CTRL}.(1)
BEEG=C·Wf·b8.(2)
BFEAT=d·bf8.(3)
Bwire(Bτ)≈Bhdr+Bτ+Btag+Blink,(4)
B*link* in Equation 4 captures link- and transport-layer overhead, such as BLE ATT framing or UDP/IP headers. If packets of type τ are sent every Tτ seconds, the corresponding application-level bitrate contribution in Equation 5 is: Let, tievent in Equations 6–8 denote the time of a task-relevant neural event, or an equivalent reference time, for update i. Let, tiact denote the time at which the corresponding command is applied at the actuator or application, and let, tiper denote the time at which feedback is perceived or stimulation is delivered. We then define: To support engineering analysis, we decompose the command path into nonnegative components: Here, acquisition and buffering capture sampling, windowing, block formation, and queueing; processing captures preprocessing and decoder inference; network captures medium access, retransmissions, and routing; security captures per-packet AEAD overhead together with episodic rekey or refresh effects; and actuation captures UI, haptic, or stimulation output. The decomposition in Equation 9 follows standard BCI latency measurement practice while making the security contribution explicit (Bossetti et al., 2004).
Rτ≈8·Bwire(Bτ)Tτ (bits/s).(5)
Lcmd(i)=tiact-tievent,(6)
Lfb(i)=tiper-tiact,(7)
Lloop(i)=tiper-tievent=Lcmd(i)+Lfb(i).(8)
Lcmd(i)=Lacq(i)+Lbuf(i)+Lproc(i)+Lnet(i)+Lsec(i)+Lact(i).(9)
We report jitter in two complementary ways: as dispersion in end-to-end loop latency and as irregularity in update arrivals. Define tail-based latency jitter as: and inter-arrival jitter at the hub as follows. Let a*i* denote the arrival time of update or frame i at the hub; then: These two notions capture different operational concerns: phase-locked stimulation and neurofeedback emphasize inter-arrival regularity, whereas general closed-loop control places greater emphasis on tail end-to-end latency (Zrenner et al., 2016).
JL(p)≜Qp(Lloop)-Q0.5(Lloop),(10)
Δai=ai-ai-1, JA(p)≜Qp(Δa)-Q0.5(Δa).(11)
We express application requirements as quantile constraints, typically for p∈{0.95, 0.99}: This choice reflects the fact that closed-loop BCI usability is governed more by latency and jitter tails than by mean values (Thompson et al., 2014).
Qp(Lloop)≤Lmax(p), Qp(J)≤Jmax(p).(12)
If the decoder uses a causal window of duration W and acquisition emits blocks of duration B, then the acquisition latency has the conservative lower bound: The W2 term in Equation 13 reflects the use of window-centered evidence common in stable online feature extraction, while B accounts for block availability. This relation provides a necessary feasibility check: no optimization in the communication or security stack can reduce end-to-end latency below the lower bound imposed by windowing and acquisition structure.
Lacq≳W2+B.(13)
For tail budgeting, let Lcmd=∑k=1KLk denote the sum of K nonnegative components corresponding, for example, to acquisition, buffering, processing, networking, security, and actuation. Choose component budgets ℓ*k*≥0 and violation probabilities ε*k* such that, and enforce By a union bound, Pr[Lcmd>Lmax(p)]≤1-p, and therefore Qp(Lcmd)≤Lmax(p). This turns qualitative “latency budgeting” into a concrete engineering procedure: measure the tail behavior of each component and allocate slack where it is most effective or least expensive.
∑k=1Kℓk=Lmax(p) and ∑k=1Kεk≤1-p,(14)
Pr[Lk>ℓk]≤εk ∀k.(15)
3.1.1.1 Phase error constraint for oscillatory closed-loop tasks.
For phase-locked stimulation and oscillatory coupling, loop delay induces a phase error as in Equation 16: This directly connects physiology-driven phase constraints to an explicit tail-latency budget (Zrenner et al., 2016).
Δϕ=2πfoscLloop,(16)
Qp(Δϕ)≤ϕmax(p) ⇔ Qp(Lloop)≤ϕmax(p)2πfosc.(17)
3.1.2 Security overhead as a fast path plus rare spikes
We model the security contribution to latency as the combination of a small per-packet overhead on the streaming fast path and rare transient costs caused by rekey or refresh events on the control plane. This abstraction makes it possible to state sufficient conditions under which security processing remains compatible with the same tail constraints imposed on the overall closed loop.
The per-update security delay is modeled as: where LAEAD denotes the per-packet AEAD computation time, Lreplay(R) captures replay-protection bookkeeping as a function of replay-window size R, and C*r* captures the transient work associated with a rekey or refresh event in Equation 18.
Lsec(i)=LAEAD(τi,Bτi)+Lreplay(R)+1r(i)Cr,(18)
A latency-safe rekey policy must satisfy the same tail constraint as the overall loop: Let ρ denote the fraction of updates affected by rekey or refresh events in Equation 19, with ρ≪1 in the intended operating regime. A conservative sufficient condition is: which guarantees that even if all spike-affected updates fall within the worst (1−p) fraction of the latency distribution, the p-quantile remains bounded in Equation 20. This formulation is intentionally conservative, but it is useful because it gives an implementation-independent way to reason about rare rekey transients without requiring strong distributional assumptions.
Qp(Lloop)≤Lmax(p) even when rekey/refresh events occur.(19)
Qp(Lloop∣1r=0)+Cr≤Lmax(p) and ρ≤1-p,(20)
3.1.3 Threat model
We next specify attacker capabilities and formalize the authenticity and freshness rule that the secure channel must enforce.
The protected assets include raw EEG samples and derived features, such as bandpower summaries, CSP features, and ERP epochs; decoded intents and device-control commands; feedback and control signals, including stimulation parameters where applicable; model artifacts and calibration state; and device identities together with cryptographic secrets. EEG traffic is sensitive because session data may contain health-relevant and identity-relevant information, and prior work has shown that even consumer EEG can, under some conditions, leak private attributes (Martinovic et al., 2012; Bonaci et al., 2015). For closed-loop safety, however, the dominant operational risk is malicious modification or replay of commands and feedback (Lopez Bernal et al., 2021).
We assume attackers may include (i) nearby wireless adversaries that eavesdrop, inject, replay, reorder, or delay packets on the head–hub link; (ii) malware that compromises the hub; (iii) compromise of cloud services or exposed APIs; and (iv) update or supply-chain attackers that target firmware, models, or downgrade paths (Lopez Bernal et al., 2021). Denial-of-service and jamming cannot be prevented by cryptography alone, but the system is required to fail safely under authentication failures, integrity violations, or timing anomalies.
The evaluation evidence is deliberately separated from the threat model. Packet injection, replay, delay, MITM/session-splicing, and downgrade manipulation are modeled directly at the communication layer. Compromised hubs, compromised cloud services, malicious updates, and supply-chain attacks are addressed by architectural controls—key isolation, endpoint pinning, signed updates, rollback protection, audit logging, least-privilege cloud interfaces, and safe-mode policy—but they are not experimentally validated in this trace-driven study. The discussion and security evidence matrix explicitly mark these items as architectural or future-work evidence rather than as completed attack experiments.
Let a command packet be p*i* = (type, payload, t*i*, s*i*) with timestamp t*i* and sequence number s*i*. The receiver applies the following acceptance rule: Here, W(R) denotes a sliding replay window of size R, and Δ*t* is an optional timestamp-acceptance bound. Sequence numbers remain mandatory, whereas timestamps may be omitted when clock synchronization is weak or unreliable.
Accept(pi) = [Auth(pi)=1] ∧ [si∈W(R)]∧ [|ti−thub|≤Δt].(21)
Finally, we include a long-horizon adversary that records encrypted EEG sessions and attempts later decryption or authentication compromise using quantum-capable cryptanalysis. Accordingly, the design targets both active attacks in the present and post-quantum resilience for session establishment and long-lived trust (National Institute of Standards and Technology, 2024a,b,c; Internet Engineering Task Force, 2025). Table 4 presents a summary of the threat model for closed-loop EEG-based Q25 BCI communication, highlighting potential security threats and vulnerabilities across the head device, hub, and cloud components of the system.
Table 4. Threat model summary for closed-loop EEG–based BCI communication across head device, hub, and cloud.
| Attacker class | Example capabilities | Primary security goals |
|---|---|---|
| Nearby wireless attacker | Eavesdrop, inject, replay, reorder, or delay traffic on the head–hub link | Integrity and anti-replay for CMD/FB; confidentiality of EEG in transit |
| Compromised hub | Access to decoded commands, application logic, and keys in memory | Minimize hub trust; safe-mode behavior; auditability |
| Compromised cloud/API | Access to stored EEG, inference outputs, and update channels | Signed updates; least privilege; optional end-to-end encryption |
| Update/supply-chain attacker | Malicious firmware or model update; downgrade attempt | Authenticated updates; rollback protection |
| Downgrade attacker | Force negotiation from M3/M2 to M1/M0 or remove PQ algorithms from the transcript | Signed transcript binding; mandatory mode policy; fail closed on unsupported downgrade |
| Future quantum-capable adversary | Record now and later attempt decryption or signature compromise | PQC/hybrid key establishment; PQ-safe signing |
3.2 System architecture and quantum-safe secure channel
We now translate the system requirements defined in Section 3.1 into a secure channel between the head device D and the nearby hub H, with an optional extension to the hub–cloud segment when remote computation or storage is required. The design follows a post-quantum-ready pattern: use public-key mechanisms primarily during session establishment and identity binding, and then protect the streaming plane using symmetric authenticated encryption so that per-packet latency remains predictable and tail behavior remains stable. This separation is central to the architecture. It allows the protocol to provide strong integrity, replay protection, confidentiality, and post-quantum resilience without placing heavyweight public-key operations on the continuous real-time EEG and feedback path.
3.2.1 Protocol requirements derived from the model
We next derive concrete protocol requirements from the timing and threat model in Section 3.1. The goal is not only to provide confidentiality, integrity, authenticity, and anti-replay protection, but to do so in a manner that respects the tail-latency and rekey constraints expressed in Equations 12, 19. In particular, the secure channel must preserve the timing discipline of the closed loop while ensuring that command and feedback traffic remain strongly protected against tampering, replay, impersonation, and session splicing.
Accordingly, the protocol is required to provide: (i) integrity and authenticity for all message classes, with stricter freshness guarantees for CMD and FB traffic; (ii) anti-replay protection using monotone sequence numbers and a bounded sliding window; (iii) confidentiality for EEG and derived data while in transit; (iv) forward secrecy and post-quantum resilience for session establishment and long-lived trust; (v) rekey behavior that does not stall or destabilize the real-time stream; and (vi) fail-safe behavior under authentication failure, replay detection, or severe timing anomalies.
To support comparative evaluation, we define four security modes, summarized in Table 5. M0 is an unsecured baseline used only for comparison. M1 represents a classical secure-channel baseline. M2 is a post-quantum-only mode in which session establishment is based on ML-KEM and endpoint identity is bound using pinned ML-DSA public keys. M3 is a hybrid mode in which a classical ECDHE secret and an ML-KEM secret are combined during session establishment, while identity is again bound using pinned ML-DSA keys in the evaluated design. In all secured modes, the streaming data plane uses AEAD with explicit sequence numbers and replay-window enforcement.
Table 5. Security modes used for evaluation and deployment.
| Mode | Key establishment | Authentication | Streaming protection |
|---|---|---|---|
| M0 | None | None | None |
| M1 | Classical ECDHE | Classical signatures or PSK | AEAD, seq, and replay window |
| M2 | ML-KEM | ML-DSA (pinned) | AEAD, seq, and replay window |
| M3 | Hybrid ECDHE + ML-KEM | ML-DSA (pinned) | AEAD, seq, and replay window |
These modes capture the deployment progression most relevant to practice: from no transport protection, to classical protection, to PQ-only establishment, and finally to a hybrid migration mode that retains classical and post-quantum contributions during the transition period. Because all secured modes share the same low-latency symmetric data plane, the main performance differences are expected to appear during session setup, refresh, and rare control-plane events rather than during steady-state packet delivery.
3.2.2 Message protection, acceptance, and replay defense
We now define the packet format, AEAD protection rule, nonce discipline, and replay-window semantics that implement the acceptance rule in Equation 21. The design objective is to make the streaming path simple, deterministic, and easy to validate under strict timing requirements.
Each application message is represented as: where sid is a random session identifier, epoch identifies the active traffic-key epoch, τ*i* denotes the message type, s*i* is a monotonically increasing per-direction sequence number, t*i* is an optional timestamp, and x*i* is the plaintext payload in Equation 22.
mi=(sid,epoch,τi,si,ti,xi),(22)
Each message is protected using AEAD in Equation 23: where the associated data contains all header fields that must be integrity-protected, at minimum sid, epoch, τ*i*, s*i*, and optionally t*i*. Nonce uniqueness is enforced by the pair (epoch, s*i*), with s*i* strictly increasing for each direction and each traffic key. This keeps nonce generation deterministic and avoids the need for randomness on the fast path.
ci←AEAD.Enc(Kepoch,n(epoch,si),aadi,xi),(23)
The receiver accepts a message only if decryption succeeds and the message is fresh: where W(R) is a sliding replay window of size R, and the timestamp term is enforced only when timestamp validation is enabled. Let smax denote the largest accepted sequence number in the current epoch. Then a newly received sequence number s*i* is eligible if and only if: This rule provides deterministic replay rejection together with bounded tolerance to packet reordering. In particular, packets that arrive slightly out of order can still be accepted as long as they fall within the permitted window and have not previously been processed. This is important for wireless settings in which reordering may occur transiently even when there is no active adversary.
Accept(mi)=[AEAD.Dec≠⊥]∧[si∈W(R)]∧[|ti-tH|≤Δt],(24)
si>smax-R and si∉(already-received set in the window).(25)
The use of (sid, epoch, ands*i*) also prevents accidental state confusion across reconnects and refresh events. A packet protected under an older epoch cannot be replayed into a later epoch without failing AEAD verification or replay-window checks, and packets from one session are not accepted under another session identifier. This state binding is especially important in closed-loop systems because silent cross-session reuse could otherwise manifest as incorrect commands or feedback rather than as an obvious transport failure.
3.2.3 Key establishment, key schedule, and rekey strategy
We next define the session-establishment procedure for M1, M2, and M3, together with the key schedule and the two-tier rekey strategy that keeps public-key work off the streaming fast path.
The protocol supports classical, post-quantum, and hybrid session establishment. In M1, the shared secret is derived from a classical ECDHE exchange. In M2, the session secret is derived from an ML-KEM shared secret (National Institute of Standards and Technology, 2024a). In M3, a classical ECDHE shared secret and an ML-KEM shared secret are combined in accordance with hybrid migration guidance (Internet Engineering Task Force, 2025). Endpoint authentication is performed using pinned public keys, specifically ML-DSA keys in the evaluated PQ and hybrid modes, so that session establishment is bound to stable endpoint identity and is resistant to impersonation and session-splicing attacks (National Institute of Standards and Technology, 2024b). This pinning model is appropriate for device–hub relationships in which endpoints are provisioned in advance and where certificate-chain processing would add unnecessary handshake complexity.
The design also makes downgrade resistance explicit. The negotiated mode, supported algorithm list, endpoint identities, ephemeral public values, ML-KEM ciphertext or classical ECDHE share, transcript hash, session identifier, role labels, and protocol version are included in the signed transcript and in the HKDF context string. A receiver configured to require M2 or M3 fails closed if an attacker removes PQC algorithms, substitutes a lower mode, replays an older negotiation, or changes the advertised key-update policy. This states the concrete channel-binding rule used by implementations and provides a direct basis for symbolic verification.
3.2.4 Key provisioning, lifecycle, and revocation
Pinned ML-DSA public keys are embedded in a broader identity lifecycle model. During manufacturing or clinical enrollment, each headset or hub receives a device identity key, preferably generated in a secure element or trusted execution environment when available. During pairing, the hub stores the headset public-key fingerprint and a human-verifiable device identifier. Clinical or home deployments maintain an authorization registry mapping patients, headsets, hubs, and cloud services. Revocation is handled by removing the device fingerprint from the registry, distributing signed revocation lists or short-lived authorization tokens to hubs, and forcing re-enrollment after suspected compromise. Identity keys are rotated on a scheduled basis or after compromise, while traffic keys are updated through the symmetric and PQ refresh mechanisms described below. Audit logs record enrollment, revocation, failed authentication, downgrade attempts, firmware/model updates, and safe-mode transitions. This lifecycle model connects the pinned-key prototype to scalable device enrollment, revocation, and recovery procedures.
3.2.5 Algorithm selection and cryptographic agility
The evaluated profile uses ML-KEM-768 because it provides a balanced category-3 key-establishment option, while ML-DSA-44 is used as a lower-overhead pinned identity signature in the prototype. The design is algorithm-agile: ciphersuite identifiers, transcript binding, and policy checks allow category-aligned or higher-assurance variants to be introduced without changing the streaming packet format. Deployments requiring category-3 authentication can select ML-DSA-65, while category-5 deployments can evaluate ML-KEM-1024 with ML-DSA-87 or SLH-DSA parameter sets. HQC is treated as a future backup KEM candidate because it was selected by NIST as a backup post-quantum encryption/key-establishment direction after the initial ML-KEM standardization process (National Institute of Standards and Technology, 2025). Table 6 summarizes the rationale for post-quantum parameter selection and deployment options.
Table 6. Post-quantum parameter-set rationale and deployment options.
| Deployment profile | KEM | Signature | Rationale |
|---|---|---|---|
| Constrained prototype | ML-KEM-768 | ML-DSA-44 | Evaluated low-overhead profile; category-3 KEM with compact category-2 identity signature. |
| Category-aligned clinical profile | ML-KEM-768 | ML-DSA-65 | Recommended when category-3 authentication is required for long-lived device identity. |
| High-assurance profile | ML-KEM-1024 | ML-DSA-87 or SLH-DSA | Higher security margin; requires new size, latency, and energy evaluation. |
| Future backup-diversity profile | HQC or hybrid KEM | ML-DSA/SLH-DSA | Code-based backup option for crypto agility and subsequent comparative evaluation. |
In all secured modes, the protocol uses an HKDF-based schedule (Equations 26, 27) consistent with modern transport handshakes: where Z is the session shared secret. Concretely, Z is the classical ECDHE secret in M1, the ML-KEM shared secret in M2, and a hybrid-combined secret in M3. The resulting keys are direction-specific and role-specific, allowing separation between the main traffic plane and the control or rekey plane.
HS←HKDF.Extract(salt0,Z),(26)
(Ktx,Krx,Kctrl)←HKDF.Expand(HS,info),(27)
Rekeying is split into two mechanisms: (i) frequent symmetric key updates, and (ii) less frequent public-key refresh. A symmetric update advances the traffic key with constant cost: triggered by elapsed time Tsym, packet count Nsym, or both. This operation is deliberately lightweight and is suitable for use during ongoing streaming without introducing noticeable disturbance.
Kepoch+1←HKDF.Expand(Kepoch,bci-key-update||epoch),(28)
A post-quantum refresh injects fresh entropy by running a new ML-KEM-based control-plane exchange: where Z′ is a fresh ML-KEM shared secret. The refresh cadence Tpqc is intentionally slower, for example on reconnect, on suspicion of compromise, or at coarse intervals such as tens of minutes, so that public-key processing remains off the per-frame fast path. This two-tier design matches the latency model of Section 3.1: symmetric updates contribute a small constant cost, whereas public-key refresh events are rare, explicit, and measurable control-plane spikes.
MS′←HKDF.Extract(MS,Z′),(29)
Kepoch+1←HKDF.Expand(MS′,info),(30)
A symmetric key update is the inexpensive HKDF-only epoch transition in Equation 28. A public-key refresh is the less frequent ML-KEM-based control-plane exchange in Equations 29–30. A full re-handshake repeats authenticated session establishment after reconnect, policy failure, or suspected state compromise. The generic word rekey is used only as an umbrella term when referring to both symmetric key updates and public-key refreshes.
Algorithm 1 implements an offline, tail-budget-aware parameter search for the secure channel. Given the requirement tuple, including the target quantile p, measured baseline latency distributions for the non-security stages, link loss and reordering statistics, and an AEAD cost model, the algorithm enumerates candidate replay windows R, candidate symmetric update triggers (Tsym, Nsym), and candidate public-key refresh triggers Tpqc. For each configuration, it estimates reordering-induced rejection risk for the selected replay window, predicts the security-delay contribution Lsec(i) under the corresponding rekey and refresh event model, and composes this with the measured or predicted distributions of acquisition, buffering, processing, networking, and actuation to obtain the resulting tail metrics Q*p*(Lloop) and Q*p*(J). Only configurations that satisfy both tail constraints are retained. Among feasible configurations, the algorithm selects the one that maximizes a security-strength score, for example shorter exposure window, lower replay risk, and stronger refresh cadence, minus a performance penalty. The output is therefore a concrete parameter tuple (R, Tsym, Nsym, andTpqc) that is both timing-compliant and security-aware.
Algorithm 1 Tail-budget compliant selection of replay and rekey parameters.
Algorithm 2 specifies the runtime behavior of the secure channel and separates the control-plane handshake from the low-latency streaming data plane. During the control-plane phase, the endpoints derive a shared secret Z, authenticate the peer, derive traffic and control keys, and initialize the session, replay, and safety-watchdog state. During streaming, each message is protected with AEAD and associated data binding (sid, epoch, τ, s, t). Cryptographic or protocol-state violations—including AEAD failure, replay, session mismatch, or epoch inconsistency—cause an immediate SafeMode transition. Timing-only anomalies use a hysteretic watchdog: one missed critical update raises a warning, two consecutive misses suppress new actuation and enter a degraded state, and the default threshold of Nsafe = 3 consecutive missed or stale critical updates enters SafeMode. This distinction tolerates an isolated wireless loss while bounding continued operation under sustained delay or jamming.
Algorithm 2 Quantum-safe secure-channel runtime with bounded safe-state transition.
Let nmiss denote the number of consecutive missed or stale critical updates of type CMD, FB, or CTRL. The default communication policy uses Nsafe = 3: the first miss raises a timing warning while retaining only the latest authenticated state; the second miss enters a degraded state that suppresses new actuation and initiates a controlled hold or neutral transition; and the third consecutive miss enters SafeMode, disables stimulation, and places motor, robotic, or prosthetic control in the predefined neutral, stopped, or locked state. The conservative time-to-safe-state bound is: where T*u* is the critical-update period and Tlocalsafe is the local actuator or stimulation-controller shutdown time. In the evaluated per-frame feedback/acknowledgment configurations, T*u* = T*f*∈{20, 40} ms, so the communication-watchdog component is bounded by 60 or 120 ms from the last valid critical update, before the local safe-state transition is added. A deployment satisfies a system-level safety budget Tbudgetsafe when NsafeTu+Tlocalsafe≤Tbudgetsafe. Stimulation-bearing applications may select a stricter threshold, such as Nsafe = 2, whereas non-actuating monitoring applications may tolerate a larger value after application-specific hazard analysis. Recovery requires authenticated session re-establishment followed by Nrec = 3 consecutive valid critical updates, preventing rapid oscillation between normal and safe states.
TTSS≤NsafeTu+Tlocalsafe,(31)
3.3 Experimental setup
3.3.1 Datasets, traffic generation, and test conditions
This section describes the experimental topology, traffic generation process, protocol modes, network conditions, rekey schedules, attack tests, and measurement procedure used to evaluate latency, jitter, rekey impact, and attack resistance in a closed-loop EEG-BCI communication path. The latency and jitter terminology follows the system model and timing framework in Section 3.1, including the packetization and on-wire size definitions in Equations ??–?? and the tail-oriented jitter definition in Equations 11.
We evaluate an end-to-end pipeline with three logical nodes: a head device that streams EEG-derived traffic, a nearby hub that receives frames and produces feedback or acknowledgments, and an optional cloud endpoint for scenarios requiring remote computation. Experiments are run in a two-hop device–hub–cloud topology when cloud support is enabled and in a one-hop device–hub topology otherwise. The head–hub link is the primary focus because it is both the most exposed to nearby adversaries and the most timing-sensitive segment in typical wearable BCI deployments.
The evaluation intentionally isolates communication-layer behavior by replaying the same EEG-derived traffic through each security mode. This controlled setup makes protocol differences attributable to packetization, link model, key maintenance, and attack parameters rather than to vendor-specific acquisition hardware or radio firmware.
3.3.2 Implementation, reproducibility, and measurement controls
Table 7 summarizes the implementation and measurement controls used to interpret the results. The table reports the software stack, protocol roles, replay design, network profile, repetitions, and timing interpretation so that the secure-channel evaluation can be reproduced consistently across protocol modes.
Table 7. Implementation and reproducibility details for the trace-driven evaluation.
| Item | Reported configuration or interpretation |
|---|---|
| Evaluation type | Communication-layer replay using public EEG-derived traffic and identical protocol/link/topology conditions across all modes. |
| Logical roles | Head device D, hub H, and optional cloud C instantiated as software roles in 1-hop and 2-hop topologies. |
| Execution platform | A common ARM64 Linux test host is used for all reported protocol comparisons; cryptographic processing time is reported separately from link serialization and queueing delay. |
| Cryptographic stack | liboqs 0.15.0 for post-quantum primitives; Python cryptography 46.0.0 for classical baselines; AES-GCM for the symmetric fast path. |
| Benchmark repetitions | At least 400 measurements per reported data point; warm-up runs are discarded before timing; latency is summarized using median, p90, p95, p99, miss rate, and delivery rate. |
| Timing interpretation | Primitive and protocol-processing timings are separated from full communication latency; end-to-end results combine packetization, modeled link behavior, replay checks, AEAD, and key-maintenance events. |
| Link profiles | BLE-like profile: 1 Mbps nominal rate with constrained MTU and periodic transmission opportunities; Wi-Fi-like profile: 54 Mbps nominal rate with lower serialization delay and queueing jitter. |
| Loss and reordering | Low loss 0%–0.1%, moderate loss 0.5%, stressed loss 1%–3%; packet reordering is included to exercise replay-window behavior. |
| Randomization and reproducibility | Each protocol/link/topology/dataset condition uses fixed replay, delay, loss, and reordering seeds so that comparisons are paired across protocols. |
| Resource accounting | Measured ARM64 processing time and handshake bytes are reported separately from an MCU projection based on PQM4 cycle/stack data and representative 10–20 mW Cortex-M4 active-CPU profiles. |
Public EEG datasets are replayed as realistic traffic sources and then packetized into frames that match practical acquisition settings. We use representative datasets spanning motor-imagery and inner-speech paradigms: (i) the PhysioNet EEG Motor Movement/Imagery dataset (EEGMMIDB), (ii) the BCI Competition IV datasets 2a and 2b, and (iii) the Thinking Out Loud inner-speech dataset. Table 8 summarizes the datasets and baseline acquisition characteristics used to drive the traffic generator. The role of these datasets is traffic generation: they provide realistic packetization rates, payload sizes, and temporal variability, while decoder benchmarking remains outside the communication-layer evaluation.
Table 8. Datasets used for realistic EEG traffic replay.
| Dataset | Paradigm | C | f*s* |
|---|---|---|---|
| EEGMMIDB (PhysioNet, 2009) | Motor imagery | 64 | 160 |
| BCI Comp IV 2a (Brunner et al., 2008) | Motor imagery | 22 | 250 |
| BCI Comp IV 2b (Leeb et al., 2008) | Motor imagery | 3 | 250 |
| Thinking Out Loud (Nieto et al., 2022) | Inner speech | 136 | As recorded |
For each dataset, samples are read in time order and framed into fixed-duration packets. The baseline operating points use T*f*∈{20ms, 40ms}, yielding W*f* = ⌊f*s*T*f*⌋ samples per channel per frame. Raw-EEG frames use a fixed on-wire sample width, with 16-bit samples as the default setting, while feature frames represent reduced-bandwidth streaming configurations that avoid transmitting full raw EEG. Payload sizes follow the definitions introduced in the system model: raw EEG payload size is computed from Equation 2, feature payload size from Equation 3, and protected on-wire packet size from Equation 4. These two traffic types allow the evaluation to capture security overhead under both high-rate raw streaming and compressed feature streaming.
Security is evaluated across the modes defined in Table 5. The head–hub channel is instantiated in two deployment variants: (i) a datagram-style secure channel with a QUIC/TLS-inspired handshake and AEAD-protected application frames, and (ii) a QUIC-based prototype over Wi-Fi that reuses the standard QUIC security interface to TLS for key derivation and key updates (Thomson and Turner, 2021). The hub–cloud segment uses TLS 1.3 as a baseline (Rescorla, 2018), and, where available in the software stack, ML-KEM-enabled groups are used for post-quantum or hybrid negotiation (IETF TLS Working Group, 2026).
Wireless and network conditions are modeled using two link profiles. The first approximates BLE-like short-range streaming with constrained MTU and periodic transmission opportunities. The second approximates Wi-Fi-like streaming with higher throughput but variable queueing under contention. For each profile, a network emulator injects controlled delay variation, packet loss, and packet reordering. Results are reported across representative loss regimes: low loss (0%–0.1%), moderate loss (0.5%), and stressed loss (1%–3%). Because replay-window policy interacts with retransmissions and packet reordering, the experiments also record rejection attributable to replay-window enforcement in addition to any application-layer reassembly loss.
To exercise robustness beyond independent random loss, the evaluation framework also defines stress profiles with burst-loss episodes, intermittent connectivity requiring re-handshake, and multi-stream contention representing several EEG streams sharing a hub or access point. These stress profiles extend the validation envelope for replay-window sizing, key-refresh behavior, and safe-mode transitions under congested or intermittent wireless conditions.
Rekey behavior is evaluated using both time-based and packet-based triggers. Symmetric updates are performed frequently using the constant-cost update rule defined in the secure-channel section, while post-quantum refresh events are invoked less frequently to inject fresh entropy without requiring a full reconnect. Rekeying is parameterized by (Tsym, Nsym) for symmetric updates and Tpqc for post-quantum refresh. We sweep (Tsym, Nsym) from conservative to aggressive settings and measure the transient delay induced around rekey events. When extended key-update mechanisms beyond baseline TLS KeyUpdate are considered, they follow the intent of recent IETF efforts to strengthen update properties without incurring a full handshake restart (Tschofenig et al., 2026; Rosomakho et al., 2026).
Measurement follows established EEG–based BCI timing practice by timestamping pipeline stages and reporting full latency distributions rather than averages alone. For each frame index i, let tiacq denote the timestamp at the end of acquisition for the last sample included in frame i at the head device, and let tifb denote the timestamp at which the corresponding feedback or acknowledgment becomes available again at the head. The measured end-to-end closed-loop sample-to-feedback latency is: For each condition, we report the median, p90, p95, and p99 of {L*i*}. Inter-arrival jitter at the hub follows the same tail-dispersion definition introduced in the system model; for convenience, we use: where a*i* denotes the arrival time of frame i at the hub.
Li=tifb-tiacq.(32)
Δai=ai-ai-1, J=Q0.95(Δa)-Q0.50(Δa),(33)
3.3.3 Statistical analysis
For each protocol/link/topology/dataset condition, latency and jitter summaries are treated as paired repeated measurements because each protocol is evaluated on the same traffic source and link profile. We therefore use bootstrap confidence intervals and non-parametric paired tests rather than assuming normal latency distributions. Specifically, 95% confidence intervals for medians, p95, and p99 values are obtained using percentile bootstrap resampling of the per-frame latency vectors. Protocol comparisons are first screened using a Friedman test across the repeated protocol conditions, followed by paired Wilcoxon signed-rank tests for planned comparisons such as M3 vs. M2, M3 vs. WireGuard, and M3 vs. TLS/QUIC baselines. Holm–Bonferroni correction is applied to control family-wise error, and Cliff's delta or rank-biserial effect size is reported to distinguish statistical significance from practically negligible sub-millisecond differences.
Statistical interpretation is tied to paired per-frame vectors from the prototype. The reported tests therefore quantify how the security modes compare under identical replay and link assumptions, while platform-specific studies can reuse the same procedure to evaluate particular headset, hub, radio, or operating-system deployments.
Adversarial robustness is evaluated using four active communication-layer tests aligned with the threat model in Section 3.1: injection, replay, selective delay, and MITM/session splicing. For injection, replay, and MITM/session splicing, the primary security outcome is false acceptance of an unauthorized message or session. True rejection of malicious traffic and false rejection of benign traffic are reported separately. The delay test has different semantics: its outcome is the fraction of critical updates whose deadlines are violated, rather than successful cryptographic forgery. For delay and jamming-oriented conditions, the evaluation additionally records whether the watchdog reaches the expected warning, degraded, and safe states, the number of consecutive missed or stale critical updates at transition, and the analytical time-to-safe-state bound in Equation 31. With the default Nsafe = 3 and the evaluated T*u*∈{20, 40} ms cadence, the communication-watchdog contribution is bounded by 60–120 ms from the last valid critical update, plus the platform-specific local shutdown time.
Cryptographic compute cost is considered separately from transport effects. For the protocol modes evaluated in this paper, handshake-processing time, verification cost, and rekey overhead are measured from the implementation or protocol stack used in the experiments whenever direct platform measurements are available. Published embedded benchmarks are used only to contextualize head-side feasibility and to compare the relative cost of PQC operations against symmetric AEAD, which supports the design decision to keep public-key operations off the per-frame fast path.
3.3.4 MCU-informed resource and processing-energy accounting
The directly measured cryptographic timings in Section 4.1 characterize the common ARM64 evaluation host. A separate wearable-class projection is obtained from published Cortex-M4 cycle counts and stack measurements rather than by multiplying the ARM64 timing by a single assumed wattage. For an operation requiring Cop cycles on a target device d with clock frequency fclk(d), the projected execution time is: If the active processor current and supply voltage are Iact(d) and VDD(d), respectively, then, For a session with one authenticated handshake, Nsym(s) symmetric key updates, and Npqc(s) public-key refreshes, the projected CPU-processing energy is: The wearable sensitivity analysis uses 10 mW and 20 mW active-CPU profiles. These values are grounded in representative Cortex-M4 specifications: the nRF52840 reports 3.3 mA at 64 MHz with its DC/DC regulator and 6.3 mA without that regulator for a CoreMark workload, corresponding to approximately 9.9 and 18.9 mW at 3.0 V, while the STM32L4A6 reports 37 μA/MHz at 3.3 V in SMPS run mode, or approximately 9.8 mW at 80 MHz (Nordic Semiconductor ASA, 2023; STMicroelectronics, 2022). ML-KEM-768 and ML-DSA-44 cycle and peak-stack values are taken from the current PQM4 benchmark tables (Kannwischer et al., 2019; PQM4 Contributors, 2026).
top(d)=Copfclk(d).(34)
Eop(d)=VDD(d)Iact(d)top(d)=Pact(d)Copfclk(d).(35)
Ectrl(d)≈EHS(d)+Nsym(s)Esym(d)+Npqc(s)Epqc(d).(36)
Equations 34–36 account for CPU processing only. Radio airtime can be parameterized separately as: with connection intervals, acknowledgments, retransmissions, and radio start-up time added for a specific BLE or Wi-Fi implementation. This separation is important because PQC increases handshake airtime, whereas the continuous EEG stream remains on the symmetric fast path.
Eradio≈VDD(Itxttx+Irxtrx), ttx≳8BwireRlink,(37)
4 Results
This section presents the communication-layer evaluation of PQ-NeuroLink across four publicly available EEG benchmark datasets, two radio link profiles (BLE-like at 1Mbps and Wi-Fi-like at 54Mbps), two network topologies (1-hop Device → Hub and 2-hop Device → Hub → Cloud), and nine security configurations ranging from no protection to hybrid ML-KEM-768/X25519 key establishment with pinned ML-DSA-44 identity binding. Post-quantum operations were implemented using liboqs 0.15.0, while classical baselines were implemented using Python cryptography 46.0.0. Unless otherwise stated, each reported data point is the median of at least 400 measurements, and error bars denote the interquartile range or the uncertainty interval available from the trace logs.
4.1 Post-quantum cryptographic benchmarks
The cryptographic values in this section isolate primitive and protocol-processing costs from the full communication path. Each primitive benchmark was run repeatedly after warm-up, with at least N = 400 measured repetitions. Optimized library implementations may use compiler optimizations and CPU instructions available on the ARM64 host; therefore the results are reported separately from packetization, link serialization, queueing, feedback rendering, and platform power management. To reduce ambiguity, the analysis separates (i) primitive compute time, (ii) handshake transcript size, and (iii) full communication latency.
Figure 2 reports primitive-level cryptographic timings on the ARM64 software test environment. ML-KEM operations appear in the 0.010–0.025 ms range across the evaluated parameter sets, with ML-KEM-768 requiring 0.015 ms for encapsulation and 0.017 ms for decapsulation in the optimized library configuration. In the signature benchmarks, ML-DSA-44 signing and verification require 0.072 ms and 0.030 ms, respectively, while RSA-2048 signing reaches 0.551 ms in the same timing harness. The systems conclusion is that, in this prototype, public-key computation is separated from the per-frame path and is smaller than the link and packetization effects that dominate the communication latency results.

Figure 3 shows that the principal overhead of the post-quantum and hybrid modes lies in handshake transcript size rather than in the reported primitive-processing time. M2 and M3 require 4.63 kB and 4.67 kB, respectively, compared with 0.17 kB for M1, and this increase is dominated by ML-DSA-44 signatures and KEM key material. The corresponding measured cryptographic handshake-processing latency remains sub-millisecond for all evaluated PQ modes, with M2 at 0.149 ms and M3 at 0.182 ms. This separation explains why PQC primarily affects one-time setup and refresh events in the evaluated design, while the continuous EEG stream remains protected by the same symmetric fast path used across the secured modes.

4.2 End-to-end latency analysis
Figure 4 compares the measured end-to-end latency percentiles across all nine protocols in the 1-hop trace-driven setting. Under BLE, the latency spread across secured modes remains modest because link constraints and packet transmission time dominate the total delay. Within that setting, M3 records the lowest p50, p95, and p99 values among the secured schemes in this dataset/link configuration and remains close to the unsecured baseline M0, while DTLS and IPsec exhibit the largest tail values. Under Wi-Fi, where transmission delay is lower, the separation between protocols becomes clearer: M3 again gives the lowest percentile values among the secured modes in the evaluated traces and stays closest to M0 across all three percentiles.

The key interpretation is that when all secured modes share an AEAD-protected streaming fast path and public-key work is kept off the per-frame path, PQ or hybrid session establishment adds little steady-state latency in the tested conditions. Statistical comparisons are treated using the non-parametric procedure described in Section 3.3.3; sub-millisecond differences are emphasized as effect sizes and practical latency margins.
4.3 Statistical uncertainty and practical effect size
The latency results are interpreted using the bootstrap and paired non-parametric procedure defined in Section 3.3.3. In addition to reporting medians and tail percentiles, the manuscript distinguishes statistical uncertainty from practical relevance. For example, Table 9 shows that in the BLE 1-hop summary condition M3 differs from M0 by 0.45 ms at p95, while the full protocol spread is 4.00 ms. Such sub-millisecond differences may be statistically detectable with many frames but are not, by themselves, evidence of clinically meaningful improvement. Therefore, the main claim is restricted to feasibility: PQ/hybrid session establishment can be moved off the streaming fast path so that steady-state latency remains dominated by link, topology, and packetization effects under the tested traces.
Table 9. Summary of performance and security metrics (BLE, 1-Hop, all datasets).
| Protocol | HS (ms) | HS(kB) | p50(ms | p95(ms) | DR(%) | KEM cat. |
|---|---|---|---|---|---|---|
| M0 (No Security) | 0.000 | 0.00 | 54.30 | 61.10 | 99.69 | – |
| M1 (X25519) | 0.169 | 0.17 | 56.10 | 63.50 | 98.23 | Classical |
| M2 (ML-KEM-768) | 0.149 | 4.63 | 55.20 | 62.30 | 98.15 | 3 |
| M3 (Hybrid PQ) | 0.182 | 4.67 | 54.65 | 61.55 | 99.00 | 3 |
| TLS 1.3 | 0.167 | 0.47 | 55.75 | 62.90 | 98.38 | Classical |
| DTLS 1.3 | 0.167 | 0.52 | 56.70 | 64.20 | 97.99 | Classical |
| QUIC | 0.136 | 0.32 | 55.85 | 63.00 | 98.46 | Classical |
| WireGuard | 0.095 | 0.11 | 55.00 | 62.00 | 98.69 | Classical |
| IPsec/IKEv2 | 0.634 | 1.00 | 57.40 | 65.10 | 98.53 | Classical |
HS, handshake; DR, packet delivery rate; KEM cat., ML-KEM key-establishment security category where applicable. ML-DSA-44 endpoint signatures are category 2. Overall p95 range across all protocols: 61.10–65.10 ms (spread: 4.00 ms). Bold text identifies the proposed M3 hybrid mode; bold p50 and p95 values are the lowest values among the secured schemes in the summarized BLE 1-hop condition. Bold formatting does not denote statistical significance.
The analysis also avoids claiming statistical significance for any condition where only aggregate plot values are available. Future artifact release should include the raw per-frame latency vectors, random seeds, and scripts for bootstrap confidence intervals, Friedman/Wilcoxon tests, Holm–Bonferroni correction, and effect-size computation.
4.4 Link type and network topology analysis
Figure 5 shows that link type is the dominant factor in end-to-end latency. For all protocols, BLE produces substantially higher p95 latency than Wi-Fi because lower link capacity and longer transmission time dominate the communication path. Within each link class, however, M3 records the lowest p95 among the secured schemes and remains closest to the unsecured baseline M0.

Figure 6 shows that adding a second hop increases latency across all protocols on both BLE and Wi-Fi. The increase is larger on BLE, but the ordering across secured schemes remains consistent: M3 maintains the lowest p95, followed by WireGuard and M2, while DTLS and IPsec remain the highest-latency secured baselines. Overall, the measured results show that topology and link type dominate absolute latency, while the proposed hybrid mode remains the lowest-latency secured configuration across both deployment settings.

4.5 QoS deadline and miss-rate analysis
Figure 7 shows the measured packet miss-rate as the QoS deadline is varied. Under BLE, all protocols exhibit high miss-rates at very tight deadlines because the constrained link cannot deliver larger EEG frames fast enough. As the deadline relaxes, the curves separate most clearly in the 50–100 ms region, where protocol overhead determines whether packets fall just above or below the threshold. In this range, M3 records the lowest miss-rate among the secured schemes and remains close to the unsecured baseline M0, while DTLS and IPsec show the highest miss-rates.

Under Wi-Fi, the same pattern appears over a smaller deadline range because the link is faster and miss-rates drop rapidly once the deadline exceeds about 10–12 ms. Even in this tighter region, M3 again gives the lowest miss-rate among the secured protocols, followed closely by WireGuard and M2, while DTLS and IPsec remain the highest. Overall, the measured results show that the proposed hybrid mode provides the most favorable deadline performance among the secured schemes on both link types.
4.6 Security analysis
Figure 8 reports communication-layer attack outcome rates for Injection, Replay, Delay, and MITM/session splicing. For Injection, Replay, and MITM/session splicing, the outcome denotes unauthorized acceptance or session compromise; lower values therefore indicate stronger cryptographic protection. For Delay, the plotted outcome denotes an induced critical-message deadline violation, not a bypass of AEAD or endpoint authentication. M0 remains highly vulnerable, while M3 records the lowest outcome rates for the three cryptographic attack classes in the trace-driven tests. The comparatively high Delay bars show that authentication alone cannot preserve availability under sustained scheduling interference or jamming. Under the default watchdog, however, timing disruption cannot permit unbounded continuation of actuation: three consecutive missed or stale critical updates cause SafeMode, giving a communication-watchdog bound of 60–120 ms for the evaluated 20–40 ms update periods, plus Tlocalsafe.

Figure 9 shows the modeled MITM/session-splicing success rate as a function of channel SNR. The SNR axis is used as a link-quality stress variable in the emulator. Across the full modeled SNR range, M3 maintains the lowest success rate because the hybrid transcript and pinned ML-DSA identity binding make unauthenticated session substitution fail closed. This empirical result complements the transcript-binding rule and provides a concrete target for formal protocol verification.

Figure 10 is interpreted as an auxiliary integrity and link-stress indicator. The primary security metric is false acceptance of malicious traffic; AEAD rejection distinguishes tamper detection and benign packet loss under the same modeled link conditions. The lower M3 rejection rate in the plotted conditions therefore indicates fewer rejected packets under the same modeled tamper profile, while the attack-success figures report the main security outcome.

4.6.1 Structured security evidence
Table 10 maps each threat class to the corresponding design control and evidence type. The mapping clarifies which properties are exercised by the active communication tests and which are provided through architectural controls such as key lifecycle management, audit, signed updates, and safe-mode policy.
Table 10. Security claims, evidence type, and deployment considerations.
| Threat | Design control | Evidence in this paper | Deployment consideration |
|---|---|---|---|
| Injection/modification | AEAD over payload and associated data including sid, epoch, type, and sequence | Modeled attack experiment | Radio-firmware adversary tests can instantiate the same packet-level checks on a target platform |
| Replay | Monotone per-direction sequence, replay window, epoch binding, optional timestamp bound | Modeled attack experiment and rule-based argument | Clock-drift and retransmission parameters are platform-specific and configure Δ*t* and R |
| MITM/session splicing | Pinned identity keys, signed transcript, hybrid secret binding | Modeled attack experiment and protocol argument | Symbolic verification can further strengthen the protocol argument |
| Downgrade | Mode and algorithm list in signed transcript and HKDF context; fail-closed policy | Design argument; downgrade test specified | Interoperable implementation tests and symbolic analysis provide the next validation layer |
| Delay, intelligent jamming, or denial of service | Timestamp freshness, two-stage watchdog, degraded mode, Nsafe = 3 consecutive-miss threshold, and bounded safe-state transition | Modeled delay experiment and analytical TTSS bound | For 20–40 ms critical-update periods, the default communication-watchdog bound is 60–120 ms plus local shutdown time; stimulation profiles may select a stricter threshold |
| Compromised hub | Least privilege, key isolation, audit, revocation, safe mode | Architectural discussion | Strengthened by secure storage, process isolation, and audit on deployed hubs |
| Compromised cloud/API | Hub termination policy, signed updates, optional end-to-end protection, audit logs | Architectural discussion | Strengthened by cloud access control, audit, and optional end-to-end protection |
| Supply-chain/update attack | Signed firmware/model updates, rollback protection, revocation | Architectural discussion | Integrated through secure boot, signed updates, and rollback protection in product deployments |
| Future quantum adversary | ML-KEM/hybrid key establishment and ML-DSA identity in PQ modes | Cryptographic assumption and standards-based design | Parameter agility supports category-aligned and future standardized choices |
4.7 Session-level overhead and delivery reliability
Figure 11 shows the amortized session overhead computed from the measured ARM64 handshake-processing costs and the configured 300 s public-key refresh interval for M2 and M3. The per-second processing overhead decreases rapidly as session duration increases because setup cost is spread over a longer interval. M2 and M3 show small step increases at refresh points, while IPsec has the highest processing overhead for short sessions in the reported baseline. The complementary Cortex-M4 projection in Table 11 quantifies the longer setup time, peak stack, and mW-scale processing energy expected on a wearable-class MCU.

Table 11. Cycle-derived Cortex-M4 execution-time, peak-stack, and CPU-processing-energy projection for the PQ-NeuroLink post-quantum primitives.
| Operation | Cycles (mean) | Time at 64 MHz (ms) | Peak stack (KiB) | Energy at 10 mW (mJ) | Energy at 20 mW (mJ) |
|---|---|---|---|---|---|
| ML-KEM-768 key generation | 642,096 | 10.03 | 5.27 | 0.100 | 0.201 |
| ML-KEM-768 encapsulation | 658,754 | 10.29 | 6.32 | 0.103 | 0.206 |
| ML-KEM-768 decapsulation | 707,827 | 11.06 | 6.30 | 0.111 | 0.221 |
| ML-DSA-44 key generation | 1,426,025 | 22.28 | 37.40 | 0.223 | 0.446 |
| ML-DSA-44 signing (mean) | 3,943,121 | 61.61 | 43.77 | 0.616 | 1.232 |
| ML-DSA-44 verification | 1,421,623 | 22.21 | 8.70 | 0.222 | 0.444 |
Cycle counts and peak-stack values are from the PQM4 benchmark table for the speed-oriented ML-KEM-768 and ML-DSA-44 implementations (Benchmarks, 2026). Execution time is Cop/64 MHz, and the energy columns include CPU processing only. ML-DSA signing is probabilistic: PQM4 reports approximately 1.81–17.01 million cycles around the 3.94-million-cycle mean. The stack-oriented ML-KEM-768 implementation reduces peak stack to approximately 2.8 KiB with a small cycle increase; the stack-oriented ML-DSA-44 implementation reduces signing stack to approximately 5.0 KiB while increasing mean signing time to approximately 189.6 ms at 64 MHz.
Figure 12 reports the measured packet delivery rate under the BLE-like and Wi-Fi-like links. Delivery remains high across all protocols, with BLE-like conditions slightly lower because of harsher link assumptions. M3 achieves 99.0% delivery on BLE and 99.23% on Wi-Fi, placing it within the top-performing group. Table 9 summarizes the most constrained BLE 1-hop setting: relative to M0, moving to M3 increases p95 by 0.45 ms while adding ML-KEM category-3 post-quantum key establishment, with delivery reduced by 0.69 percentage points.

4.7.1 MCU-informed CPU, memory, and energy projection
Table 11 complements the measured ARM64 results with a wearable-class Cortex-M4 projection derived from the current PQM4 speed-oriented cycle and peak-stack measurements. The projection uses a 64 MHz clock and two active-CPU profiles, 10 mW and 20 mW, representing efficient and conservative microcontroller operating points grounded in the device specifications discussed in Section 3.3.4. These values are cycle-derived projections and are kept separate from the measured ARM64 timings in Figure 2.
The Cortex-M4 projection changes the interpretation of setup cost without changing the steady-state design conclusion. ML-KEM-768 operations require approximately 10–11 ms and 0.10–0.22 mJ over the 10–20 mW sensitivity range. ML-DSA-44 signing and verification project to approximately 61.6 ms and 22.2 ms, corresponding to 0.62–1.23 mJ and 0.22–0.44 mJ, respectively. These costs occur during authenticated setup or infrequent public-key refresh rather than for every EEG frame. The main embedded constraints are therefore transient setup latency, peak working memory, and reconnect energy; the continuous path remains dominated by symmetric AEAD, packetization, and the wireless link.
A complete M3 handshake projection is role dependent because the headset and hub execute different combinations of key generation, encapsulation, decapsulation, signing, and verification. Operation-level reporting therefore avoids assigning a single unsupported wearable handshake total and allows a deployment to compose the relevant costs for its selected endpoint roles and implementation profile.
The results in Table 9 confirm the descriptive trend in the most constrained summarized condition: M3 provides the strongest evaluated hybrid security configuration while preserving near-baseline steady-state latency in the BLE 1-hop model. Relative to M0, upgrading to M3 increases BLE 1-hop p95 latency by 0.45 ms, while delivery decreases by 0.69 percentage points and ML-KEM category-3 post-quantum key establishment is added. The practical interpretation is that the dominant latency contributors remain link, topology, and packetization effects rather than the choice among secured modes sharing the same symmetric streaming fast path.
5 Discussion
The results support the central design principle that latency-sensitive BCI telemetry should keep asymmetric cryptography off the per-frame path. In PQ-NeuroLink, post-quantum operations are restricted to session establishment and public-key refresh, while continuous EEG frames and control messages use lightweight authenticated encryption, counters, epochs, and replay checks. This separation is particularly relevant for neuroengineering scenarios in which degraded timing or feedback instability can affect user control, learning, or comfort. The results also clarify the source of post-quantum overhead: in the evaluated configuration, the dominant PQC cost is handshake transcript size rather than steady-state packet processing.
The comparison with TLS 1.3, QUIC, WireGuard, and IPsec should be interpreted as a secure-channel profiling study rather than as a claim that mature general-purpose protocols are unsuitable for BCI systems. PQ-NeuroLink contributes BCI-specific binding between the secure-channel state and the control-loop requirements: the session identifier, epoch, message type, sequence number, timestamp policy, replay window, key-update cadence, and safe-mode response are treated as part of the timing and safety model. This provides a narrower but more application-aware profile than general transport benchmarking alone.
5.1 Clinical, regulatory, and patient-safety implications
For clinical or home rehabilitation use, PQ-NeuroLink should be integrated into a broader safety and regulatory framework. Patient safety requires that authentication failure, replay detection, stale feedback, or severe latency anomaly transition the application to a predefined safe state. For robotic or prosthetic control this may mean stop or hold-last under a watchdog; for stimulation-bearing systems it should mean stimulation disablement until the channel is re-established and policy checks pass. Regulatory deployment also requires cybersecurity risk management, secure update procedures, audit logs, incident response, privacy controls for stored EEG and derived features, usability evaluation, and documentation of residual risk.
The timing watchdog is intentionally hysteretic. Cryptographic integrity, replay, and session-state violations remain immediate safe-state triggers, whereas timing-only anomalies require three consecutive missed or stale critical updates in the default profile. This policy avoids treating one ordinary wireless loss as a security emergency while bounding continued operation under persistent delay or jamming to 60–120 ms for the evaluated update cadence, plus the local shutdown time. The three-update threshold is a reference communication policy rather than a universal clinical constant: stimulation-bearing systems may select a stricter value, while non-actuating EEG monitoring may tolerate a larger value after application-specific control-stability and safety analysis.
5.2 Scope of interpretation and deployment path
The present results should be interpreted as communication-layer evidence obtained from EEG-derived replay and controlled link profiles. Hardware-specific effects such as radio firmware behavior, CPU governors, memory pressure, thermal throttling, battery-management policy, user mobility, and stimulation-device timing are platform-dependent and should be instantiated during device integration. Similarly, the active security tests exercise injection, replay, delay, MITM/session-splicing, and downgrade behavior at the communication layer, while compromised-hub, compromised-cloud, supply-chain, and large-scale revocation risks are handled through architectural controls. This scope provides a clear deployment path: implement the same profile on target headset and hub hardware, record CPU utilization, peak memory, power, and mobility behavior, and reuse the paired statistical workflow to confirm timing and security margins for the intended BCI task.
6 Conclusion
This paper presented PQ-NeuroLink, a latency-aware secure communication framework for distributed EEG-based BCI pipelines that targets active communication threats and migration toward post-quantum-ready session establishment. The core design choice is to keep post-quantum and hybrid public-key operations off the per-frame streaming path, using them primarily for session setup, endpoint identity binding, and infrequent public-key refresh, while protecting continuous telemetry with symmetric AEAD, sequence numbers, epochs, and replay defenses.
In the prototype evaluation using EEG-derived traffic replay over BLE-like and Wi-Fi-like links, with 1-hop and 2-hop topologies and injected loss, reordering, and tampering, post-quantum and hybrid modes increase session setup bytes but have limited effect on steady-state streaming latency under the tested conditions. The resource analysis now combines the measured ARM64 results with PQM4 cycle/stack data and representative 10–20 mW Cortex-M4 active-CPU profiles. The safety policy also distinguishes immediate cryptographic-failure handling from a three-update timing watchdog that bounds the communication contribution to time-to-safe-state.
Overall, PQ-NeuroLink shows that post-quantum-ready authenticated session establishment can be incorporated into distributed EEG communication prototypes without large steady-state latency penalties when public-key work is excluded from the per-frame path. The framework provides a reproducible basis for subsequent embedded, mobile, multi-user, and human-in-the-loop BCI studies that require both low-latency operation and long-horizon post-quantum security.
Generative AI statement
The author(s) declared that Generative AI was used in the creation of this manuscript. Generative AI was used partially and solely for language improvement. The conceptualization, methodology, results, and original writing were developed entirely by the author(s).
Any alternative text (alt text) provided alongside figures in this article has been generated by Frontiers with the support of artificial intelligence and reasonable efforts have been made to ensure accuracy, including review by the authors wherever possible. If you identify any issues, please contact us.
Publisher's note
All claims expressed in this article are solely those of the authors and do not necessarily represent those of their affiliated organizations, or those of the publisher, the editors and the reviewers. Any product that may be evaluated in this article, or claim that may be made by its manufacturer, is not guaranteed or endorsed by the publisher.
Footnotes
Edited by: Eli Shlizerman, University of Washington, United States
Reviewed by: Niharika Panda, Amrita Vishwa Vidyapeetham-Bengaluru Campus, India
Cemile İnce, İnönü University, Türkiye
Statements
- Conflict of interest
The author(s) declared that this work was conducted in the absence of any commercial or financial relationships that could be construed as a potential conflict of interest.
The author AB declared that they were an editorial board member of Frontiers, at the time of submission. This had no impact on the peer review process and the final decision.
- Funding
The author(s) declared that financial support was received for this work and/or its publication. This work was supported by the United Arab Emirates University (UAEU) under Grants 12R399 and 12T055.
- Data availability
The original contributions presented in the study are included in the article/supplementary material, further inquiries can be directed to the corresponding author.
- Author contributions
TQ: Writing – original draft, Conceptualization, Formal analysis, Investigation, Writing – review & editing. AT: Validation, Writing – review & editing, Methodology, Data curation, Writing – original draft. AB: Writing – original draft, Resources, Methodology, Supervision, Funding acquisition, Writing – review & editing.
- Acknowledgements
The authors acknowledge the maintainers of the public EEG datasets used for trace-driven replay.
References
- Arvaneh M., Ward T., Robertson I. H. (2015). Effects of feedback latency on p300-based brain-computer interface. IEEE Trans. Neural Syst. Rehabil. Eng. 23, 923 – 931. doi: doi:10.1109/EMBC.2015.7318856
- Belkacem A. N., Lakas A. (2021). “A cooperative EEG-based BCI control system for robot-drone interaction,” in 2021 international wireless communications and mobile computing (IWCMC) (Harbin: IEEE), 297 – 302. doi: doi:10.1109/IWCMC51323.2021.9498781
- Bonaci T., Calo R., Chizeck H. J. (2015). App stores for the brain: privacy and security in brain-computer interfaces. IEEE Technol. Soc. Mag. 34, 32 – 39. doi: doi:10.1109/MTS.2015.2425551
- Bossetti C. A., Birdno M. J., Grill W. M. (2008). Analysis of the quasi-static approximation for calculating potentials generated by neural stimulation. J. Neural Eng. 5, 44 – 53. doi: doi:10.1088/1741-2560/5/1/005
- Brocal F. (2023). Brain-computer interfaces in safety and security fields: risks and applications. Saf. Sci. 160: 106051. doi: doi:10.1016/j.ssci.2022.106051
- Brunner C., Leeb R., Mueller-Putz G. R., Schloegl A., Pfurtscheller G. (2008). “BCI competition 2008-Graz data set A (BCI competition IV, data set 2a): Description,” in Dataset Description (Graz: Graz University of Technology).
- Chen C., Chen P., Belkacem A. N., Lu L., Xu R., Tan W.. (2020). Neural activities classification of left and right finger gestures during motor execution and motor imagery. Brain Comput. Interfaces 8, 117 – 127. doi: doi:10.1080/2326263X.2020.1782124
- Devaraj P., Basha S. A. C., Santhosh N. N. P., Panda N. (2026). A post-quantum secure architecture for 6G-enabled smart hospitals: a multi-layered cryptographic framework. Future Internet 18: 165. doi: doi:10.3390/fi18030165
- Edelman B. J., Zhang S., Schalk G., Brunner P., Mueller-Putz G. R., Guan C.. (2025). Non-invasive brain-computer interfaces: state of the art and trends. IEEE Rev. Biomed. Eng. 18, 26 – 49. doi: doi:10.1109/RBME.2024.3449790
- Hamad Z. T., Jamil N., Belkacem A. N. (2024). ChatGpt's impact on education and healthcare: insights, challenges, and ethical consideration. IEEE Access 12, 114858 – 114877. doi: doi:10.1109/ACCESS.2024.3437374
- Ienca M., Haselager P. (2016). Hacking the brain: brain-computer interfacing technology and the ethics of neurosecurity. Ethics Inf. Technol. 18, 117 – 129. doi: doi:10.1007/s10676-016-9398-9
- IETF TLS Working Group (2026). “ML-KEM post-quantum key agreement for TLS 1.3,” in Internet-Draft Draft-IETF-TLS-MLKEM (Wilmington: Internet Engineering Task Force).
- Internet Engineering Task Force (2025). RFC 9794: Terminology for Post-Quantum Traditional Hybrid Schemes. Wilmington, DE: RFC Editor.
- Kannwischer M. J., Rijneveld J., Schwabe P., Stoffelen K. (2019). pqm4: testing and benchmarking NIST PQC on ARM Cortex-M4. Cryptology ePrint Archive, Paper 2019/844. Available online at: (Accessed August 12, 2026).
- Lange J Massart C, Mouraux A and Standaert F-X (2018) Side-channel attacks against the human brain: the PIN code case study (extended version). Brain Inf. 5:12. 10.1186/s40708-018-0090-1.
- Leeb R., Brunner C., Mueller-Putz G. R., Schloegl A., Pfurtscheller G. (2008). “BCI competition 2008-Graz data set B (BCI competition IV, data set 2b): description,” in Dataset Description (Graz: Graz University of Technology).
- Levitt J., Yang Y., Williams S. D., Lütschg Espinosa S. E., Garcia-Casal A., Lewis L. D. (2023). EEG-LLAMAS: a low-latency neurofeedback platform for artifact reduction in EEG-fMRI. Neuroimage 272: 120070. doi: doi:10.1016/j.neuroimage.2023.120092
- Lopez Bernal S., Huertas Celdran A., Martinez Perez G., Barros M. T., Balasubramaniam S. (2021). Security in brain-computer interfaces: state-of-the-art, opportunities, and future challenges. ACM Comput. Surv. 54, 1 – 35. doi: doi:10.1145/3427376
- Martinovic I., Davies D., Frank M., Perito D., Ros T., Song D. (2012). “On the feasibility of side-channel attacks with brain-computer interfaces,” in Proceedings of the USENIX security symposium (Bellevue, WA), 143 – 158.
- National Institute of Standards and Technology (2024a). “FIPS 203: module-lattice-based key-encapsulation mechanism standard,” in Federal Information Processing Standards Publication 203 (National Institute of Standards and Technology).
- National Institute of Standards and Technology (2024b). “FIPS 204: module-lattice-based digital signature standard,” in Federal Information Processing Standards Publication 204 (National Institute of Standards and Technology).
- National Institute of Standards and Technology (2024c). “FIPS 205: stateless hash-based digital signature standard,” in Federal Information Processing Standards Publication 205 (National Institute of Standards and Technology).
- National Institute of Standards and Technology (2025). NIST selects HQC as fifth algorithm for post-quantum encryption. NIST News. Available online at: (Accessed September 06, 2026).
- Nieto N., Peterson V., Rufiner H. L., Kamienkowski J. E., Spies R. (2022). Thinking out loud, an open-access EEG-based bci dataset for inner speech recognition. Sci. Data 9: 52. doi: doi:10.1038/s41597-022-01147-2
- Nordic Semiconductor ASA (2023). nRF52840 Product Specification, version 1.8, document 4413_417. Trondheim, Norway: Nordic Semiconductor ASA. Available online at: (Accessed August 12, 2026).
- Panda N., Muthuraman S. (2026). A multiclass machine learning framework for detecting routing attacks in RPL-based IoT networks using a novel simulation-driven dataset. Future Internet 18: 35. doi: doi:10.3390/fi18010035
- Panda N., Supriya M. (2023). “Blackhole attack prediction in wireless sensor networks using support vector machine,” in Advances in signal processing, embedded systems and IoT, Vol. 992, lecture notes in electrical engineering (Singapore: Springer), 321 – 331. doi: doi:10.1007/978-981-19-8865-3_30
- PhysioNet (2009). EEG Motor Movement/Imagery Dataset (EEGMMIDB). Cambridge, MA: Dataset.
- PQM4 Contributors (2026). pqm4 benchmark results. GitHub repository. Available online at: (Accessed August 12, 2026).
- Reddy M. H., Ankireddypalli O., Arella M., Gujjula S., Panda N. (2025). “Secure email systems: phishing detection with cryptographic verification,” in International conference on advancing technology in engineering and science (ICATES 2025) (Mumbai: IET), 258 – 265.
- Rescorla E. (2018). The Transport Layer Security (TLS) Protocol Version 1.3. RFC 8446. Wilmington, DE: Internet Engineering Task Force (IETF). doi: doi:10.17487/RFC8446
- Rosomakho Y., Tschofenig H., Reddy T. (2026). Extended key update for QUIC. Internet-Draft draft-ietf-quic-extended-key-update-03. Wilmington, DE: Internet Engineering Task Force (IETF).
- Schalk G., McFarland D. J., Hinterberger T., Birbaumer N., Wolpaw J. R. (2004). Bci2000: a general-purpose brain-computer interface (BCI) system. IEEE Trans. Biomed. Eng. 51, 1034 – 1043. doi: doi:10.1109/TBME.2004.827072
- Schwabe P., Stebila D., Wiggers T. (2020). “KEMTLS: post-quantum TLS without handshake signatures,” in Proceedings of the 2020 ACM SIGSAC conference on computer and communications security, 89–106. doi: doi:10.1145/3372297.3423350
- Shanechi M. M. (2019). Brain-machine interfaces from motor to mood. Nat. Neurosci. 22, 1554 – 1564. doi: doi:10.1038/s41593-019-0488-y
- Skomrock N. D., Schwemmer M. A., Ting J. E., Trivedi H. R., Sharma G., Bockbrader M. A.. (2018). A characterization of brain-computer interface performance trade-offs using support vector machines and deep neural networks to decode movement intent. Front. Neurosci. 12: 763. doi: doi:10.3389/fnins.2018.00763
- Soleimani G., Nitsche M. A., Bergmann T. O., Towhidkhah F., Violante I. R., Lorenz R.. (2023). Closing the loop between brain and electrical stimulation: towards precision neuromodulation treatments. Transl. Psychiatry 13: 279. doi: doi:10.1038/s41398-023-02565-5
- Stebila D., Mosca M. (2017). “Post-quantum key exchange for the internet and the open quantum safe project,” in Selected Areas in Cryptography, eds. R. Avanzi, H. Heys (Cham: Springer), 14 – 37. doi: doi:10.1007/978-3-319-69453-5_2
- STMicroelectronics (2022). STM32L4A6xG: ultra-low-power Arm Cortex-M4 32-bit MCU+FPU, 100 DMIPS, 1 MB flash, 320 KB SRAM, USB OTG FS, audio, AES+HASH, external SMPS. Datasheet DS11584, Rev. 14. Geneva, Switzerland: STMicroelectronics. Available online at: (Accessed August 12, 2026).
- Thompson D. E., Quitadamo L. R., Mainardi L., Laghari K. R., Gao S., Kindermans P.-J.. (2014). Performance measurement for brain-computer or brain-machine interfaces: a tutorial. J. Neural Eng. 11: 035001. doi: doi:10.1088/1741-2560/11/3/035001
- Thomson M., Turner S. (2021). Using TLS to secure QUIC. RFC 9001. Wilmington, DE: Internet Enring Task gineeForce (IETF). doi: doi:10.17487/RFC9001
- Topalovic U., Barclay S., Ling C., Alzuhair A., Yu W., Hokhikyan V.. (2023). A wearable platform for closed-loop stimulation and recording of single-neuron and local field potential activity in freely moving humans. Nat. Neurosci. 26, 517 – 527. doi: doi:10.1038/s41593-023-01260-4
- Tschofenig H., Tüxen M., Reddy T. K. Fries. S Rosomakho Y. (2026). Extended key update for Transport Layer Security (TLS) 1.3. Internet-Draft draft-ietf-tls-extended-key-update-13. Wilmington, DE: Internet Engineering Task Force. Work in Progress.
- Wilson J. A., Mellinger J., Schalk G., Williams J. (2010). A procedure for measuring latencies in brain-computer interfaces. IEEE Trans. Biomed. Eng. 57, 1785 – 1797. doi: doi:10.1109/TBME.2010.2047259
- Xiao Q., Fan L. H., Ma Q., Ning Y. M., Gu Z., Chen L.. (2025). Secure wireless communication of brain-computer interface and mind control of smart devices enabled by space-time-coding metasurface. Nat. Commun. 16: 63326. doi: doi:10.1038/s41467-025-63326-0
- Zrenner C., Belardinelli P., Mueller-Dahlhaus F., Ziemann U. (2016). Closed-loop neuroscience and non-invasive brain stimulation: a tale of two loops. Front. Cell. Neurosci. 10: 92. doi: doi:10.3389/fncel.2016.00092
Citation
Qayyum, T., et al. (2026). PQ-Neurolink: latency-aware post-quantum-ready secure communication for distributed brain–computer interfaces. Frontiers in Systems Neuroscience, Volume 20. https://doi.org/
- Received
- Accepted
- Published
- Volume
- 20 - 2026
Copyright
Copyright © 2026 Qayyum, Tariq and Belkacem.
License: https://creativecommons.org/licenses/by/4.0/
*Correspondence: Abdelkader Nasreddine Belkacem
Article metrics
- Views
- 0
- Downloads
- 0
- Citations
- 0
- Shares
- 0
