diff --git a/modules/restricted-guests/synapse/README.md b/modules/restricted-guests/synapse/README.md index 5db9f5c867..958806ae7f 100644 --- a/modules/restricted-guests/synapse/README.md +++ b/modules/restricted-guests/synapse/README.md @@ -91,3 +91,15 @@ The module is not published to a python registry, but we provide a docker contai + name: synapse-modules # ... ``` + +## Copyright & License + +Copyright 2023 Nordeck IT + Consulting GmbH +Copyright (c) 2025 New Vector Ltd + +This software is multi licensed by New Vector Ltd (Element). It can be used either: + +(1) for free under the terms of the GNU Affero General Public License (as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version); OR + +(2) under the terms of a paid-for Element Commercial License agreement between you and Element (the terms of which may vary depending on what you and Element have agreed to). +Unless required by applicable law or agreed to in writing, software distributed under the Licenses is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the Licenses for the specific language governing permissions and limitations under the Licenses. diff --git a/modules/restricted-guests/synapse/package.json b/modules/restricted-guests/synapse/package.json index 00d2345ef8..529323342e 100644 --- a/modules/restricted-guests/synapse/package.json +++ b/modules/restricted-guests/synapse/package.json @@ -4,7 +4,7 @@ "private": true, "description": "A synapse module to restrict the actions of guests", "author": "New Vector Ltd.", - "license": "Apache-2.0", + "license": "SEE LICENSE IN README.md", "scripts": { "prepare": "echo \"Nothing to prepare\"", "clean": "echo \"Nothing to clean\"", diff --git a/modules/restricted-guests/synapse/scripts/run_in_venv.sh b/modules/restricted-guests/synapse/scripts/run_in_venv.sh index 21e676f0c0..3c97ad3e8c 100755 --- a/modules/restricted-guests/synapse/scripts/run_in_venv.sh +++ b/modules/restricted-guests/synapse/scripts/run_in_venv.sh @@ -1,19 +1,8 @@ #!/usr/bin/env sh - -# Copyright 2023 Nordeck IT + Consulting GmbH -# Copyright 2025 New Vector Ltd. +# Copyright (C) 2025 New Vector Ltd. # -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +# Please see LICENSE files in the repository root for full details. # A script to run a command in a python virtual environment that is stored in # `/.venv`. If the virtual environment doesn't exist yet, it will diff --git a/modules/restricted-guests/synapse/setup.cfg b/modules/restricted-guests/synapse/setup.cfg index 8eeff887b1..4ebc42cd85 100644 --- a/modules/restricted-guests/synapse/setup.cfg +++ b/modules/restricted-guests/synapse/setup.cfg @@ -4,9 +4,10 @@ description = A synapse module to restrict the actions of guests long_description = file: README.md long_description_content_type = text/markdown version = 1.0.0 - -classifiers = - License :: OSI Approved :: Apache Software License +license = AGPL-3.0-only OR LicenseRef-Element-Commercial +license_files = + ../../../LICENSE-AGPL-3.0 + ../../../LICENSE-COMMERCIAL [options] diff --git a/modules/restricted-guests/synapse/synapse_guest_module/__init__.py b/modules/restricted-guests/synapse/synapse_guest_module/__init__.py index fc47effa9f..33a6e8331f 100644 --- a/modules/restricted-guests/synapse/synapse_guest_module/__init__.py +++ b/modules/restricted-guests/synapse/synapse_guest_module/__init__.py @@ -1,17 +1,11 @@ # Copyright 2023 Nordeck IT + Consulting GmbH -# Copyright 2025 New Vector Ltd. +# Copyright (C) 2025 New Vector Ltd. # -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at +# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +# Please see LICENSE files in the repository root for full details. # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Originally licensed under the Apache License, Version 2.0: +# . from synapse_guest_module.guest_module import GuestModule diff --git a/modules/restricted-guests/synapse/synapse_guest_module/config.py b/modules/restricted-guests/synapse/synapse_guest_module/config.py index 2ef607a491..4a53ae47c5 100644 --- a/modules/restricted-guests/synapse/synapse_guest_module/config.py +++ b/modules/restricted-guests/synapse/synapse_guest_module/config.py @@ -1,17 +1,11 @@ # Copyright 2023 Nordeck IT + Consulting GmbH -# Copyright 2025 New Vector Ltd. +# Copyright (C) 2025 New Vector Ltd. # -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at +# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +# Please see LICENSE files in the repository root for full details. # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Originally licensed under the Apache License, Version 2.0: +# . import attr diff --git a/modules/restricted-guests/synapse/synapse_guest_module/guest_module.py b/modules/restricted-guests/synapse/synapse_guest_module/guest_module.py index 89fb3f87de..ec09c0a58b 100644 --- a/modules/restricted-guests/synapse/synapse_guest_module/guest_module.py +++ b/modules/restricted-guests/synapse/synapse_guest_module/guest_module.py @@ -1,17 +1,11 @@ # Copyright 2023 Nordeck IT + Consulting GmbH -# Copyright 2025 New Vector Ltd. +# Copyright (C) 2025 New Vector Ltd. # -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at +# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +# Please see LICENSE files in the repository root for full details. # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Originally licensed under the Apache License, Version 2.0: +# . import logging from typing import Any, Dict, Literal, Tuple, Union diff --git a/modules/restricted-guests/synapse/synapse_guest_module/guest_registration_servlet.py b/modules/restricted-guests/synapse/synapse_guest_module/guest_registration_servlet.py index 7f9849d781..4555823b22 100644 --- a/modules/restricted-guests/synapse/synapse_guest_module/guest_registration_servlet.py +++ b/modules/restricted-guests/synapse/synapse_guest_module/guest_registration_servlet.py @@ -1,17 +1,11 @@ # Copyright 2023 Nordeck IT + Consulting GmbH -# Copyright 2025 New Vector Ltd. +# Copyright (C) 2025 New Vector Ltd. # -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at +# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +# Please see LICENSE files in the repository root for full details. # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Originally licensed under the Apache License, Version 2.0: +# . import logging import secrets diff --git a/modules/restricted-guests/synapse/synapse_guest_module/guest_user_reaper.py b/modules/restricted-guests/synapse/synapse_guest_module/guest_user_reaper.py index c2492be9bb..d03d5da4f4 100644 --- a/modules/restricted-guests/synapse/synapse_guest_module/guest_user_reaper.py +++ b/modules/restricted-guests/synapse/synapse_guest_module/guest_user_reaper.py @@ -1,17 +1,11 @@ # Copyright 2023 Nordeck IT + Consulting GmbH -# Copyright 2025 New Vector Ltd. +# Copyright (C) 2025 New Vector Ltd. # -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at +# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +# Please see LICENSE files in the repository root for full details. # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Originally licensed under the Apache License, Version 2.0: +# . import logging import time diff --git a/modules/restricted-guests/synapse/tests/__init__.py b/modules/restricted-guests/synapse/tests/__init__.py index 49012b4ca7..4def99172a 100644 --- a/modules/restricted-guests/synapse/tests/__init__.py +++ b/modules/restricted-guests/synapse/tests/__init__.py @@ -1,17 +1,11 @@ # Copyright 2023 Nordeck IT + Consulting GmbH -# Copyright 2025 New Vector Ltd. +# Copyright (C) 2025 New Vector Ltd. # -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at +# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +# Please see LICENSE files in the repository root for full details. # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Originally licensed under the Apache License, Version 2.0: +# . import sqlite3 from asyncio import Future diff --git a/modules/restricted-guests/synapse/tests/test_guest_module.py b/modules/restricted-guests/synapse/tests/test_guest_module.py index c5d7164edf..c08ce3071d 100644 --- a/modules/restricted-guests/synapse/tests/test_guest_module.py +++ b/modules/restricted-guests/synapse/tests/test_guest_module.py @@ -1,17 +1,11 @@ # Copyright 2023 Nordeck IT + Consulting GmbH -# Copyright 2025 New Vector Ltd. +# Copyright (C) 2025 New Vector Ltd. # -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at +# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +# Please see LICENSE files in the repository root for full details. # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Originally licensed under the Apache License, Version 2.0: +# . import aiounittest from synapse.module_api import ProfileInfo, UserProfile diff --git a/modules/restricted-guests/synapse/tests/test_guest_registration_servlet.py b/modules/restricted-guests/synapse/tests/test_guest_registration_servlet.py index e8700d2f03..314264b657 100644 --- a/modules/restricted-guests/synapse/tests/test_guest_registration_servlet.py +++ b/modules/restricted-guests/synapse/tests/test_guest_registration_servlet.py @@ -1,17 +1,11 @@ # Copyright 2023 Nordeck IT + Consulting GmbH -# Copyright 2025 New Vector Ltd. +# Copyright (C) 2025 New Vector Ltd. # -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at +# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +# Please see LICENSE files in the repository root for full details. # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Originally licensed under the Apache License, Version 2.0: +# . import io from typing import cast diff --git a/modules/restricted-guests/synapse/tests/test_guest_user_reaper.py b/modules/restricted-guests/synapse/tests/test_guest_user_reaper.py index 191312f380..3ad2b03d6a 100644 --- a/modules/restricted-guests/synapse/tests/test_guest_user_reaper.py +++ b/modules/restricted-guests/synapse/tests/test_guest_user_reaper.py @@ -1,17 +1,11 @@ # Copyright 2023 Nordeck IT + Consulting GmbH -# Copyright 2025 New Vector Ltd. +# Copyright (C) 2025 New Vector Ltd. # -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at +# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +# Please see LICENSE files in the repository root for full details. # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Originally licensed under the Apache License, Version 2.0: +# . import time from unittest.mock import call