git.iko.soy/typeable/nixpkgs
on master help sign in
chipsec: init at 1.3.6
commit75e08f26f1c4ef2502b9427bbd87131aee657957 authorDaniel Schaefer <git@danielschaefer.me> dateThu 27 Dec 2018, 20:28 (8 years ago) parentf3a5c0e
2 files changed+50
pkgs/tools/security/chipsec/default.nix+42 pkgs/top-level/all-packages.nix+8
pkgs/tools/security/chipsec/default.nixnew file+42
@@ -0,0 +1,42 @@
1+{ stdenv, lib, fetchFromGitHub, python27Packages, nasm, libelf
2+, kernel ? null, withDriver ? false }:
3+python27Packages.buildPythonApplication rec {
4+ name = "chipsec-${version}";
5+ version = "1.3.6";
6+
7+ src = fetchFromGitHub {
8+ owner = "chipsec";
9+ repo = "chipsec";
10+ rev = "v${version}";
11+ sha256 = "18iwbh74j4igrvfx9cc2bfk014ha0b40mvwnn05yabij22kl9l49";
12+ };
13+
14+ buildInputs = [
15+ nasm libelf
16+ ];
17+
18+ setupPyBuildFlags = lib.optional (!withDriver) "--skip-driver";
19+
20+ checkPhase = "python setup.py build "
21+ + lib.optionalString (!withDriver) "--skip-driver "
22+ + "test";
23+
24+ KERNEL_SRC_DIR = lib.optionalString withDriver "${kernel.dev}/lib/modules/${kernel.modDirVersion}/build";
25+
26+ meta = with stdenv.lib; {
27+ description = "Platform Security Assessment Framework";
28+ longDescription = ''
29+ CHIPSEC is a framework for analyzing the security of PC platforms
30+ including hardware, system firmware (BIOS/UEFI), and platform components.
31+ It includes a security test suite, tools for accessing various low level
32+ interfaces, and forensic capabilities. It can be run on Windows, Linux,
33+ Mac OS X and UEFI shell.
34+ '';
35+ license = licenses.gpl2;
36+ homepage = https://github.com/chipsec/chipsec;
37+ maintainers = with maintainers; [ johnazoidberg ];
38+ # This package description is currently only able to build the Linux driver.
39+ # But the other functionality should work on all platforms.
40+ platforms = platforms.all;
41+ };
42+}
pkgs/top-level/all-packages.nix+8
@@ -684,6 +684,9 @@ in
684684
685685 chezmoi = callPackage ../tools/misc/chezmoi { };
686686
687+ # Without kernel driver, should build and work on non-linux as well
688+ chipsec = callPackage ../tools/security/chipsec { };
689+
687690 clair = callPackage ../tools/admin/clair { };
688691
689692 cloud-sql-proxy = callPackage ../tools/misc/cloud-sql-proxy { };
@@ -14938,6 +14941,11 @@ in
1493814941
1493914942 blcr = callPackage ../os-specific/linux/blcr { };
1494014943
14944+ chipsec = callPackage ../tools/security/chipsec {
14945+ inherit kernel;
14946+ withDriver = true;
14947+ };
14948+
1494114949 cryptodev = callPackage ../os-specific/linux/cryptodev { };
1494214950
1494314951 cpupower = callPackage ../os-specific/linux/cpupower { };