From 37dbe92519259fb476f8b98f92464f194f080862 Mon Sep 17 00:00:00 2001 From: Viicos <65306057+Viicos@users.noreply.github.com> Date: Wed, 18 Oct 2023 14:50:54 +0200 Subject: [PATCH 1/3] =?UTF-8?q?=E2=AC=86=EF=B8=8F=20Upgrade=20django-simpl?= =?UTF-8?q?ecertmanager=20to=201.4.1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- requirements/base.txt | 6 ++- requirements/ci.txt | 8 ++- requirements/dev.txt | 8 ++- requirements/extensions.txt | 7 ++- .../contrib/jcc/tests/test_client.py | 2 +- .../contrib/qmatic/tests/test_client.py | 2 +- .../digid/tests/test_auth_procedure.py | 2 +- .../digid/tests/test_signicat_integration.py | 2 +- .../tests/test_eherkenning_auth.py | 2 +- .../eherkenning/tests/test_eidas_auth.py | 2 +- .../tests/test_signicat_integration.py | 2 +- src/openforms/contrib/kvk/tests/base.py | 2 +- src/simple_certmanager_ext/__init__.py | 0 src/simple_certmanager_ext/tests/__init__.py | 0 .../tests/data/README.md | 16 ------ .../tests/data/test.certificate | 33 ------------ .../tests/data/test.key | 52 ------------------- src/simple_certmanager_ext/tests/factories.py | 28 ---------- src/soap/tests/factories.py | 4 +- src/soap/tests/test_client.py | 3 +- src/stuf/stuf_zds/tests/test_client.py | 2 +- src/zgw_consumers_ext/tests/factories.py | 4 +- .../tests/test_client_factory.py | 3 +- 23 files changed, 39 insertions(+), 151 deletions(-) delete mode 100644 src/simple_certmanager_ext/__init__.py delete mode 100644 src/simple_certmanager_ext/tests/__init__.py delete mode 100644 src/simple_certmanager_ext/tests/data/README.md delete mode 100644 src/simple_certmanager_ext/tests/data/test.certificate delete mode 100644 src/simple_certmanager_ext/tests/data/test.key delete mode 100644 src/simple_certmanager_ext/tests/factories.py diff --git a/requirements/base.txt b/requirements/base.txt index 213ab5b064..9e372c094e 100644 --- a/requirements/base.txt +++ b/requirements/base.txt @@ -24,7 +24,9 @@ beautifulsoup4==4.10.0 billiard==3.6.4.0 # via celery bleach[css]==5.0.1 - # via -r requirements/base.in + # via + # -r requirements/base.in + # bleach boltons==21.0.0 # via # face @@ -195,7 +197,7 @@ django-sendfile2==0.7.0 # via django-privates django-sessionprofile==2.0.0 # via django-digid-eherkenning -django-simple-certmanager==1.3.0 +django-simple-certmanager==1.4.1 # via # django-digid-eherkenning # zgw-consumers diff --git a/requirements/ci.txt b/requirements/ci.txt index b01b3c4b99..2457f712c7 100644 --- a/requirements/ci.txt +++ b/requirements/ci.txt @@ -54,6 +54,7 @@ bleach[css]==5.0.1 # via # -c requirements/base.txt # -r requirements/base.txt + # bleach boltons==21.0.0 # via # -c requirements/base.txt @@ -225,6 +226,7 @@ django-axes[ipware]==6.0.5 # via # -c requirements/base.txt # -r requirements/base.txt + # django-axes django-better-admin-arrayfield==1.4.2 # via # -c requirements/base.txt @@ -333,7 +335,7 @@ django-sessionprofile==2.0.0 # -c requirements/base.txt # -r requirements/base.txt # django-digid-eherkenning -django-simple-certmanager==1.3.0 +django-simple-certmanager==1.4.1 # via # -c requirements/base.txt # -r requirements/base.txt @@ -560,6 +562,7 @@ maykin-django-two-factor-auth[phonenumbers]==2.0.4 # via # -c requirements/base.txt # -r requirements/base.txt + # maykin-django-two-factor-auth maykin-json-logic-py==0.13.0 # via # -c requirements/base.txt @@ -659,6 +662,7 @@ portalocker[redis]==2.3.2 # via # -c requirements/base.txt # -r requirements/base.txt + # portalocker prance==23.6.21.0 # via # -c requirements/base.txt @@ -844,6 +848,7 @@ sentry-sdk[django]==1.27.1 # via # -c requirements/base.txt # -r requirements/base.txt + # sentry-sdk simplejson==3.17.6 # via # -c requirements/base.txt @@ -916,6 +921,7 @@ tablib[xlsx]==3.0.0 # via # -c requirements/base.txt # -r requirements/base.txt + # tablib tabulate==0.8.9 # via # -c requirements/base.txt diff --git a/requirements/dev.txt b/requirements/dev.txt index 766e2219f2..c118786b99 100644 --- a/requirements/dev.txt +++ b/requirements/dev.txt @@ -64,6 +64,7 @@ bleach[css]==5.0.1 # via # -c requirements/ci.txt # -r requirements/ci.txt + # bleach boltons==21.0.0 # via # -c requirements/ci.txt @@ -254,6 +255,7 @@ django-axes[ipware]==6.0.5 # via # -c requirements/ci.txt # -r requirements/ci.txt + # django-axes django-better-admin-arrayfield==1.4.2 # via # -c requirements/ci.txt @@ -372,7 +374,7 @@ django-sessionprofile==2.0.0 # django-digid-eherkenning django-silk==5.0.1 # via -r requirements/dev.in -django-simple-certmanager==1.3.0 +django-simple-certmanager==1.4.1 # via # -c requirements/ci.txt # -r requirements/ci.txt @@ -640,6 +642,7 @@ maykin-django-two-factor-auth[phonenumbers]==2.0.4 # via # -c requirements/ci.txt # -r requirements/ci.txt + # maykin-django-two-factor-auth maykin-json-logic-py==0.13.0 # via # -c requirements/ci.txt @@ -765,6 +768,7 @@ portalocker[redis]==2.3.2 # via # -c requirements/ci.txt # -r requirements/ci.txt + # portalocker prance==23.6.21.0 # via # -c requirements/ci.txt @@ -973,6 +977,7 @@ sentry-sdk[django]==1.27.1 # via # -c requirements/ci.txt # -r requirements/ci.txt + # sentry-sdk simplejson==3.17.6 # via # -c requirements/ci.txt @@ -1080,6 +1085,7 @@ tablib[xlsx]==3.0.0 # via # -c requirements/ci.txt # -r requirements/ci.txt + # tablib tabulate==0.8.9 # via # -c requirements/ci.txt diff --git a/requirements/extensions.txt b/requirements/extensions.txt index b1d0093872..2771237c9f 100644 --- a/requirements/extensions.txt +++ b/requirements/extensions.txt @@ -40,6 +40,7 @@ bleach[css]==5.0.1 # via # -c requirements/base.in # -r requirements/base.txt + # bleach boltons==21.0.0 # via # -r requirements/base.txt @@ -291,7 +292,7 @@ django-sessionprofile==2.0.0 # via # -r requirements/base.txt # django-digid-eherkenning -django-simple-certmanager==1.3.0 +django-simple-certmanager==1.4.1 # via # -r requirements/base.txt # django-digid-eherkenning @@ -466,6 +467,7 @@ maykin-django-two-factor-auth[phonenumbers]==2.0.4 # via # -c requirements/base.in # -r requirements/base.txt + # maykin-django-two-factor-auth maykin-json-logic-py==0.13.0 # via # -c requirements/base.in @@ -542,6 +544,7 @@ portalocker[redis]==2.3.2 # via # -c requirements/base.in # -r requirements/base.txt + # portalocker prance==23.6.21.0 # via # -r requirements/base.txt @@ -686,6 +689,7 @@ sentry-sdk[django]==1.27.1 # via # -c requirements/base.in # -r requirements/base.txt + # sentry-sdk simplejson==3.17.6 # via # -r requirements/base.txt @@ -723,6 +727,7 @@ tablib[xlsx]==3.0.0 # via # -c requirements/base.in # -r requirements/base.txt + # tablib tabulate==0.8.9 # via # -c requirements/base.in diff --git a/src/openforms/appointments/contrib/jcc/tests/test_client.py b/src/openforms/appointments/contrib/jcc/tests/test_client.py index 6997f76074..eb0bd2cba8 100644 --- a/src/openforms/appointments/contrib/jcc/tests/test_client.py +++ b/src/openforms/appointments/contrib/jcc/tests/test_client.py @@ -3,9 +3,9 @@ from django.test import TestCase from privates.test import temp_private_root +from simple_certmanager.test.factories import CertificateFactory from zeep.client import Client as ZeepClient -from simple_certmanager_ext.tests.factories import CertificateFactory from soap.tests.factories import SoapServiceFactory from ..client import get_client diff --git a/src/openforms/appointments/contrib/qmatic/tests/test_client.py b/src/openforms/appointments/contrib/qmatic/tests/test_client.py index 3924b8f566..e57d7902d8 100644 --- a/src/openforms/appointments/contrib/qmatic/tests/test_client.py +++ b/src/openforms/appointments/contrib/qmatic/tests/test_client.py @@ -3,9 +3,9 @@ import requests_mock from privates.test import temp_private_root from simple_certmanager.constants import CertificateTypes +from simple_certmanager.test.factories import CertificateFactory from openforms.utils.tests.logging import disable_logging -from simple_certmanager_ext.tests.factories import CertificateFactory from ..client import QmaticClient from .utils import MockConfigMixin diff --git a/src/openforms/authentication/contrib/digid/tests/test_auth_procedure.py b/src/openforms/authentication/contrib/digid/tests/test_auth_procedure.py index 7c5efb9712..16483a497e 100644 --- a/src/openforms/authentication/contrib/digid/tests/test_auth_procedure.py +++ b/src/openforms/authentication/contrib/digid/tests/test_auth_procedure.py @@ -14,6 +14,7 @@ from lxml import etree from privates.test import temp_private_root from rest_framework import status +from simple_certmanager.test.factories import CertificateFactory from openforms.forms.tests.factories import ( FormDefinitionFactory, @@ -23,7 +24,6 @@ from openforms.submissions.tests.factories import SubmissionFactory from openforms.submissions.tests.mixins import SubmissionsMixin from openforms.utils.tests.cache import clear_caches -from simple_certmanager_ext.tests.factories import CertificateFactory from ....constants import CO_SIGN_PARAMETER, FORM_AUTH_SESSION_KEY, AuthAttribute from ....contrib.tests.saml_utils import create_test_artifact, get_artifact_response diff --git a/src/openforms/authentication/contrib/digid/tests/test_signicat_integration.py b/src/openforms/authentication/contrib/digid/tests/test_signicat_integration.py index dc68163e57..8cdd09cf7f 100644 --- a/src/openforms/authentication/contrib/digid/tests/test_signicat_integration.py +++ b/src/openforms/authentication/contrib/digid/tests/test_signicat_integration.py @@ -12,6 +12,7 @@ from freezegun import freeze_time from furl import furl from privates.test import temp_private_root +from simple_certmanager.test.factories import CertificateFactory from webtest.forms import Form as WTForm from openforms.forms.tests.factories import FormStepFactory @@ -19,7 +20,6 @@ from openforms.submissions.tokens import submission_resume_token_generator from openforms.utils.tests.cache import clear_caches from openforms.utils.tests.vcr import OFVCRMixin -from simple_certmanager_ext.tests.factories import CertificateFactory from ....constants import FORM_AUTH_SESSION_KEY from ..constants import PLUGIN_ID diff --git a/src/openforms/authentication/contrib/eherkenning/tests/test_eherkenning_auth.py b/src/openforms/authentication/contrib/eherkenning/tests/test_eherkenning_auth.py index 8541683fb4..1460696f06 100644 --- a/src/openforms/authentication/contrib/eherkenning/tests/test_eherkenning_auth.py +++ b/src/openforms/authentication/contrib/eherkenning/tests/test_eherkenning_auth.py @@ -16,13 +16,13 @@ from furl import furl from lxml import etree from privates.test import temp_private_root +from simple_certmanager.test.factories import CertificateFactory from openforms.forms.tests.factories import FormFactory from openforms.submissions.tests.factories import SubmissionFactory from openforms.submissions.tests.mixins import SubmissionsMixin from openforms.tests.utils import supress_output from openforms.utils.tests.cache import clear_caches -from simple_certmanager_ext.tests.factories import CertificateFactory from ....constants import CO_SIGN_PARAMETER, FORM_AUTH_SESSION_KEY, AuthAttribute from ....contrib.tests.saml_utils import ( diff --git a/src/openforms/authentication/contrib/eherkenning/tests/test_eidas_auth.py b/src/openforms/authentication/contrib/eherkenning/tests/test_eidas_auth.py index f6c47ee123..db9e16e2c8 100644 --- a/src/openforms/authentication/contrib/eherkenning/tests/test_eidas_auth.py +++ b/src/openforms/authentication/contrib/eherkenning/tests/test_eidas_auth.py @@ -15,13 +15,13 @@ from furl import furl from lxml import etree from privates.test import temp_private_root +from simple_certmanager.test.factories import CertificateFactory from openforms.forms.tests.factories import FormFactory from openforms.submissions.tests.factories import SubmissionFactory from openforms.submissions.tests.mixins import SubmissionsMixin from openforms.tests.utils import supress_output from openforms.utils.tests.cache import clear_caches -from simple_certmanager_ext.tests.factories import CertificateFactory from ....constants import CO_SIGN_PARAMETER, FORM_AUTH_SESSION_KEY, AuthAttribute from ....contrib.tests.saml_utils import ( diff --git a/src/openforms/authentication/contrib/eherkenning/tests/test_signicat_integration.py b/src/openforms/authentication/contrib/eherkenning/tests/test_signicat_integration.py index c6f9a42bd8..23668eb012 100644 --- a/src/openforms/authentication/contrib/eherkenning/tests/test_signicat_integration.py +++ b/src/openforms/authentication/contrib/eherkenning/tests/test_signicat_integration.py @@ -12,6 +12,7 @@ from freezegun import freeze_time from furl import furl from privates.test import temp_private_root +from simple_certmanager.test.factories import CertificateFactory from webtest.forms import Form as WTForm from openforms.forms.tests.factories import FormStepFactory @@ -19,7 +20,6 @@ from openforms.submissions.tokens import submission_resume_token_generator from openforms.utils.tests.cache import clear_caches from openforms.utils.tests.vcr import OFVCRMixin -from simple_certmanager_ext.tests.factories import CertificateFactory from ....constants import FORM_AUTH_SESSION_KEY from .utils import TEST_FILES diff --git a/src/openforms/contrib/kvk/tests/base.py b/src/openforms/contrib/kvk/tests/base.py index 40ac406864..ba5aab40bb 100644 --- a/src/openforms/contrib/kvk/tests/base.py +++ b/src/openforms/contrib/kvk/tests/base.py @@ -4,10 +4,10 @@ from unittest.mock import patch from simple_certmanager.constants import CertificateTypes +from simple_certmanager.test.factories import CertificateFactory from zgw_consumers.constants import APITypes, AuthTypes from openforms.contrib.kvk.models import KVKConfig -from simple_certmanager_ext.tests.factories import CertificateFactory from zgw_consumers_ext.tests.factories import ServiceFactory TEST_FILES = Path(__file__).parent.resolve() / "files" diff --git a/src/simple_certmanager_ext/__init__.py b/src/simple_certmanager_ext/__init__.py deleted file mode 100644 index e69de29bb2..0000000000 diff --git a/src/simple_certmanager_ext/tests/__init__.py b/src/simple_certmanager_ext/tests/__init__.py deleted file mode 100644 index e69de29bb2..0000000000 diff --git a/src/simple_certmanager_ext/tests/data/README.md b/src/simple_certmanager_ext/tests/data/README.md deleted file mode 100644 index 61eabe1bae..0000000000 --- a/src/simple_certmanager_ext/tests/data/README.md +++ /dev/null @@ -1,16 +0,0 @@ -# Test files for mTLS via simple_certmanager.Certificate models - -## Certificate and key - -The test.certificate and the test.key were generated using the following command: - -```bash -openssl req -newkey rsa:4096 -x509 -sha256 -days 365 -nodes -out test.certificate -keyout test.key -``` - -The tests making use of these certificates are: - -- `src/zgw_consumers_ext/tests/test_client_factory.py` -- `src/openforms/appointments/contrib/qmatic/tests/test_client.py` - -These tests will potentially start failing once the test certificate expires. diff --git a/src/simple_certmanager_ext/tests/data/test.certificate b/src/simple_certmanager_ext/tests/data/test.certificate deleted file mode 100644 index 098a44a3d8..0000000000 --- a/src/simple_certmanager_ext/tests/data/test.certificate +++ /dev/null @@ -1,33 +0,0 @@ ------BEGIN CERTIFICATE----- -MIIFvTCCA6WgAwIBAgIUMzTMR5GJmyJOvSl6rXId64MDha4wDQYJKoZIhvcNAQEL -BQAwbjELMAkGA1UEBhMCTkwxFjAUBgNVBAgMDU5vb3JkLUhvbGxhbmQxEjAQBgNV -BAcMCUFtc3RlcmRhbTEZMBcGA1UECgwQT3BlbiBGb3JtdWxpZXJlbjEYMBYGA1UE -AwwPb3BlbmZvcm11bGllcmVuMB4XDTI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YJKoZIhvcNAQELBQADggIB -ABjTI0q7UZBWt3CeDep79krHg/cRlS28PxL0Of8SNRc0y2XA1aMwXMba1AB2TwpE -EYVC1lJ6lLKRVNop+YJbb1D6ErOu5BQMQnawzJDfgSK+teVUV6bDyGa3641FSRTT -S9CPwAhzI8DgfrqtJGwpL4O84wNy076dyN//u3dXhhwao6eKSoHCXHE2gToAzFpT -Pe/zK+IGfBXG+fBdY1v//EYSTOHioleivsB1dXN0J+9XEXI1v1rJoKDz3tN1rJi1 -B6c/Eio8jXSeXnUyY2A0JND+8dl5U0bW6oMD3Yjk22z9b+RZ0B5bkMM0hxqZbYrW -CKHw0PEGU2K272grMR18HT5A5/nFK7ukWi61xEnL3RxXGif7dYnUNcNsDQLCGnvK -/QO3ySNj5gAjxPKNkBTWGZ/2GSXR8OOTSfTQnz7YA8yh9tN7BffFkZ7yoc1PlEjR -UWdDd88FafNxdEIugvqaoW4zcCGVrUjG9i27P5Y7JcrmskLnG+opm4Kow9Hm9N91 -dTwOs2U9ecWzLCGhh9jc4VUj1BX5rxGOZHLxreZ5HhO4Bec3FO/DnCih15LPeX3+ -1knK3WO0iDF4IvGNcdLAGOvxo4IJs1BvGWrGCDdaxdk+z7a3UhiM+kwdrMA3Jv3s -7CAM8RLViegSaC+onpQkctn+JVBMq2NUVM1ZiyHIJtD5 ------END CERTIFICATE----- diff --git a/src/simple_certmanager_ext/tests/data/test.key b/src/simple_certmanager_ext/tests/data/test.key deleted file mode 100644 index e88b19c181..0000000000 --- a/src/simple_certmanager_ext/tests/data/test.key +++ /dev/null @@ -1,52 +0,0 @@ ------BEGIN PRIVATE KEY----- -MIIJQgIBADANBgkqhkiG9w0BAQEFAASCCSwwggkoAgEAAoICAQDDZkKrx9pA7zVJ -2qOZycwsrWh/3vxLP4XzLAUaytX/WQQvghmm5yftNOQngBrHRgWHcRh/iRF0H06g -v1l8IsLhxwD2BxJXoWMvyXlLFJSV16syC2pISpC5ixvZihoaQ1nYjRdmDWKIVkMN -f9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-eL2R+SZ2nBVush9eNPB2G9yj1bMC1LtLliFoLPasVIGlgc0zTh2gP8Q78VcoHxfU -wO/Tq6WXhhoDqzspBlyO4tCmfFvxaF3JlJJZVmX4FTDkwkbVmZQVtMGViTaVPGB/ -m3BYxeLSO9U8yix+e8q84NzkHo66MOPzLGBsCoDpAoIBAEBFmJttMf/TrGGcqQ7O -pe38Ir5mCRGoOhBD7cNJ2rSe6anwTkgV8ZVSyjrs2/gcfcrnGx7Cqen5NsZ2uApZ -uP2cCMTAENPGsUbzE1qZoAfJNjNmtwnKUWhd9RnWSlmX4OQ/nirtgJsT+UJW63Gf -U+YNK+7B2UzuY8M1Dt8DMqCQxvvgH7Zcxv8WxSW1bTguxp7qrJ52n03TxMi2z1Fs -61SRPRsrqFYuNh8JKF+lcRmQmlU/2s/Fkyhjdc800GYp9wPy8hPe4l8SOssecVOx -tGmFfGs4SHTmIfQILu0THgpwUDkc2zVxJ6QJdBuRM7k3lpStQMuk0zYnPl9Ll2WH -BW8CggEAAbxkGGqg1Ynh4EWS6Gyy31gvMXmV2KP4YPQCm9FW31pX88yJMfZEwSAR -RUa4r4yxArMq/Qy4i1K9Z4emPfNwjk92va60MH6IlAgwaSPGS7Qsgxpu8UoU1FPV -1Qpw9+loft8eUdRl6H2i1GU2LWjcjG5BnLKyCuly9eCrOkEsjqrX/59ggPjs02Ok -d95R9LXgCA+XZGyfMKp/9ndIrCxCSYdq5zXWK6mTYl6tvI7crBd6shPk6fVS1Nni -uAFbCr9IxKpwJ9GKuC/hakit9EnOqrl0F8rEJGpuOFCsGXGt0lSmksEN6G64Gs6I -LFg4KO/pXNCP8nnieqfzHufJYz0wzA== ------END PRIVATE KEY----- diff --git a/src/simple_certmanager_ext/tests/factories.py b/src/simple_certmanager_ext/tests/factories.py deleted file mode 100644 index 3e46082c9b..0000000000 --- a/src/simple_certmanager_ext/tests/factories.py +++ /dev/null @@ -1,28 +0,0 @@ -from pathlib import Path - -import factory -from simple_certmanager.constants import CertificateTypes -from simple_certmanager.models import Certificate - -DATA_DIR = Path(__file__).parent.resolve() / "data" - - -class CertificateFactory(factory.django.DjangoModelFactory): - label = factory.Sequence(lambda n: f"certificate-{n}") - type = CertificateTypes.cert_only - public_certificate = factory.django.FileField( - from_path=str(DATA_DIR / "test.certificate"), - filename="cert.pem", - ) - - class Meta: - model = Certificate - - class Params: - with_private_key = factory.Trait( - type=CertificateTypes.key_pair, - private_key=factory.django.FileField( - from_path=str(DATA_DIR / "test.key"), - filename="key.pem", - ), - ) diff --git a/src/soap/tests/factories.py b/src/soap/tests/factories.py index 5d6fa2bd32..e0450061db 100644 --- a/src/soap/tests/factories.py +++ b/src/soap/tests/factories.py @@ -13,13 +13,13 @@ class Meta: class Params: with_server_cert = factory.Trait( server_certificate=factory.SubFactory( - "simple_certmanager_ext.tests.factories.CertificateFactory", + "simple_certmanager.test.factories.CertificateFactory", public_certificate__filename="server.cert", ), ) with_client_cert = factory.Trait( client_certificate=factory.SubFactory( - "simple_certmanager_ext.tests.factories.CertificateFactory", + "simple_certmanager.test.factories.CertificateFactory", public_certificate__filename="client.cert", ), ) diff --git a/src/soap/tests/test_client.py b/src/soap/tests/test_client.py index 9345bdb925..98f6f517ce 100644 --- a/src/soap/tests/test_client.py +++ b/src/soap/tests/test_client.py @@ -7,8 +7,7 @@ import requests_mock from ape_pie import InvalidURLError - -from simple_certmanager_ext.tests.factories import CertificateFactory +from simple_certmanager.test.factories import CertificateFactory from ..client import SOAPSession, build_client from ..constants import EndpointSecurity diff --git a/src/stuf/stuf_zds/tests/test_client.py b/src/stuf/stuf_zds/tests/test_client.py index 4503d62f77..c5fb5e166e 100644 --- a/src/stuf/stuf_zds/tests/test_client.py +++ b/src/stuf/stuf_zds/tests/test_client.py @@ -6,10 +6,10 @@ import requests_mock from simple_certmanager.constants import CertificateTypes +from simple_certmanager.test.factories import CertificateFactory from openforms.registrations.exceptions import RegistrationFailed from openforms.tests.utils import can_connect -from simple_certmanager_ext.tests.factories import CertificateFactory from ...constants import EndpointType from ...tests.factories import StufServiceFactory diff --git a/src/zgw_consumers_ext/tests/factories.py b/src/zgw_consumers_ext/tests/factories.py index 8c67263147..fd35cb78b5 100644 --- a/src/zgw_consumers_ext/tests/factories.py +++ b/src/zgw_consumers_ext/tests/factories.py @@ -25,13 +25,13 @@ class Meta: class Params: with_server_cert = factory.Trait( server_certificate=factory.SubFactory( - "simple_certmanager_ext.tests.factories.CertificateFactory", + "simple_certmanager.test.factories.CertificateFactory", public_certificate__filename="server.cert", ), ) with_client_cert = factory.Trait( client_certificate=factory.SubFactory( - "simple_certmanager_ext.tests.factories.CertificateFactory", + "simple_certmanager.test.factories.CertificateFactory", public_certificate__filename="client.cert", ), ) diff --git a/src/zgw_consumers_ext/tests/test_client_factory.py b/src/zgw_consumers_ext/tests/test_client_factory.py index e2bd2f906e..c65067ef4f 100644 --- a/src/zgw_consumers_ext/tests/test_client_factory.py +++ b/src/zgw_consumers_ext/tests/test_client_factory.py @@ -4,10 +4,9 @@ from ape_pie import APIClient from privates.test import temp_private_root from simple_certmanager.constants import CertificateTypes +from simple_certmanager.test.factories import CertificateFactory from zgw_consumers.constants import AuthTypes -from simple_certmanager_ext.tests.factories import CertificateFactory - from ..api_client import ServiceClientFactory from .factories import ServiceFactory From 471fbaf976f3445e7a8b365a7e750632446699cc Mon Sep 17 00:00:00 2001 From: Viicos <65306057+Viicos@users.noreply.github.com> Date: Thu, 19 Oct 2023 15:23:59 +0200 Subject: [PATCH 2/3] =?UTF-8?q?=E2=AC=86=EF=B8=8F=20Add=20`django-simple-c?= =?UTF-8?q?ertmanager`=20to=20`base.in`?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- requirements/base.in | 1 + requirements/base.txt | 5 ++--- requirements/ci.txt | 6 ------ requirements/dev.txt | 6 ------ requirements/extensions.txt | 7 +------ 5 files changed, 4 insertions(+), 21 deletions(-) diff --git a/requirements/base.in b/requirements/base.in index cf642792ad..4b1f3ba4a1 100644 --- a/requirements/base.in +++ b/requirements/base.in @@ -55,6 +55,7 @@ django-modeltranslation django-ordered-model django-privates django-redis +django-simple-certmanager>=1.4.1 django-solo django-tinymce django-treebeard diff --git a/requirements/base.txt b/requirements/base.txt index 9e372c094e..787ac8817f 100644 --- a/requirements/base.txt +++ b/requirements/base.txt @@ -24,9 +24,7 @@ beautifulsoup4==4.10.0 billiard==3.6.4.0 # via celery bleach[css]==5.0.1 - # via - # -r requirements/base.in - # bleach + # via -r requirements/base.in boltons==21.0.0 # via # face @@ -199,6 +197,7 @@ django-sessionprofile==2.0.0 # via django-digid-eherkenning django-simple-certmanager==1.4.1 # via + # -r requirements/base.in # django-digid-eherkenning # zgw-consumers django-solo==2.1.0 diff --git a/requirements/ci.txt b/requirements/ci.txt index 2457f712c7..111b17464b 100644 --- a/requirements/ci.txt +++ b/requirements/ci.txt @@ -54,7 +54,6 @@ bleach[css]==5.0.1 # via # -c requirements/base.txt # -r requirements/base.txt - # bleach boltons==21.0.0 # via # -c requirements/base.txt @@ -226,7 +225,6 @@ django-axes[ipware]==6.0.5 # via # -c requirements/base.txt # -r requirements/base.txt - # django-axes django-better-admin-arrayfield==1.4.2 # via # -c requirements/base.txt @@ -562,7 +560,6 @@ maykin-django-two-factor-auth[phonenumbers]==2.0.4 # via # -c requirements/base.txt # -r requirements/base.txt - # maykin-django-two-factor-auth maykin-json-logic-py==0.13.0 # via # -c requirements/base.txt @@ -662,7 +659,6 @@ portalocker[redis]==2.3.2 # via # -c requirements/base.txt # -r requirements/base.txt - # portalocker prance==23.6.21.0 # via # -c requirements/base.txt @@ -848,7 +844,6 @@ sentry-sdk[django]==1.27.1 # via # -c requirements/base.txt # -r requirements/base.txt - # sentry-sdk simplejson==3.17.6 # via # -c requirements/base.txt @@ -921,7 +916,6 @@ tablib[xlsx]==3.0.0 # via # -c requirements/base.txt # -r requirements/base.txt - # tablib tabulate==0.8.9 # via # -c requirements/base.txt diff --git a/requirements/dev.txt b/requirements/dev.txt index c118786b99..355bfe0650 100644 --- a/requirements/dev.txt +++ b/requirements/dev.txt @@ -64,7 +64,6 @@ bleach[css]==5.0.1 # via # -c requirements/ci.txt # -r requirements/ci.txt - # bleach boltons==21.0.0 # via # -c requirements/ci.txt @@ -255,7 +254,6 @@ django-axes[ipware]==6.0.5 # via # -c requirements/ci.txt # -r requirements/ci.txt - # django-axes django-better-admin-arrayfield==1.4.2 # via # -c requirements/ci.txt @@ -642,7 +640,6 @@ maykin-django-two-factor-auth[phonenumbers]==2.0.4 # via # -c requirements/ci.txt # -r requirements/ci.txt - # maykin-django-two-factor-auth maykin-json-logic-py==0.13.0 # via # -c requirements/ci.txt @@ -768,7 +765,6 @@ portalocker[redis]==2.3.2 # via # -c requirements/ci.txt # -r requirements/ci.txt - # portalocker prance==23.6.21.0 # via # -c requirements/ci.txt @@ -977,7 +973,6 @@ sentry-sdk[django]==1.27.1 # via # -c requirements/ci.txt # -r requirements/ci.txt - # sentry-sdk simplejson==3.17.6 # via # -c requirements/ci.txt @@ -1085,7 +1080,6 @@ tablib[xlsx]==3.0.0 # via # -c requirements/ci.txt # -r requirements/ci.txt - # tablib tabulate==0.8.9 # via # -c requirements/ci.txt diff --git a/requirements/extensions.txt b/requirements/extensions.txt index 2771237c9f..4d244b63ff 100644 --- a/requirements/extensions.txt +++ b/requirements/extensions.txt @@ -40,7 +40,6 @@ bleach[css]==5.0.1 # via # -c requirements/base.in # -r requirements/base.txt - # bleach boltons==21.0.0 # via # -r requirements/base.txt @@ -192,7 +191,6 @@ django-axes[ipware]==6.0.5 # via # -c requirements/base.in # -r requirements/base.txt - # django-axes django-better-admin-arrayfield==1.4.2 # via # -c requirements/base.in @@ -294,6 +292,7 @@ django-sessionprofile==2.0.0 # django-digid-eherkenning django-simple-certmanager==1.4.1 # via + # -c requirements/base.in # -r requirements/base.txt # django-digid-eherkenning # zgw-consumers @@ -467,7 +466,6 @@ maykin-django-two-factor-auth[phonenumbers]==2.0.4 # via # -c requirements/base.in # -r requirements/base.txt - # maykin-django-two-factor-auth maykin-json-logic-py==0.13.0 # via # -c requirements/base.in @@ -544,7 +542,6 @@ portalocker[redis]==2.3.2 # via # -c requirements/base.in # -r requirements/base.txt - # portalocker prance==23.6.21.0 # via # -r requirements/base.txt @@ -689,7 +686,6 @@ sentry-sdk[django]==1.27.1 # via # -c requirements/base.in # -r requirements/base.txt - # sentry-sdk simplejson==3.17.6 # via # -r requirements/base.txt @@ -727,7 +723,6 @@ tablib[xlsx]==3.0.0 # via # -c requirements/base.in # -r requirements/base.txt - # tablib tabulate==0.8.9 # via # -c requirements/base.in From e2034b4d5b8bc9d7ec5026513076535cb9d18e28 Mon Sep 17 00:00:00 2001 From: Viicos <65306057+Viicos@users.noreply.github.com> Date: Thu, 19 Oct 2023 17:44:35 +0200 Subject: [PATCH 3/3] =?UTF-8?q?=E2=AC=86=EF=B8=8F=20=20Fix=20extras=20spec?= =?UTF-8?q?ification?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- requirements/base.in | 2 +- requirements/ci.txt | 7 +++++-- requirements/dev.txt | 3 ++- requirements/test-tools.in | 1 + 4 files changed, 9 insertions(+), 4 deletions(-) diff --git a/requirements/base.in b/requirements/base.in index 4b1f3ba4a1..0eb82c3b8b 100644 --- a/requirements/base.in +++ b/requirements/base.in @@ -55,7 +55,7 @@ django-modeltranslation django-ordered-model django-privates django-redis -django-simple-certmanager>=1.4.1 +django-simple-certmanager django-solo django-tinymce django-treebeard diff --git a/requirements/ci.txt b/requirements/ci.txt index 111b17464b..0bd3beaf53 100644 --- a/requirements/ci.txt +++ b/requirements/ci.txt @@ -333,10 +333,11 @@ django-sessionprofile==2.0.0 # -c requirements/base.txt # -r requirements/base.txt # django-digid-eherkenning -django-simple-certmanager==1.4.1 +django-simple-certmanager[testutils]==1.4.1 # via # -c requirements/base.txt # -r requirements/base.txt + # -r requirements/test-tools.in # django-digid-eherkenning # zgw-consumers django-solo==2.1.0 @@ -424,7 +425,9 @@ face==20.1.1 # -r requirements/base.txt # glom factory-boy==3.0.1 - # via -r requirements/test-tools.in + # via + # -r requirements/test-tools.in + # django-simple-certmanager faker==7.0.1 # via # -c requirements/base.txt diff --git a/requirements/dev.txt b/requirements/dev.txt index 355bfe0650..dabe96623e 100644 --- a/requirements/dev.txt +++ b/requirements/dev.txt @@ -372,7 +372,7 @@ django-sessionprofile==2.0.0 # django-digid-eherkenning django-silk==5.0.1 # via -r requirements/dev.in -django-simple-certmanager==1.4.1 +django-simple-certmanager[testutils]==1.4.1 # via # -c requirements/ci.txt # -r requirements/ci.txt @@ -472,6 +472,7 @@ factory-boy==3.0.1 # via # -c requirements/ci.txt # -r requirements/ci.txt + # django-simple-certmanager faker==7.0.1 # via # -c requirements/ci.txt diff --git a/requirements/test-tools.in b/requirements/test-tools.in index a8ccb25a05..7d9275605d 100644 --- a/requirements/test-tools.in +++ b/requirements/test-tools.in @@ -3,6 +3,7 @@ # Dependencies only relevant for (unit) testing coverage django-jenkins +django-simple-certmanager[testutils] django-webtest factory-boy freezegun