bug(cp): when using --context in Non Selinux kernel, it does not warn
Open
Nobody has claimed this yet.
U - cp
- Dominant language
- Rust
- Stars
- 24.1k
- Forks
- 2k
- Avg merge
- 1d 5h
- Merged PRs (30d)
- 365
Description
Hi, uutils mainteners
as i confirmed that the uu cp do not output the warning while the gnu one does, as our test confirmed
relunsec@relunsec:~/software/coreutils/target/debug$ gnucp --context=con a b --verbose
gnucp: warning: ignoring --context; it requires an SELinux-enabled kernel
'a' -> 'b'
relunsec@relunsec:~/software/coreutils/target/debug$ ./cp --context=con a b --verbose
'a' -> 'b'
relunsec@relunsec:~/software/coreutils/target/debug$
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the Rust implementation of cp and its handling of --context, then reproduce the command shown on a non-SELinux kernel and compare it with GNU cp. Done means uu cp emits the corresponding warning while still performing the copy and verbose output.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 64/100