History

xfrm: Add Direction to the SA in or out

This patch introduces the 'dir' attribute, 'in' or 'out', to the xfrm_state, SA, enhancing usability by delineating the scope of values based on direction. An input SA will restrict values pertinent to input, effectively segregating them from output-related values. And an output SA will restrict attributes for output. This change aims to streamline the configuration process and improve the overall consistency of SA attributes during configuration. This feature sets the groundwork for future patches, including the upcoming IP-TFS patch.

Antony Antony committed 2 years ago

Commit a4a87fa1 parent aeb48a47 files · +160 −9Browse files

Showing the changes to include/uapi (1 of 7 files). Show all

Unified · Split

include/uapi/linux/xfrm.h+6−0
@@ -141,6 +141,11 @@ enum { · 140 unmodified lines
141141 XFRM_POLICY_MAX = 3
142142 };
143143
144+enum xfrm_sa_dir {
145+ XFRM_SA_DIR_IN = 1,
146+ XFRM_SA_DIR_OUT = 2
147+};
148+
144149 enum {
145150 XFRM_SHARE_ANY, /* No limitations */
146151 XFRM_SHARE_SESSION, /* For this session only */
@@ -315,6 +320,7 @@ enum xfrm_attr_type_t { · 168 unmodified lines
315320 XFRMA_SET_MARK_MASK, /* __u32 */
316321 XFRMA_IF_ID, /* __u32 */
317322 XFRMA_MTIMER_THRESH, /* __u32 in seconds for input SA */
323+ XFRMA_SA_DIR, /* __u8 */
318324 __XFRMA_MAX
319325
320326 #define XFRMA_OUTPUT_MARK XFRMA_SET_MARK /* Compatibility */

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t