This reverts commit 65a333600d5c88a98d674f637d092807cfc12253. This wasn't tested for correctness with something like fodwatch [0], and should not have been (self-)merged so quickly, especially without further review. It also resulted in the breakage of at least one package [1] (and that's the one we know of and was caught). A few packages that were updated in between this commit and this revert were not reverted back to using `rev`, but other than that, this is a 1:1 revert. [0]: https://codeberg.org/raphaelr/fodwatch [1]: https://github.com/NixOS/nixpkgs/pull/396904 / 758551e4587d75882aebc21a04bee960418f8ce9
63 lines
1.3 KiB
Nix
63 lines
1.3 KiB
Nix
{
|
|
lib,
|
|
fetchFromGitHub,
|
|
python3Packages,
|
|
}:
|
|
|
|
python3Packages.buildPythonApplication rec {
|
|
pname = "zeronet";
|
|
version = "0.7.1";
|
|
format = "other";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "HelloZeroNet";
|
|
repo = "ZeroNet";
|
|
rev = "v${version}";
|
|
sha256 = "04prgicm0yjh2klcxdgwx1mvlsxxi2bdkzfcvysvixbgq20wjvdk";
|
|
};
|
|
|
|
propagatedBuildInputs = with python3Packages; [
|
|
gevent
|
|
msgpack
|
|
base58
|
|
merkletools
|
|
rsa
|
|
pysocks
|
|
pyasn1
|
|
websocket-client
|
|
gevent-websocket
|
|
rencode
|
|
python-bitcoinlib
|
|
maxminddb
|
|
pyopenssl
|
|
];
|
|
|
|
buildPhase = ''
|
|
${python3Packages.python.pythonOnBuildForHost.interpreter} -O -m compileall .
|
|
'';
|
|
|
|
installPhase = ''
|
|
mkdir -p $out/share
|
|
cp -r plugins src tools *.py $out/share/
|
|
'';
|
|
|
|
postFixup = ''
|
|
makeWrapper "$out/share/zeronet.py" "$out/bin/zeronet" \
|
|
--set PYTHONPATH "$PYTHONPATH" \
|
|
--set PATH ${python3Packages.python}/bin
|
|
'';
|
|
|
|
meta = with lib; {
|
|
description = "Decentralized websites using Bitcoin crypto and BitTorrent network";
|
|
homepage = "https://zeronet.io/";
|
|
license = licenses.gpl2;
|
|
maintainers = with maintainers; [ fgaz ];
|
|
knownVulnerabilities = [
|
|
''
|
|
Unmaintained. Probable XSS/code injection vulnerability.
|
|
Switching to the maintained zeronet-conservancy package is recommended
|
|
''
|
|
];
|
|
};
|
|
}
|