Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 20.09 74 lines 1.5 kB view raw
1{ stdenv 2, buildPythonPackage 3, debugger 4, fetchPypi 5, isPy3k 6, Mako 7, makeWrapper 8, packaging 9, pysocks 10, pygments 11, ROPGadget 12, capstone 13, paramiko 14, pip 15, psutil 16, pyelftools 17, pyserial 18, dateutil 19, requests 20, tox 21, unicorn 22, intervaltree 23, fetchpatch 24}: 25 26buildPythonPackage rec { 27 version = "4.2.1"; 28 pname = "pwntools"; 29 30 src = fetchPypi { 31 inherit pname version; 32 sha256 = "1fh7sq9wrcfvn44qryln9cyg99pilvyq9bp80758lgdd6ss6hdqd"; 33 }; 34 35 # Upstream has set an upper bound on unicorn because of https://github.com/Gallopsled/pwntools/issues/1538, 36 # but since that is a niche use case and it requires extra work to get unicorn 1.0.2rc3 to work we relax 37 # the bound here. Check if this is still necessary when updating! 38 postPatch = '' 39 sed -i 's/unicorn>=1.0.2rc1,<1.0.2rc4/unicorn>=1.0.2rc1/' setup.py 40 ''; 41 42 propagatedBuildInputs = [ 43 Mako 44 packaging 45 pysocks 46 pygments 47 ROPGadget 48 capstone 49 paramiko 50 pip 51 psutil 52 pyelftools 53 pyserial 54 dateutil 55 requests 56 tox 57 unicorn 58 intervaltree 59 ]; 60 61 doCheck = false; # no setuptools tests for the package 62 63 postFixup = '' 64 mkdir -p "$out/bin" 65 makeWrapper "${debugger}/bin/${stdenv.lib.strings.getName debugger}" "$out/bin/pwntools-gdb" 66 ''; 67 68 meta = with stdenv.lib; { 69 homepage = "http://pwntools.com"; 70 description = "CTF framework and exploit development library"; 71 license = licenses.mit; 72 maintainers = with maintainers; [ bennofs kristoff3r pamplemousse ]; 73 }; 74}