Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed set capability fail. #1349

Merged
merged 1 commit into from
Nov 17, 2022

Conversation

higuruchi
Copy link
Contributor

@higuruchi higuruchi commented Nov 17, 2022

Signed-off-by: higuruchi [email protected]

If you use caps::all function, caps::drop function fails unexpectedly because caps::all function get capabilities that the old kernel does not support.
Therefore, Avoid unintended failures by use caps read function that get only the kernel's corresponding capabilities.

@codecov-commenter
Copy link

Codecov Report

Merging #1349 (337d3df) into main (f9c141c) will decrease coverage by 0.00%.
The diff coverage is 0.00%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1349      +/-   ##
==========================================
- Coverage   68.68%   68.68%   -0.01%     
==========================================
  Files         119      119              
  Lines       12609    12609              
==========================================
- Hits         8661     8660       -1     
- Misses       3948     3949       +1     

@utam0k
Copy link
Member

utam0k commented Nov 17, 2022

If you use caps::all function, caps::drop function fails unexpectedly because caps::all function get capabilities that the old kernel does not support.

I just am interested in which version it became available?

@utam0k utam0k merged commit bb610a3 into youki-dev:main Nov 17, 2022
@higuruchi
Copy link
Contributor Author

higuruchi commented Nov 17, 2022

https://man7.org/linux/man-pages/man7/capabilities.7.html

CAP_CHECKPOINT_RESTORE be enabled since Linux 5.9.
So newer than Linux5.9 become available.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants