Bugzilla – Attachment 1461 Details for
Bug 29407
auditctl 命令不支持 --help 选项,执行时报错 "Option --help is invalid",与 CentOS 8 行为不一致。CentOS 8 中 auditctl --help 可以正常显示帮助信息。
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
用于复现问题的 Dockerfile
Dockerfile (text/plain), 3.37 KB, created by
djjjjj
on 2026-01-11 22:29:13 UTC
(
hide
)
Description:
用于复现问题的 Dockerfile
Filename:
MIME Type:
Creator:
djjjjj
Created:
2026-01-11 22:29:13 UTC
Size:
3.37 KB
patch
obsolete
># Verify auditctl --help error - DIFF_0096 >FROM openanolis/anolisos:8.8 AS anolis >RUN yum install -y audit -q 2>/dev/null || true >RUN { \ > echo "=== Anolis OS 8.8 auditctl Help Test ==="; \ > echo ""; \ > echo "1. auditctl version:"; \ > auditctl --version 2>&1 || echo "Cannot get version"; \ > echo ""; \ > echo "2. Test auditctl --help:"; \ > echo " Command: auditctl --help 2>&1 | head -5"; \ > auditctl --help 2>&1 | head -5 || echo " Command failed"; \ > echo ""; \ > echo "3. Test auditctl -h:"; \ > echo " Command: auditctl -h 2>&1 | head -5"; \ > auditctl -h 2>&1 | head -5 || echo " Command failed"; \ > echo ""; \ > echo "4. Check error message:"; \ > if auditctl --help 2>&1 | grep -q "invalid"; then \ > echo " --help option is invalid (as reported)"; \ > else \ > echo " --help option works normally"; \ > fi; \ >} > /anolis_result.txt > >FROM centos:8 AS centos >RUN cd /etc/yum.repos.d/ && \ > sed -i 's/mirrorlist/#mirrorlist/g' /etc/yum.repos.d/CentOS-* && \ > sed -i 's|#baseurl=http://mirror.centos.org|baseurl=http://vault.centos.org|g' /etc/yum.repos.d/CentOS-* >RUN yum install -y audit -q 2>/dev/null || true >RUN { \ > echo "=== CentOS 8 auditctl Help Test ==="; \ > echo ""; \ > echo "1. auditctl version:"; \ > auditctl --version 2>&1 || echo "Cannot get version"; \ > echo ""; \ > echo "2. Test auditctl --help:"; \ > echo " Command: auditctl --help 2>&1 | head -5"; \ > auditctl --help 2>&1 | head -5 || echo " Command failed"; \ > echo ""; \ > echo "3. Test auditctl -h:"; \ > echo " Command: auditctl -h 2>&1 | head -5"; \ > auditctl -h 2>&1 | head -5 || echo " Command failed"; \ > echo ""; \ > echo "4. Check error message:"; \ > if auditctl --help 2>&1 | grep -q "invalid"; then \ > echo " --help option is invalid"; \ > else \ > echo " --help option works normally"; \ > fi; \ >} > /centos_result.txt > >FROM alpine:latest >COPY --from=anolis /anolis_result.txt /tmp/ >COPY --from=centos /centos_result.txt /tmp/ > >RUN apk add --no-cache bash > >CMD /bin/bash -c 'echo "===== auditctl --help Error Verification (DIFF_0096) ====="; echo ""; echo "********** Anolis OS 8.8 Output **********"; cat /tmp/anolis_result.txt; echo ""; echo "********** CentOS 8 Output **********"; cat /tmp/centos_result.txt; echo ""; echo "===== Difference Analysis ====="; anolis_invalid=$(grep -c "invalid" /tmp/anolis_result.txt); centos_invalid=$(grep -c "invalid" /tmp/centos_result.txt); anolis_works=$(grep -c "works normally" /tmp/anolis_result.txt); centos_works=$(grep -c "works normally" /tmp/centos_result.txt); echo "auditctl --help status:"; echo " AnolisOS8: Invalid=$anolis_invalid, Works=$anolis_works"; echo " CentOS8: Invalid=$centos_invalid, Works=$centos_works"; echo ""; echo "===== Conclusion ====="; if [ "$anolis_invalid" -gt 0 ] && [ "$centos_invalid" -eq 0 ]; then echo "â Compatibility issue: auditctl --help reports invalid option on AnolisOS8"; echo " Impact: Users cannot get help information using --help flag"; echo " This is a bug in the audit package"; elif [ "$anolis_works" -eq 0 ] && [ "$centos_works" -eq 1 ]; then echo "â ï¸ Help option behavior different: --help not working on AnolisOS8"; echo " Impact: Help documentation inaccessible via standard --help flag"; else echo "â Help option behavior consistent"; fi'
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 29407
: 1461