Bridging the MACsec Gap: Add Line-Rate Security Without Redesigning Your Ethernet Subsystem

Now place a MACsec engine between an existing MAC and PHY with new xMII bridges; handle key management with new MKA stack and drivers

Data link layer security has become increasingly important across industrial, automotive, and network edge systems, driven by growing cyber threats as well as emerging cybersecurity requirements such as the European Union's Cyber Resilience Act (CRA). As cyber-physical threats proliferate, hardware-accelerated IEEE 802.1AE (MACsec) protection provides critical packet-level encryption and authentication directly on line-rate Ethernet traffic.

Integrating a hardware MACsec engine into a new System-on-Chip (SoC) or Network-on-Chip (NoC) architecture is relatively straightforward using MACsec engine IP cores such as those we offer. Adding MACsec to an existing SoC, however, can be much harder. The Ethernet MAC may already be tightly integrated with the processor, DMA subsystem, TSN logic, and software stack, making it disruptive to insert a conventional streaming MACsec engine.

Designers have previously faced a dilemma: either completely revamp the software and hardware interface between the host CPU and MAC, or accept complex packet-rerouting schemes to handle encrypted frames. As shown in the illustration, CAST’s new MACsec engine options provide a much simpler integration path.

Optional MII interface bridges and an integrated IEEE 802.1X MKA stack make CAST MACsec easy to integrate.

These new CAST MACsec core options allow you to readily:

  • Place the MACsec engine directly between the existing MAC and PHY with new xMII hardware bridge options, and
  • Integrate key-management responsibilities with a new IEEE 802.1X MACsec Key Agreement (MKA) software stack with bare-metal, FreeRTOS, and Linux drivers.

Simplifying Integration with xMII Hardware Bridges

CAST MACsec Engine IP Cores

  • MACSEC-1G: High-Efficiency Protection for 10/100/1000 Mbps; MII/RMII/GMII/RGMII; compact 32-bit datapath.
    Optimized for high-density, low-power applications requiring line-rate security up to 1 Gbps.
  • MACSEC-MG: High-Throughput Engine for 2.5G to 16.75+ Gbps; XGMII; 128-bit datapath.
    Addresses high-bandwidth backhaul, high-speed Ethernet switches, and multi-gigabit edge gateways.

Both deliver full compliance with IEEE 802.1AE-2018 and IEEE 802.1AEbw standards, support full-duplex line-speed execution, and offer advanced features such as MACsec 802.1Q Tag in the Clear (VLAN-in-Clear).

By default, CAST MACsec IP cores (see sidebar) feature native AXI-Stream interfaces on both input and output paths. This native streaming architecture is ideal when embedding MACsec directly into custom internal bus hierarchies, high-speed packet pipelines, or pre-integrated protocol stacks.

However, placing MACsec between an existing, third-party Ethernet MAC and physical layer transceiver (PHY) historically required custom glue logic or complex packet manipulation. The newly added xMII hardware bridges solve this by establishing a direct drop-in interface at the physical boundary. (See illustration.)

Block diagram of the CAST MACsec engine with optional MAC-side and PHY-side xMII bridges, AXI4-Stream Tx/Rx interfaces, and CSR interface

CAST MACsec engine IP core with optional MAC-side and PHY-side xMII bridges.

This inline placement of the MII interfaces enables two key advantages:

  1. It preserves the existing MAC-to-CPU Interface: Placing the MACsec engine between the MAC and PHY allows engineers to insert the MACsec core transparently into the existing MAC-to-PHY data path. The existing MAC-to-CPU host interface remains entirely unchanged, drastically lowering implementation effort and risk.
  2. It is optimal for Ethernet Switches and TSN Systems: In Time-Sensitive Networking (TSN) endpoints, TSN switches, and multi-port Ethernet switching fabrics, frames typically need to be available in the clear for parsing, classification, scheduling, and routing. Placing the MACsec engine at the external xMII link ensures that packets reaching the switching fabric or queuing engine remain unencrypted. Encryption and authentication occur on the wire side, safeguarding data the instant it leaves the physical port.

Complete Key Management: MKA Software Stack & Drivers

The second update to CAST’s MACsec engine cores addresses the fact that hardware encryption is only as strong as its key management. To complete the security subsystem, CAST delivers an IEEE 802.1X MACsec Key Agreement (MKA) software stack alongside low-level hardware drivers.

Automated Lifecycle and Key Management

The MKA protocol handles live session setup, mutual peer authentication, dynamic Security Association (SA) creation, key rotation, and replay counter management. Supplying the software stack alongside the hardware engine removes the burden of writing complex control-plane firmware from scratch.

Designed for Embedded Systems and FreeRTOS

Linux systems can use established MACsec/MKA support such as wpa_supplicant, but embedded RTOS and bare-metal environments often lack an equivalent ready-to-use key-management framework.

Turnkey key management for embedded systems: host CPU running the CAST MKA software stack and MACsec driver on FreeRTOS or bare metal, connected to the MACSEC-1G or MACSEC-MG core, optional xMII bridges, and Ethernet PHY

CAST's MKA Stack and Drivers work with the MII interfaces for a complete hardware/software MACsec integration.

To bridge this gap, CAST provides optimized MKA stack software paired with hardware drivers tailored for FreeRTOS and bare-metal application environments:

  • FreeRTOS Integration: Provides seamless thread-safe communication between the MKA key exchange engine and the MACsec core CSR registers.
  • Flexible Software Deployment: Allows RTOS-based industrial controllers, automotive ECUs, and IoT gateways to perform secure key negotiations without needing a full-blown OS footprint.
  • Turnkey Solution: Combined with CAST’s pre-integrated subsystems—such as the Low-Latency Ethernet MAC (LLeMAC), UDP/IP hardware stacks, or TSN Switch cores—developers gain an end-to-end, validated hardware-software security platform out of the box.

While Linux systems can use established MACsec/MKA software such as wpa_supplicant, they still require drivers to interface with the MACsec hardware; CAST provides these Linux drivers as well.


Explore CAST IP:


MACsec and the EU Cyber Resilience Act

MACsec is also becoming increasingly relevant as manufacturers prepare for the European Union's Cyber Resilience Act (CRA), which establishes cybersecurity requirements for hardware and software products with digital elements and becomes fully applicable on December 11, 2027.

Draft ETSI EN 304 627 State-of-the-Art MACsec Technologies
Protocols CAST MACsec
IEEE 802.1AE MACsec Supported
GCM-AES-256 Supported
GCM-AES-XPN-128 Supported
GCM-AES-XPN-256 Supported

The current Enquiry Draft of ETSI EN 304 627, a candidate harmonized European standard being developed in support of the CRA for routers, Internet-connected modems, and switches, identifies IEEE 802.1AE MACsec as a state-of-the-art cryptographic protocol and GCM-AES-256, GCM-AES-XPN-128, and GCM-AES-XPN-256 as state-of-the-art MACsec cipher suites.

CAST's MACsec engine IP cores support IEEE 802.1AE and AES-GCM-128/256 with Extended Packet Numbering (XPN), helping SoC developers implement standards-based link-layer security as part of a broader CRA cybersecurity strategy.

Complete Design Flexibility

With these new options, designers can add MACsec to existing Ethernet subsystems with substantially less hardware and software integration effort, while retaining CAST's native AXI-Stream architecture for new designs:

  • Use native AXI-Stream interfaces when integrating MACsec into a new packet-processing pipeline, or
  • Use optional xMII bridges when adding MACsec between an existing MAC and PHY.

Complete the subsystem with CAST's IEEE 802.1X MKA stack and bare-metal, FreeRTOS, or Linux drivers.

By delivering single-clock-domain RTL, flexible interface bridges, complete CSR bus translation, and a FreeRTOS-compatible MKA software stack, CAST provides a comprehensive hardware and software platform for next-generation Ethernet security.


References

  1. European Parliament and Council of the European Union, Regulation (EU) 2024/2847 on horizontal cybersecurity requirements for products with digital elements (Cyber Resilience Act), 23 October 2024. In particular, see Annex I, “Essential Cybersecurity Requirements,” and Article 71, “Entry into force and application.”
    EUR-Lex: Regulation (EU) 2024/2847
  2. ETSI, ETSI EN 304 627 V1.0.1 (2026-07), Cyber Security (CYBER); CRA; Cybersecurity requirements for routers, modems intended for the connection to the internet, and switches, Enquiry Draft, July 2026. See Annex K.7.2, “MACSec,” including Tables K.15 and K.16 identifying IEEE 802.1AE and MACsec cipher suites considered state of the art.
    ETSI Portal – ETSI EN 304 627 work item and status
  3. IEEE Standards Association, IEEE Std 802.1AE-2018 — IEEE Standard for Local and Metropolitan Area Networks—Media Access Control (MAC) Security, 2018.
    IEEE 802.1AE-2018 standard information
  4. CAST, Inc., MACSEC-1G MACsec Engine IP Core and MACSEC-MG MACsec Engine IP Core. Product specifications for CAST's IEEE 802.1AE MACsec implementations, including AES-GCM and AES-GCM-XPN cipher suites and optional xMII integration.
    https://www.cast-inc.com/interfaces/internet-protocol-stacks/macsec-1g
    https://www.cast-inc.com/interfaces/internet-protocol-stacks/macsec-mg
×
Semiconductor IP