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

[17.09] Apache Spark address CVE-2017-12612 #33740

Merged
merged 3 commits into from Jan 12, 2018

Conversation

andir
Copy link
Member

@andir andir commented Jan 11, 2018

Motivation for this change

During a routine check I found that our current Apache Spark version is affected by CVE-2017-12612.

This PR marks the ancient Apache Spark version form the 1.6 branch as insecure. It doesn't receive any updates anymore.

The minor version bump for the 2.1 branch should fix the mentioned CVE among some upstream fixes [1].

CC maintainers and contributors: @thoughtpolice @offlinehacker @cko @mboes @samuelrivas

[1] https://issues.apache.org/jira/secure/ReleaseNote.jspa?projectId=12315420&version=12340295

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option build-use-sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Fits CONTRIBUTING.md.

@andir
Copy link
Member Author

andir commented Jan 11, 2018

@GrahamcOfBorg build spark

Copy link

@GrahamcOfBorg GrahamcOfBorg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Failure for system: x86_64-darwin

Package ‘mesos-1.4.0’ in /Users/graham/nix-borg/repo/38dca4e3aa6bca43ea96d2fcc04e8229/builder/grahamc-zoidberg/pkgs/applications/networking/cluster/mesos/default.nix:245 is not supported on ‘x86_64-darwin’, refusing to evaluate.

a) For `nixos-rebuild` you can set
  { nixpkgs.config.allowBroken = true; }
in configuration.nix to override this.

b) For `nix-env`, `nix-build`, `nix-shell` or any other Nix command you can add
  { allowBroken = true; }
to ~/.config/nixpkgs/config.nix.

Copy link

@GrahamcOfBorg GrahamcOfBorg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Failure for system: aarch64-linux

error: while evaluating the attribute 'buildInputs' of the derivation 'spark-2.1.2' at /var/lib/gc-of-borg/nix-test-rs-3/repo/38dca4e3aa6bca43ea96d2fcc04e8229/builder/grahamc-aarch64-community-3/pkgs/stdenv/generic/make-derivation.nix:98:11:
while evaluating the attribute 'buildInputs' of the derivation 'openjdk-8u152b16' at /var/lib/gc-of-borg/nix-test-rs-3/repo/38dca4e3aa6bca43ea96d2fcc04e8229/builder/grahamc-aarch64-community-3/pkgs/stdenv/generic/make-derivation.nix:98:11:
while evaluating the attribute 'buildCommand' of the derivation 'openjdk-bootstrap' at /var/lib/gc-of-borg/nix-test-rs-3/repo/38dca4e3aa6bca43ea96d2fcc04e8229/builder/grahamc-aarch64-community-3/pkgs/stdenv/generic/make-derivation.nix:98:11:
No bootstrap for system

Copy link

@GrahamcOfBorg GrahamcOfBorg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Success for system: x86_64-linux

/nix/store/9ly43hjnwxqiwk0ygmwijxdshan1pfrk-spark-2.1.2/lib/spark-2.1.2-bin-hadoop2.4/bin/run-example: interpreter directive changed from "/usr/bin/env bash" to "/nix/store/hqi64wjn83nw4mnf9a5z9r4vmpl72j3r-bash-4.4-p12/bin/bash"
/nix/store/9ly43hjnwxqiwk0ygmwijxdshan1pfrk-spark-2.1.2/lib/spark-2.1.2-bin-hadoop2.4/bin/spark-shell: interpreter directive changed from "/usr/bin/env bash" to "/nix/store/hqi64wjn83nw4mnf9a5z9r4vmpl72j3r-bash-4.4-p12/bin/bash"
/nix/store/9ly43hjnwxqiwk0ygmwijxdshan1pfrk-spark-2.1.2/lib/spark-2.1.2-bin-hadoop2.4/bin/find-spark-home: interpreter directive changed from "/usr/bin/env bash" to "/nix/store/hqi64wjn83nw4mnf9a5z9r4vmpl72j3r-bash-4.4-p12/bin/bash"
/nix/store/9ly43hjnwxqiwk0ygmwijxdshan1pfrk-spark-2.1.2/lib/spark-2.1.2-bin-hadoop2.4/bin/pyspark: interpreter directive changed from "/usr/bin/env bash" to "/nix/store/hqi64wjn83nw4mnf9a5z9r4vmpl72j3r-bash-4.4-p12/bin/bash"
/nix/store/9ly43hjnwxqiwk0ygmwijxdshan1pfrk-spark-2.1.2/lib/spark-2.1.2-bin-hadoop2.4/bin/spark-sql: interpreter directive changed from "/usr/bin/env bash" to "/nix/store/hqi64wjn83nw4mnf9a5z9r4vmpl72j3r-bash-4.4-p12/bin/bash"
/nix/store/9ly43hjnwxqiwk0ygmwijxdshan1pfrk-spark-2.1.2/lib/spark-2.1.2-bin-hadoop2.4/bin/spark-submit: interpreter directive changed from "/usr/bin/env bash" to "/nix/store/hqi64wjn83nw4mnf9a5z9r4vmpl72j3r-bash-4.4-p12/bin/bash"
/nix/store/9ly43hjnwxqiwk0ygmwijxdshan1pfrk-spark-2.1.2/lib/spark-2.1.2-bin-hadoop2.4/bin/beeline: interpreter directive changed from "/usr/bin/env bash" to "/nix/store/hqi64wjn83nw4mnf9a5z9r4vmpl72j3r-bash-4.4-p12/bin/bash"
/nix/store/9ly43hjnwxqiwk0ygmwijxdshan1pfrk-spark-2.1.2/lib/spark-2.1.2-bin-hadoop2.4/bin/spark-class: interpreter directive changed from "/usr/bin/env bash" to "/nix/store/hqi64wjn83nw4mnf9a5z9r4vmpl72j3r-bash-4.4-p12/bin/bash"
checking for references to /tmp/nix-build-spark-2.1.2.drv-0 in /nix/store/9ly43hjnwxqiwk0ygmwijxdshan1pfrk-spark-2.1.2...
/nix/store/9ly43hjnwxqiwk0ygmwijxdshan1pfrk-spark-2.1.2

@andir
Copy link
Member Author

andir commented Jan 11, 2018

I backported ae9a7c4 to fix the check-meta.nix result. knownVulnerabilities is used across the 17.09 branch and it seems so far nobody did run into this issue.

@Ericson2314 Ericson2314 removed their request for review January 11, 2018 23:07
@Ericson2314
Copy link
Member

The check-meta change, as a backport is fine with me, but I'm unqualified to comment on the rest.

@andir andir merged commit e0040c6 into NixOS:release-17.09 Jan 12, 2018
@andir andir deleted the 17.09/spark branch January 12, 2018 09:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants