/* SPDX-License-Identifier: GPL-2.0-or-later */ /* * NetLabel CIPSO/IPv4 Support * * This file defines the CIPSO/IPv4 functions for the NetLabel system. The * NetLabel system manages static and dynamic label mappings for network * protocols such as CIPSO and RIPSO. * * Author: Paul Moore <[email protected]> */ /* * (c) Copyright Hewlett-Packard Development Company, L.P., 2006 */ #ifndef _NETLABEL_CIPSO_V4 #define _NETLABEL_CIPSO_V4 #include <net/netlabel.h> /* * The following NetLabel payloads are supported by the CIPSO subsystem. * * o ADD: * Sent by an application to add a new DOI mapping table. * * Required attributes: * * NLBL_CIPSOV4_A_DOI * NLBL_CIPSOV4_A_MTYPE * NLBL_CIPSOV4_A_TAGLST * * If using CIPSO_V4_MAP_TRANS the following attributes are required: * * NLBL_CIPSOV4_A_MLSLVLLST * NLBL_CIPSOV4_A_MLSCATLST * * If using CIPSO_V4_MAP_PASS or CIPSO_V4_MAP_LOCAL no additional attributes * are required. * * o REMOVE: * Sent by an application to remove a specific DOI mapping table from the * CIPSO V4 system. * * Required attributes: * * NLBL_CIPSOV4_A_DOI * * o LIST: * Sent by an application to list the details of a DOI definition. On * success the kernel should send a response using the following format. * * Required attributes: * * NLBL_CIPSOV4_A_DOI * * The valid response message format depends on the type of the DOI mapping, * the defined formats are shown below. * * Required attributes: * * NLBL_CIPSOV4_A_MTYPE * NLBL_CIPSOV4_A_TAGLST * * If using CIPSO_V4_MAP_TRANS the following attributes are required: * * NLBL_CIPSOV4_A_MLSLVLLST * NLBL_CIPSOV4_A_MLSCATLST * * If using CIPSO_V4_MAP_PASS or CIPSO_V4_MAP_LOCAL no additional attributes * are required. * * o LISTALL: * This message is sent by an application to list the valid DOIs on the * system. When sent by an application there is no payload and the * NLM_F_DUMP flag should be set. The kernel should respond with a series of * the following messages. * * Required attributes: * * NLBL_CIPSOV4_A_DOI * NLBL_CIPSOV4_A_MTYPE * */ /* NetLabel CIPSOv4 commands */ enum { … }; /* NetLabel CIPSOv4 attributes */ enum { … }; #define NLBL_CIPSOV4_A_MAX … /* NetLabel protocol functions */ int netlbl_cipsov4_genl_init(void); #endif