Skip to main content
Version: 7.26

macsec


interface/macsec​

Conditions: !smips
Type: Directory

Create MACsec interfaces on Ethernet links and inspect their Secure Channel (SC) and Secure Association (SA) statistics. Interfaces can carry a comment, and new interfaces are enabled by default. RouterOS uses matching static CAK and CKN values on both peers; automatic dot1x key provisioning is not available. The tx-sc-* and rx-sc-* rows are aggregate counters for each SC, while the tx-sa-* and rx-sa-* rows are arrays for individual SA slots. See MACsec for configuration, MTU, negotiation, and troubleshooting.

FlagNameDescription
IinactiveThe MACsec interface is inactive.
XdisabledThe MACsec interface is disabled by configuration.
RrunningThe MACsec interface is running.
Hhw-offloadedMACsec processing is actively offloaded to supported hardware for this interface. The flag does not merely indicate hardware capability.
ArgumentTypeDescription
namestringName of the MACsec interface. Default: macsec1.
mtunumMaximum transmission unit in bytes for traffic on the MACsec interface. The MACsec L2MTU is automatically set to the parent interface L2MTU minus the 32-byte MACsec overhead and cannot be changed directly. Default: 1468.
interface ( mandatory )iface_enumParent Ethernet interface on which to create MACsec. Only one MACsec interface can use a parent. A parent that already belongs to a bridge produces an invalid MACsec interface with the detail Interface is already a slave; add the MACsec interface to the bridge instead.
cakstringSixteen-byte pre-shared Connectivity Association Key (CAK), entered as 32 hexadecimal characters. Both ends of the link must use matching CAK and CKN values. Use print show-sensitive to display the value for provisioning on the peer. Default: a randomly generated 16-byte value.
cknstringThirty-two-byte Connectivity Association Name (CKN), entered as 64 hexadecimal characters. Both ends of the link must use matching CAK and CKN values. Default: a randomly generated 32-byte value.
profileenumMACsec profile that supplies the ordered cipher-suite list and key-server priority. Default: default.
Read-only ArgumentTypeDescription
statusstring

Current MACsec interface state.

  • disabled - The interface is disabled.
  • initializing - MACsec initialization is in progress.
  • invalid - The configuration cannot be used. For example, the parent interface already belongs to a bridge.
  • negotiating - MACsec Key Agreement has not established an operational secure channel. Check that both peers have matching CAK and CKN values and a common cipher suite.
  • open-encrypted - The local interface reports an encrypted channel open. This alone does not prove peer negotiation or end-to-end forwarding.
tx-untaggednumTransmitted frames sent without a SecTAG because MACsec protection was not applied.
rx-untaggednumReceived frames without a SecTAG that were accepted when frame validation was not Strict.
tx-too-longnumTransmitted frames discarded because MACsec overhead would make the secured frame too long.
rx-no-tagnumReceived frames discarded because the SecTAG was absent while Strict validation required it.
rx-bad-tagnumReceived frames discarded because their SecTAG was malformed or otherwise invalid.
rx-unknown-scinumReceived frames discarded because their Secure Channel Identifier (SCI) did not identify a known receive SC.
rx-no-scinumReceived frames discarded because the SCI was absent and no receive SC could be identified.
rx-overrunnumReceived frames discarded because SecY receive or validation resources were overrun.
tx-sc-protected-bytemulti { counter: num }Aggregate number of plaintext octets transmitted with integrity protection but without encryption on this TX SC.
tx-sc-protected-packetmulti { counter: num }Aggregate number of packets transmitted with integrity protection but without encryption on this TX SC.
tx-sc-encrypted-bytemulti { counter: num }Aggregate number of plaintext octets transmitted with encryption and integrity protection on this TX SC.
tx-sc-encrypted-packetmulti { counter: num }Aggregate number of packets transmitted with encryption and integrity protection on this TX SC.
rx-sc-validated-bytemulti { counter: num }Aggregate number of plaintext octets successfully integrity-validated without decryption on this RX SC.
rx-sc-decrypted-bytemulti { counter: num }Aggregate number of plaintext octets successfully decrypted and integrity-validated on this RX SC.
rx-sc-uncheckedmulti { counter: num }Aggregate number of packets received while frame validation was Disabled and accepted without integrity validation on this RX SC.
rx-sc-delayedmulti { counter: num }Aggregate number of valid packets received out of order but inside the replay window when replay protection is enabled on this RX SC. The counter definition does not indicate that replay protection is enabled in RouterOS.
rx-sc-okmulti { counter: num }Aggregate number of secured packets successfully validated on this RX SC.
rx-sc-invalidmulti { counter: num }Aggregate number of packets that failed Integrity Check Value (ICV) validation on this RX SC.
rx-sc-latemulti { counter: num }Aggregate number of valid packets received with a packet number lower than the next expected packet number while replay protection is disabled on this RX SC.
rx-sc-not-validmulti { counter: num }Aggregate number of packets rejected because their packet number failed the applicable validity or replay-window checks on this RX SC.
rx-sc-not-using-samulti { counter: num }Aggregate number of packets rejected because they referred to an SA that was not in use on this RX SC.
rx-sc-unused-samulti { counter: num }Aggregate number of SecTAGged, integrity-only frames (C=0) received on an SA not in use and accepted because validation was not Strict on this RX SC.
rx-sa-okmulti { counter: num }Per-SA slot count of packets successfully validated with this individual RX SA.
rx-sa-invalidmulti { counter: num }Per-SA slot count of packets that failed ICV validation for this individual RX SA.
rx-sa-not-validmulti { counter: num }Per-SA slot count of packets that failed packet-number validity checks for this individual RX SA.
rx-sa-not-using-samulti { counter: num }Per-SA slot count of rejected packets associated with this RX SA while it was not in use.
rx-sa-unused-samulti { counter: num }Per-SA slot count of SecTAGged, integrity-only frames (C=0) received while this SA was not in use and accepted because validation was not Strict.
tx-sa-protectedmulti { counter: num }Per-SA slot count of integrity-protected, unencrypted packets transmitted with this individual TX SA.
tx-sa-encryptedmulti { counter: num }Per-SA slot count of encrypted, integrity-protected packets transmitted with this individual TX SA.