Setcap/getcap: Difference between revisions

From 탱이의 잡동사니
Jump to navigation Jump to search
(Created page with "== Overview == setcap/getcap 내용 정리. == capabilities == <pre> $ man capabilities </pre> Linux capabilities are special attributes in the Linux kernel that grant proces...")
(No difference)

Revision as of 19:57, 16 June 2020

Overview

setcap/getcap 내용 정리.

capabilities

$ man capabilities

Linux capabilities are special attributes in the Linux kernel that grant processes and binary executable specific privileges that are normally reserved for processes whose effective user ID is 0(The only root user has UID 0).

setcap

Set file capabilities.

$ sudo getcap /usr/bin/rcp
 /usr/bin/rcp = cap_net_bind_service+ep

getcap

Examine file capabilities.

$ getcap -v /bin/ping
/bin/ping = cap_net_raw+ep