2019-10-02 16:03:04 +01:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
|
|
|
|
|
|
|
# Test dependencies
|
|
|
|
, pytest, pytest-mock
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "RestrictedPython";
|
2020-11-29 14:04:41 +00:00
|
|
|
version = "5.1";
|
2019-10-02 16:03:04 +01:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2020-11-29 14:04:41 +00:00
|
|
|
sha256 = "9ae16e500782b41bd1abefd8554ccb26330817bba9ce090d385aa226f1ca83e8";
|
2019-10-02 16:03:04 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
#propagatedBuildInputs = [ xmltodict requests ifaddr ];
|
|
|
|
|
|
|
|
checkInputs = [
|
|
|
|
pytest pytest-mock
|
|
|
|
];
|
|
|
|
|
|
|
|
checkPhase = ''
|
|
|
|
pytest
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://github.com/zopefoundation/RestrictedPython";
|
2019-10-02 16:03:04 +01:00
|
|
|
description = "A restricted execution environment for Python to run untrusted code";
|
|
|
|
license = lib.licenses.zpl21;
|
|
|
|
maintainers = with lib.maintainers; [ juaningan ];
|
|
|
|
};
|
|
|
|
}
|