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

Horribly Broken Install Instructions and Wrong Binary for Linux in Latest Release #1716

Open
R3ITOSv87 opened this issue Oct 25, 2024 · 0 comments

Comments

@R3ITOSv87
Copy link

R3ITOSv87 commented Oct 25, 2024

Terrascan Version: Latest
Operating System: Kali WSL on Windows

Description

Look, whoever wrote these installation instructions might want to reconsider their career choices. The install script is a joke—it's like you didn't even test it on anything.

  1. First problem: trailing #
    Why in the world would you put a # in the beginning of a shell command in a code-Box? This isn't a place for comment syntax. It breaks the whole copy-paste experience. If you're going to provide a one-liner, at least make sure it works after someone pastes it into their terminal. A six-year-old could’ve done better.

  2. Second problem: deleting files right after installing them
    install terrascan /usr/local/bin && rm terrascan—are you serious? This is such a stupid practice that it's hard to know where to begin. If something goes wrong, congratulations! The binary is gone, and there's no way to debug the issue. Stop trying to be clever with && chains where they don't belong.

  3. Third problem: the wrong binary
    Even after forcing the install with sudo, I get hit with this gem:

    -bash: /usr/local/bin/terrascan: cannot execute binary file: Exec format error

    Turns out, the binary you provided is for macOS (Mach-O format). You do realize that most Admins are running Windows or Linux, right? This isn't macOS, and yet you’re handing me a Mach-O binary. Nice job! Way to completely ignore platform compatibility. Bravo.

What I Did

$ curl -L "$(curl -s https://api.github.com/repos/tenable/terrascan/releases/latest | grep -o -E "https[^\"]+linux_amd64.tar.gz")" -o terrascan.tar.gz
$ tar -xf terrascan.tar.gz terrascan && rm terrascan.tar.gz
$ sudo install terrascan /usr/local/bin && rm terrascan
$ terrascan
-bash: /usr/local/bin/terrascan: cannot execute binary file: Exec format error
$ file terrascan
terrascan: Mach-O 64-bit x86_64 executable, flags:<|DYLDLINK|PIE>

This isn't hard. Provide the right binary for Linux. Fix your instructions. This is just embarrassing.

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

1 participant