libnl: MACsec

libnl 3.7.0

MACsec
Routing Library (libnl-route) » Links (Interfaces)

MACsec link module. More...

## MACsec Object
struct rtnl_link * | rtnl_link_macsec_alloc (void)
int | rtnl_link_macsec_set_sci (struct rtnl_link *link, uint64_t sci)
| Set SCI. More...
int | rtnl_link_macsec_get_sci (struct rtnl_link *link, uint64_t *sci)
| Get SCI. More...
int | rtnl_link_macsec_set_port (struct rtnl_link *link, uint16_t port)
| Set port identifier. More...
int | rtnl_link_macsec_get_port (struct rtnl_link *link, uint16_t *port)
| Get port identifier. More...
int | rtnl_link_macsec_set_cipher_suite (struct rtnl_link *link, uint64_t cipher_suite)
int | rtnl_link_macsec_get_cipher_suite (struct rtnl_link *link, uint64_t *cs)
int | rtnl_link_macsec_set_icv_len (struct rtnl_link *link, uint16_t icv_len)
int | rtnl_link_macsec_get_icv_len (struct rtnl_link *link, uint16_t *icv_len)
int | rtnl_link_macsec_set_protect (struct rtnl_link *link, uint8_t protect)
int | rtnl_link_macsec_get_protect (struct rtnl_link *link, uint8_t *protect)
int | rtnl_link_macsec_set_encrypt (struct rtnl_link *link, uint8_t encrypt)
int | rtnl_link_macsec_get_encrypt (struct rtnl_link *link, uint8_t *encrypt)
int | rtnl_link_macsec_set_offload (struct rtnl_link *link, uint8_t offload)
int | rtnl_link_macsec_get_offload (struct rtnl_link *link, uint8_t *offload)
int | rtnl_link_macsec_set_encoding_sa (struct rtnl_link *link, uint8_t encoding_sa)
int | rtnl_link_macsec_get_encoding_sa (struct rtnl_link *link, uint8_t *encoding_sa)
int | rtnl_link_macsec_set_validation_type (struct rtnl_link *link, enum macsec_validation_type validate)
int | rtnl_link_macsec_get_validation_type (struct rtnl_link *link, enum macsec_validation_type *validate)
int | rtnl_link_macsec_set_replay_protect (struct rtnl_link *link, uint8_t replay_protect)
int | rtnl_link_macsec_get_replay_protect (struct rtnl_link *link, uint8_t *replay_protect)
int | rtnl_link_macsec_set_window (struct rtnl_link *link, uint32_t window)
int | rtnl_link_macsec_get_window (struct rtnl_link *link, uint32_t *window)
int | rtnl_link_macsec_set_send_sci (struct rtnl_link *link, uint8_t send_sci)
int | rtnl_link_macsec_get_send_sci (struct rtnl_link *link, uint8_t *send_sci)
int | rtnl_link_macsec_set_end_station (struct rtnl_link *link, uint8_t end_station)
int | rtnl_link_macsec_get_end_station (struct rtnl_link *link, uint8_t *es)
int | rtnl_link_macsec_set_scb (struct rtnl_link *link, uint8_t scb)
int | rtnl_link_macsec_get_scb (struct rtnl_link *link, uint8_t *scb)

## Detailed Description

MACsec link module.

Link Type Name: "macsec"

MACsec Documentation (Netlink Routing Development Guide)

## Function Documentation

## ◆ rtnl_link_macsec_set_sci()

int rtnl_link_macsec_set_sci | ( | struct rtnl_link * | link,
|  | uint64_t | sci
| ) |  |

Set SCI.

Parameters

  link | Link object
  sci | Secure Channel Identifier in network byte order

Returns
  0 on success or a negative error code.

Definition at line 456 of file macsec.c.

## ◆ rtnl_link_macsec_get_sci()

int rtnl_link_macsec_get_sci | ( | struct rtnl_link * | link,
|  | uint64_t * | sci
| ) |  |

Get SCI.

Parameters

  link | Link object
  sci | On return points to the Secure Channel Identifier in network byte order

Returns
  0 on success or a negative error code.

Definition at line 476 of file macsec.c.

## ◆ rtnl_link_macsec_set_port()

int rtnl_link_macsec_set_port | ( | struct rtnl_link * | link,
|  | uint16_t | port
| ) |  |

Set port identifier.

Parameters

  link | Link object
  port | Port identifier in host byte order

Returns
  0 on success or a negative error code.

Definition at line 498 of file macsec.c.

## ◆ rtnl_link_macsec_get_port()

int rtnl_link_macsec_get_port | ( | struct rtnl_link * | link,
|  | uint16_t * | port
| ) |  |

Get port identifier.

Parameters

  link | Link object
  port | On return points to the port identifier in host byte order

Returns
  0 on success or a negative error code.

Definition at line 517 of file macsec.c.