nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 lib,
3 buildPythonPackage,
4 django,
5 django-extensions,
6 django-js-asset,
7 fetchFromGitHub,
8 pillow,
9 python,
10 selenium,
11 setuptools-scm,
12}:
13
14buildPythonPackage rec {
15 pname = "django-ckeditor";
16 version = "6.7.3";
17 pyproject = true;
18
19 src = fetchFromGitHub {
20 owner = "django-ckeditor";
21 repo = "django-ckeditor";
22 tag = version;
23 hash = "sha256-EqauGFy3VKWHV/MaHhga1lGZhmbHcz6nvc5I87RQ4Dc=";
24 };
25
26 build-system = [ setuptools-scm ];
27
28 dependencies = [
29 django
30 django-js-asset
31 pillow
32 ];
33
34 DJANGO_SETTINGS_MODULE = "ckeditor_demo.settings";
35
36 checkInputs = [
37 django-extensions
38 selenium
39 ];
40
41 checkPhase = ''
42 runHook preCheck
43 ${python.interpreter} -m django test
44 runHook postCheck
45 '';
46
47 pythonImportsCheck = [ "ckeditor" ];
48
49 meta = {
50 description = "Django admin CKEditor integration";
51 homepage = "https://github.com/django-ckeditor/django-ckeditor";
52 changelog = "https://github.com/django-ckeditor/django-ckeditor/blob/${src.tag}/CHANGELOG.rst";
53 license = lib.licenses.bsd3;
54 maintainers = with lib.maintainers; [ onny ];
55 knownVulnerabilities = [
56 ''
57 django-ckeditor bundles CKEditor 4.22.1 which isn’t supported anmyore and
58 which does have unfixed security issues
59
60 Existing users of django-ckeditor should consider switching to a
61 different editor such as CKEditor 5 (django-ckeditor-5), after verifying
62 that its GPL licensing terms are acceptable, or ProseMirror
63 (django-prose-mirror by the author of django-ckeditor). Support of the
64 CKEditor 4 package is provided by its upstream developers as a
65 non-free/commercial LTS package until December 2028.
66
67 Note that while there are publically known vulnerabilities for the
68 CKEditor 4 series, the exploitability of these issues depends on how
69 CKEditor is used by the given Django application.
70
71 Further information:
72
73 * List of vulnerabilites fixed in CKEditor 4.24.0-lts:
74
75 * GHSA-fq6h-4g8v-qqvm
76 * GHSA-fq6h-4g8v-qqvm
77 * GHSA-mw2c-vx6j-mg76
78
79 * The django-ckeditor deprecation notice:
80 <https://406.ch/writing/django-ckeditor/>
81
82 * The non-free/commerical CKEditor 4 LTS package:
83 <https://ckeditor.com/ckeditor-4-support/>
84 ''
85 ];
86 };
87}