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

Allow suppressing compinit insecure warning #662

Open
AbbyRH opened this issue May 18, 2018 · 4 comments
Open

Allow suppressing compinit insecure warning #662

AbbyRH opened this issue May 18, 2018 · 4 comments

Comments

@AbbyRH
Copy link

AbbyRH commented May 18, 2018

Description

Running zsh/antigen as root/sudo with my normal user's configuration causes a compinit prompt

zsh compinit: insecure directories and files, run compaudit for list.
Ignore insecure directories and files and continue [y] or abort compinit [n]?

I understand that this is to protect the user from using completions that could have been modified by another user and thus might be malicious.

Would it be possible to incorporate a variable test to silently ignore insecure files such as

if [[ $ANTIGEN_DISABLE_COMPAUDIT = true ]]; then
  compinit -d "<zcompdump>"
else
  compinit -i -d "<zcompdump>"
fi

Similar to how oh-my-zsh allows you to ignore insecure files: https://github.com/robbyrussell/oh-my-zsh/blob/master/oh-my-zsh.sh#L65

Steps to reproduce

Minimal steps to reproduce this behavior. Example:

1 - Open terminal
2 - sudo -s
3 - insecure files prompt is displayed

Expected behavior:

- if `$ANTIGEN_DISABLE_COMPAUDIT` is set to true, silently ignore insecure files

Software version

  • Antigen v2.2.2
  • zsh 5.1.1 (x86_64-ubuntu-linux-gnu)
  • Linux myhost 4.4.0-36-generic Remove requirements.txt file #55-Ubuntu SMP Thu Aug 11 18:01:55 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux

Configuration

More information

@AbbyRH AbbyRH changed the title Allow overriding compinit insecure warning Allow suppressing compinit insecure warning May 18, 2018
@karibertils
Copy link

+1 drives me nuts

@karloscodes
Copy link

Any known workarounds?

@goetzc
Copy link

goetzc commented Apr 26, 2020

Should have been fixes on 2.2.3 with PR #634.

@TakuyaSama
Copy link

I just installed Antigen, along with a few Zsh plugins and I've got this issue, but without being sudo/root, just with my normal user, but shouldn't this be fixed already?

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

No branches or pull requests

5 participants