git: fb156d6624b3 - main - security/py-netbox-secretstore: Remove expired port
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Tue, 22 Aug 2023 18:59:13 UTC
The branch main has been updated by rene: URL: https://cgit.FreeBSD.org/ports/commit/?id=fb156d6624b37b4e37b67bfe3db2c16471c14df0 commit fb156d6624b37b4e37b67bfe3db2c16471c14df0 Author: Rene Ladan <rene@FreeBSD.org> AuthorDate: 2023-08-22 18:58:59 +0000 Commit: Rene Ladan <rene@FreeBSD.org> CommitDate: 2023-08-22 18:58:59 +0000 security/py-netbox-secretstore: Remove expired port 2023-08-15 security/py-netbox-secretstore: No longer maintained by upstream, not compatible with NetBox 3.5, please migrate to security/py-netbox-secrets --- MOVED | 1 + security/Makefile | 1 - security/py-netbox-secretstore/Makefile | 29 ------ security/py-netbox-secretstore/distinfo | 3 - ...lter__secret__custom__field__data__and__more.py | 60 ----------- .../patch-netbox__secretstore_models_secrets.py | 51 ---------- .../files/patch-netbox__secretstore_views.py | 33 ------- .../py-netbox-secretstore/files/pkg-message.in | 110 --------------------- security/py-netbox-secretstore/pkg-descr | 2 - 9 files changed, 1 insertion(+), 289 deletions(-) diff --git a/MOVED b/MOVED index 3cdc211d7aea..d677adb68731 100644 --- a/MOVED +++ b/MOVED @@ -7789,3 +7789,4 @@ devel/py-jaraco||2023-08-21|Remove obsoleted port security/rubygem-openssl2|security/rubygem-openssl|2023-08-21|Remove obsoleted port. Use security/rubygem-openssl instead games/cataclysm-dda-tiles|games/cataclysm-dda@tiles|2023-08-22|Moved to a flavored version devel/lua-language-server||2023-08-22|Has expired: Versions after 3.6.9 dump core (and do not compile) +security/py-netbox-secretstore|security/py-netbox-secrets|2023-08-22|Has expired: No longer maintained by upstream, not compatible with NetBox 3.5, please migrate to security/py-netbox-secrets diff --git a/security/Makefile b/security/Makefile index 573141cee499..cb182a1516e0 100644 --- a/security/Makefile +++ b/security/Makefile @@ -948,7 +948,6 @@ SUBDIR += py-muacrypt SUBDIR += py-nassl SUBDIR += py-netbox-secrets - SUBDIR += py-netbox-secretstore SUBDIR += py-netmiko SUBDIR += py-noiseprotocol SUBDIR += py-notus-scanner diff --git a/security/py-netbox-secretstore/Makefile b/security/py-netbox-secretstore/Makefile deleted file mode 100644 index f0b68fe0ca3b..000000000000 --- a/security/py-netbox-secretstore/Makefile +++ /dev/null @@ -1,29 +0,0 @@ -PORTNAME= netbox-secretstore -DISTVERSION= 1.4.1 -PORTREVISION= 2 -CATEGORIES= security python -MASTER_SITES= PYPI -PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} - -MAINTAINER= kai@FreeBSD.org -COMMENT= Secret store for NetBox -WWW= https://github.com/dansheps/netbox-secretstore - -LICENSE= APACHE20 -LICENSE_FILE= ${WRKSRC}/LICENSE.txt - -DEPRECATED= No longer maintained by upstream, not compatible with NetBox 3.5, please migrate to security/py-netbox-secrets -EXPIRATION_DATE= 2023-08-15 - -RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}importlib-metadata>0:devel/py-importlib-metadata@${PY_FLAVOR} \ - ${PYTHON_PKGNAMEPREFIX}pycryptodome>0:security/py-pycryptodome@${PY_FLAVOR} - -USES= python -USE_PYTHON= autoplist distutils - -NO_ARCH= yes - -SUB_FILES= pkg-message -SUB_LIST= PYTHON_VER=${PYTHON_VER} - -.include <bsd.port.mk> diff --git a/security/py-netbox-secretstore/distinfo b/security/py-netbox-secretstore/distinfo deleted file mode 100644 index f8cf5c30d526..000000000000 --- a/security/py-netbox-secretstore/distinfo +++ /dev/null @@ -1,3 +0,0 @@ -TIMESTAMP = 1676976590 -SHA256 (netbox-secretstore-1.4.1.tar.gz) = fb0a81cfddc38d1b3d9793ec7013fd97c7945d54c4b0989ac32f5a92920c4eaf -SIZE (netbox-secretstore-1.4.1.tar.gz) = 46819 diff --git a/security/py-netbox-secretstore/files/patch-netbox__secretstore_migrations_0006__alter__secret__custom__field__data__and__more.py b/security/py-netbox-secretstore/files/patch-netbox__secretstore_migrations_0006__alter__secret__custom__field__data__and__more.py deleted file mode 100644 index 4da31820f74e..000000000000 --- a/security/py-netbox-secretstore/files/patch-netbox__secretstore_migrations_0006__alter__secret__custom__field__data__and__more.py +++ /dev/null @@ -1,60 +0,0 @@ -From: Daniel Sheppard <dans@dansheps.com> -Date: Tue, 24 Jan 2023 13:51:57 -0600 -Subject: [PATCH] Update for missing migrations - -Obtained from: - -https://github.com/DanSheps/netbox-secretstore/commit/9c3f69e5af6f5e8d6af11f5c8ea41433ef51145c - -From: Abhimanyu Saharan <desk.abhimanyu@gmail.com> -Date: Wed, 12 Apr 2023 21:01:43 +0530 -Subject: [PATCH] fix migrations - -Obtained from: - -https://github.com/Onemind-Services-LLC/netbox-secretstore/commit/248330409413f1858daf13902fd1b409053fd846.patch - ---- netbox_secretstore/migrations/0006_alter_secret_custom_field_data_and_more.py.orig 2023-05-08 17:51:21 UTC -+++ netbox_secretstore/migrations/0006_alter_secret_custom_field_data_and_more.py -@@ -0,0 +1,41 @@ -+# Generated by Django 4.1.7 on 2023-04-12 15:31 -+ -+from django.conf import settings -+from django.db import migrations, models -+import django.db.models.deletion -+import utilities.json -+ -+ -+class Migration(migrations.Migration): -+ -+ dependencies = [ -+ migrations.swappable_dependency(settings.AUTH_USER_MODEL), -+ ("netbox_secretstore", "0005_alter_secret_created_alter_secret_id_and_more"), -+ ] -+ -+ operations = [ -+ migrations.AlterField( -+ model_name="secret", -+ name="custom_field_data", -+ field=models.JSONField( -+ blank=True, default=dict, encoder=utilities.json.CustomFieldJSONEncoder -+ ), -+ ), -+ migrations.AlterField( -+ model_name="secretrole", -+ name="custom_field_data", -+ field=models.JSONField( -+ blank=True, default=dict, encoder=utilities.json.CustomFieldJSONEncoder -+ ), -+ ), -+ migrations.AlterField( -+ model_name="userkey", -+ name="user", -+ field=models.OneToOneField( -+ editable=False, -+ on_delete=django.db.models.deletion.CASCADE, -+ related_name="user_key_secretstore", -+ to=settings.AUTH_USER_MODEL, -+ ), -+ ), -+ ] diff --git a/security/py-netbox-secretstore/files/patch-netbox__secretstore_models_secrets.py b/security/py-netbox-secretstore/files/patch-netbox__secretstore_models_secrets.py deleted file mode 100644 index af682f8b802a..000000000000 --- a/security/py-netbox-secretstore/files/patch-netbox__secretstore_models_secrets.py +++ /dev/null @@ -1,51 +0,0 @@ -From: Abhimanyu Saharan <desk.abhimanyu@gmail.com> -Date: Wed, 12 Apr 2023 21:01:43 +0530 -Subject: [PATCH] fix migrations - -Obtained from: - -https://github.com/Onemind-Services-LLC/netbox-secretstore/commit/248330409413f1858daf13902fd1b409053fd846.patch - ---- netbox_secretstore/models/secrets.py.orig 2022-12-31 01:50:00 UTC -+++ netbox_secretstore/models/secrets.py -@@ -21,6 +21,7 @@ from netbox_secretstore.utils import encrypt_master_ke - from netbox_secretstore.hashers import SecretValidationHasher - from netbox_secretstore.querysets import UserKeyQuerySet - from netbox_secretstore.utils import encrypt_master_key, decrypt_master_key, generate_random_key -+from taggit.managers import TaggableManager - - - __all__ = ( -@@ -47,7 +48,7 @@ class UserKey(models.Model): - user = models.OneToOneField( - to=User, - on_delete=models.CASCADE, -- related_name='user_key', -+ related_name='user_key_secretstore', - editable=False - ) - public_key = models.TextField( -@@ -256,6 +257,11 @@ class SecretRole(OrganizationalModel): - blank=True, - ) - -+ tags = TaggableManager( -+ through='extras.TaggedItem', -+ related_name='netbox_secretstore_secretroles' -+ ) -+ - objects = RestrictedQuerySet.as_manager() - - csv_headers = ['name', 'slug', 'description'] -@@ -312,6 +318,11 @@ class Secret(NetBoxModel): - hash = models.CharField( - max_length=128, - editable=False -+ ) -+ -+ tags = TaggableManager( -+ through='extras.TaggedItem', -+ related_name='netbox_secretstore_secret' - ) - - objects = RestrictedQuerySet.as_manager() diff --git a/security/py-netbox-secretstore/files/patch-netbox__secretstore_views.py b/security/py-netbox-secretstore/files/patch-netbox__secretstore_views.py deleted file mode 100644 index b9f12b55e322..000000000000 --- a/security/py-netbox-secretstore/files/patch-netbox__secretstore_views.py +++ /dev/null @@ -1,33 +0,0 @@ -From: Daniel Sheppard <dans@dansheps.com> -Date: Tue, 11 Apr 2023 08:34:04 -0500 -Subject: [PATCH] #12087 - Fix Bulk Edit update when M2M operations are present. - -Obtained from: - -https://github.com/DanSheps/netbox-secretstore/commit/7ad1ba639aa077c45bcac05dc025132c6bd9139e.patch - ---- netbox_secretstore/views.py.orig 2022-12-31 01:50:00 UTC -+++ netbox_secretstore/views.py -@@ -156,15 +156,15 @@ class SecretEditView(ObjectEditView): - secret.plaintext = str(form.cleaned_data['plaintext']) - secret.encrypt(master_key) - -- secret.save() -- form.save_m2m() -+ secret.save() -+ form.save_m2m() - -- msg = '{} secret'.format('Created' if not form.instance.pk else 'Modified') -- logger.info(f"{msg} {secret} (PK: {secret.pk})") -- msg = f'{msg} <a href="{secret.get_absolute_url()}">{escape(secret)}</a>' -- messages.success(request, mark_safe(msg)) -+ msg = '{} secret'.format('Created' if not form.instance.pk else 'Modified') -+ logger.info(f"{msg} {secret} (PK: {secret.pk})") -+ msg = f'{msg} <a href="{secret.get_absolute_url()}">{escape(secret)}</a>' -+ messages.success(request, mark_safe(msg)) - -- return redirect(self.get_return_url(request, secret)) -+ return redirect(self.get_return_url(request, secret)) - - else: - logger.debug("Form validation failed") diff --git a/security/py-netbox-secretstore/files/pkg-message.in b/security/py-netbox-secretstore/files/pkg-message.in deleted file mode 100644 index 5e2a87dc3ef3..000000000000 --- a/security/py-netbox-secretstore/files/pkg-message.in +++ /dev/null @@ -1,110 +0,0 @@ -[ -{ type: install - message: <<EOD -To enable the plugin please do the following steps: - -1. Add/update the following line in the netbox configuration (usually - %%LOCALBASE%%/share/netbox/netbox/configuration.py): - - PLUGINS = ['netbox_secretstore'] - -2. Run NetBox migrations and collect static files: - - # cd %%LOCALBASE%%/share/netbox - # python%%PYTHON_VER%% manage.py migrate - # python%%PYTHON_VER%% manage.py collectstatic --no-input - -3. Restart WSGI/httpd environment (supervisord/apache/nginx/etc.) -EOD -} -{ type: upgrade - maximum_version: 1.0.14 - message: <<EOD -Due to some changes of net-mgmt/py-netbox-plugin-extensions, which is required -by security/py-netbox-secretstore, the NetBox configuration must therefore be -adjusted accordingly: - -1. Add/update the following line in the netbox configuration (usually - %%LOCALBASE%%/share/netbox/netbox/configuration.py): - - PLUGINS = ['netbox_plugin_extensions','netbox_secretstore'] - -2. Run NetBox migrations and collect static files: - - # cd %%LOCALBASE%%/share/netbox - # python%%PYTHON_VER%% manage.py migrate - # python%%PYTHON_VER%% manage.py collectstatic --no-input - -3. Restart WSGI/httpd environment (supervisord/apache/nginx/etc.) -EOD -} -{ type: upgrade - maximum_version: 1.2.0 - message: <<EOD -1. The plugin 'netbox_plugin_extensions' is no longer required since the - 1.2.0 release. Please remove it from the PLUGINS section in the nextbox - configuration. - -2. Run NetBox migrations and collect static files: - - # cd %%LOCALBASE%%/share/netbox - # python%%PYTHON_VER%% manage.py migrate - # python%%PYTHON_VER%% manage.py collectstatic --no-input - -3. Restart WSGI/httpd environment (supervisord/apache/nginx/etc.) -EOD -} -{ type: upgrade - maximum_version: 1.4.2_2 - message: <<EOD -Upstream no longer maintains py-netbox-secretstore which it is not compatible -with NetBox 3.5 or newer. To ensure compatibility with newer releases of -NetBox, the py-netbox-secrets plugin should be used instead. - -To migrate from security/py-netbox-secretstore to security/py-netbox-secrets -please do following steps: - - 1. Make a backup. - - 2. Install security/py-netbox-secrets - - 3. Enable both plugins by updating the following line in the netbox - configuration (usually %%LOCALBASE%%/share/netbox/netbox/configuration.py): - - PLUGINS = ['netbox_secretstore', 'netbox_secrets'] - - 4. Run NetBox migrations: - - # cd %%LOCALBASE%%/share/netbox - # python%%PYTHON_VER%% manage.py migrate - - 5. Re-adjust the indices for the netbox-secrets plugin: - - # python%%PYTHON_VER%% manage.py sqlsequencereset netbox_secrets > output.sql - - 6. Run the output of the previous command in the database, e.g.: - - # psql -d NETBOXDB < output.sql - - 7. You can now remove netbox-secretstore from the application by removing it - from the PLUGINS line in the netbox configuration: - - PLUGINS = ['netbox_secrets'] - - 8. Collect static files of the netbox-secrets plugin: - - # python%%PYTHON_VER%% manage.py collectstatic --no-input - - 9. Restart WSGI/httpd environment (supervisord/apache/nginx/etc.). - -10. You may have clean up your database of the old tables manually, e.g.: - - DROP TABLE netbox_secretstore_secret; - DROP TABLE netbox_secretstore_secretrole; - DROP TABLE netbox_secretstore_sessionkey; - DROP TABLE netbox_secretstore_userkey; - -11. Uninstall security/py-netbox-secretstore. -EOD -} -] diff --git a/security/py-netbox-secretstore/pkg-descr b/security/py-netbox-secretstore/pkg-descr deleted file mode 100644 index 5ce4d2562736..000000000000 --- a/security/py-netbox-secretstore/pkg-descr +++ /dev/null @@ -1,2 +0,0 @@ -With NetBox 3.0 the secrets are no longer managed by NetBox itself. This is -the continuation of the secrets app.