← Documents Documentation/networking/secid.rst GitHub 원문 ↗

Linux 6.18.37 · Networking

LSM/SELinux secid

flowi의 secid 보안 label이 방향에 따라 어디에서 유도되고 XFRM 선택에 쓰이는지 설명합니다.

Source pathDocumentation/networking/secid.rst
Source versionLinux v6.18.37
TranslationDUJINLABS 전문 번역 + 해설

요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.

1. 요약·해설

원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.

요약·해설

secid.rst:1-20

flowi의 secid 보안 label이 방향에 따라 어디에서 유도되고 XFRM 선택에 쓰이는지 설명합니다.

2. 영어 원문 전체

번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.

원문 전체 펼치기
1 .. SPDX-License-Identifier: GPL-2.0
2
3 =================
4 LSM/SeLinux secid
5 =================
6
7 flowi structure:
8
9 The secid member in the flow structure is used in LSMs (e.g. SELinux) to indicate
10 the label of the flow. This label of the flow is currently used in selecting
11 matching labeled xfrm(s).
12
13 If this is an outbound flow, the label is derived from the socket, if any, or
14 the incoming packet this flow is being generated as a response to (e.g. tcp
15 resets, timewait ack, etc.). It is also conceivable that the label could be
16 derived from other sources such as process context, device, etc., in special
17 cases, as may be appropriate.
18
19 If this is an inbound flow, the label is derived from the IPSec security
20 associations, if any, used by the packet.
21

3. 한국어 전문 번역

영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.

flowi의 보안 label

1-20

`flowi` 구조의 `secid` member는 SELinux 같은 LSM에서 flow의 보안 label을 나타냅니다. 현재 이 label은 일치하는 labeled XFRM을 선택할 때 사용합니다.

outbound flow의 label은 socket이 있으면 socket에서 가져옵니다. TCP reset이나 timewait ACK처럼 수신 패킷에 대한 응답으로 flow를 만들면 그 incoming packet에서 가져옵니다. 특수한 경우에는 정책에 따라 process context나 device 등 다른 source에서 label을 유도할 수도 있습니다.

inbound flow의 label은 해당 패킷에 적용된 IPsec security association이 있으면 그 association에서 유도합니다.

secid label 출처
Outboundsocket 또는 응답 대상 incoming packetflowi.secidlabeled XFRM 선택
InboundIPsec security associationflowi.secidLSM 정책 적용

flow 방향에 따라 보안 label의 근거가 달라집니다.

.. SPDX-License-Identifier: GPL-2.0

=================
LSM/SeLinux secid
=================

flowi structure:

The secid member in the flow structure is used in LSMs (e.g. SELinux) to indicate
the label of the flow. This label of the flow is currently used in selecting
matching labeled xfrm(s).

If this is an outbound flow, the label is derived from the socket, if any, or
the incoming packet this flow is being generated as a response to (e.g. tcp
resets, timewait ack, etc.). It is also conceivable that the label could be
derived from other sources such as process context, device, etc., in special
cases, as may be appropriate.

If this is an inbound flow, the label is derived from the IPSec security
associations, if any, used by the packet.