diff --git a/application/.env b/application/.env index d3368bb51..8089ed312 100644 --- a/application/.env +++ b/application/.env @@ -37,3 +37,9 @@ MAPBENDER_DATABASE_URL="sqlite:///%kernel.project_dir%/var/db/demo.sqlite" ###> mapbender/mapbender ### KERNEL_CLASS="\Mapbender\BaseKernel" ###< mapbender/mapbender ### + +###> lexik/jwt-authentication-bundle ### +JWT_SECRET_KEY=%kernel.project_dir%/config/jwt/private.pem +JWT_PUBLIC_KEY=%kernel.project_dir%/config/jwt/public.pem +JWT_PASSPHRASE= +###< lexik/jwt-authentication-bundle ### diff --git a/application/.gitignore b/application/.gitignore index b2cecce64..4816e23b2 100644 --- a/application/.gitignore +++ b/application/.gitignore @@ -17,3 +17,7 @@ var/* .phpunit.result.cache .phpunit.cache ###< phpunit/phpunit ### + +###> lexik/jwt-authentication-bundle ### +/config/jwt/*.pem +###< lexik/jwt-authentication-bundle ### diff --git a/application/composer.json b/application/composer.json index b4cf8e655..da91966fe 100644 --- a/application/composer.json +++ b/application/composer.json @@ -29,8 +29,9 @@ "php": ">=8.1", "components/font-awesome": "^6.0", "doctrine/dbal": "^3", + "lexik/jwt-authentication-bundle": "3.1.0", "mapbender/digitizer": "^2", - "mapbender/mapbender": "^4", + "mapbender/mapbender": "dev-feature/mbapi as 4.0.0", "mnsami/composer-custom-directory-installer": "^1 || ^2", "proj4js/proj4js": "^2.4", "select2/select2": "^4.0", diff --git a/application/composer.lock b/application/composer.lock index fcc19d82e..aba2fe745 100644 --- a/application/composer.lock +++ b/application/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "8dcacaf2a9dbfaf8eca01807b752da7e", + "content-hash": "e9c942b903c8bdfd9b7c46572ff1231f", "packages": [ { "name": "assetic/framework", @@ -1478,6 +1478,258 @@ }, "type": "library" }, + { + "name": "lcobucci/clock", + "version": "3.3.1", + "source": { + "type": "git", + "url": "https://github.com/lcobucci/clock.git", + "reference": "db3713a61addfffd615b79bf0bc22f0ccc61b86b" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/lcobucci/clock/zipball/db3713a61addfffd615b79bf0bc22f0ccc61b86b", + "reference": "db3713a61addfffd615b79bf0bc22f0ccc61b86b", + "shasum": "" + }, + "require": { + "php": "~8.2.0 || ~8.3.0 || ~8.4.0", + "psr/clock": "^1.0" + }, + "provide": { + "psr/clock-implementation": "1.0" + }, + "require-dev": { + "infection/infection": "^0.29", + "lcobucci/coding-standard": "^11.1.0", + "phpstan/extension-installer": "^1.3.1", + "phpstan/phpstan": "^1.10.25", + "phpstan/phpstan-deprecation-rules": "^1.1.3", + "phpstan/phpstan-phpunit": "^1.3.13", + "phpstan/phpstan-strict-rules": "^1.5.1", + "phpunit/phpunit": "^11.3.6" + }, + "type": "library", + "autoload": { + "psr-4": { + "Lcobucci\\Clock\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Luís Cobucci", + "email": "lcobucci@gmail.com" + } + ], + "description": "Yet another clock abstraction", + "support": { + "issues": "https://github.com/lcobucci/clock/issues", + "source": "https://github.com/lcobucci/clock/tree/3.3.1" + }, + "funding": [ + { + "url": "https://github.com/lcobucci", + "type": "github" + }, + { + "url": "https://www.patreon.com/lcobucci", + "type": "patreon" + } + ], + "time": "2024-09-24T20:45:14+00:00" + }, + { + "name": "lcobucci/jwt", + "version": "5.4.1", + "source": { + "type": "git", + "url": "https://github.com/lcobucci/jwt.git", + "reference": "848815d2287abd5d3c285482f8e1f501b289a2e7" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/lcobucci/jwt/zipball/848815d2287abd5d3c285482f8e1f501b289a2e7", + "reference": "848815d2287abd5d3c285482f8e1f501b289a2e7", + "shasum": "" + }, + "require": { + "ext-openssl": "*", + "ext-sodium": "*", + "php": "~8.2.0 || ~8.3.0 || ~8.4.0", + "psr/clock": "^1.0" + }, + "require-dev": { + "infection/infection": "^0.29", + "lcobucci/clock": "^3.2", + "lcobucci/coding-standard": "^11.0", + "phpbench/phpbench": "^1.2", + "phpstan/extension-installer": "^1.2", + "phpstan/phpstan": "^1.10.7", + "phpstan/phpstan-deprecation-rules": "^1.1.3", + "phpstan/phpstan-phpunit": "^1.3.10", + "phpstan/phpstan-strict-rules": "^1.5.0", + "phpunit/phpunit": "^11.1" + }, + "suggest": { + "lcobucci/clock": ">= 3.2" + }, + "type": "library", + "autoload": { + "psr-4": { + "Lcobucci\\JWT\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Luís Cobucci", + "email": "lcobucci@gmail.com", + "role": "Developer" + } + ], + "description": "A simple library to work with JSON Web Token and JSON Web Signature", + "keywords": [ + "JWS", + "jwt" + ], + "support": { + "issues": "https://github.com/lcobucci/jwt/issues", + "source": "https://github.com/lcobucci/jwt/tree/5.4.1" + }, + "funding": [ + { + "url": "https://github.com/lcobucci", + "type": "github" + }, + { + "url": "https://www.patreon.com/lcobucci", + "type": "patreon" + } + ], + "time": "2024-11-06T06:16:04+00:00" + }, + { + "name": "lexik/jwt-authentication-bundle", + "version": "v3.1.0", + "source": { + "type": "git", + "url": "https://github.com/lexik/LexikJWTAuthenticationBundle.git", + "reference": "4f1a638289cf9282bad1b82b8df56d3bd4e0743c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/lexik/LexikJWTAuthenticationBundle/zipball/4f1a638289cf9282bad1b82b8df56d3bd4e0743c", + "reference": "4f1a638289cf9282bad1b82b8df56d3bd4e0743c", + "shasum": "" + }, + "require": { + "ext-openssl": "*", + "lcobucci/clock": "^3.0", + "lcobucci/jwt": "^5.0", + "php": ">=8.2", + "symfony/config": "^6.4|^7.0", + "symfony/dependency-injection": "^6.4|^7.0", + "symfony/deprecation-contracts": "^2.4|^3.0", + "symfony/event-dispatcher": "^6.4|^7.0", + "symfony/http-foundation": "^6.4|^7.0", + "symfony/http-kernel": "^6.4|^7.0", + "symfony/property-access": "^6.4|^7.0", + "symfony/security-bundle": "^6.4|^7.0", + "symfony/translation-contracts": "^1.0|^2.0|^3.0" + }, + "require-dev": { + "api-platform/core": "^3.0", + "symfony/browser-kit": "^6.4|^7.0", + "symfony/console": "^6.4|^7.0", + "symfony/dom-crawler": "^6.4|^7.0", + "symfony/filesystem": "^6.4|^7.0", + "symfony/framework-bundle": "^6.4|^7.0", + "symfony/phpunit-bridge": "^6.4|^7.0", + "symfony/var-dumper": "^6.4|^7.0", + "symfony/yaml": "^6.4|^7.0" + }, + "suggest": { + "gesdinet/jwt-refresh-token-bundle": "Implements a refresh token system over Json Web Tokens in Symfony", + "spomky-labs/lexik-jose-bridge": "Provides a JWT Token encoder with encryption support" + }, + "type": "symfony-bundle", + "autoload": { + "psr-4": { + "Lexik\\Bundle\\JWTAuthenticationBundle\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jeremy Barthe", + "email": "j.barthe@lexik.fr", + "homepage": "https://github.com/jeremyb" + }, + { + "name": "Nicolas Cabot", + "email": "n.cabot@lexik.fr", + "homepage": "https://github.com/slashfan" + }, + { + "name": "Cedric Girard", + "email": "c.girard@lexik.fr", + "homepage": "https://github.com/cedric-g" + }, + { + "name": "Dev Lexik", + "email": "dev@lexik.fr", + "homepage": "https://github.com/lexik" + }, + { + "name": "Robin Chalas", + "email": "robin.chalas@gmail.com", + "homepage": "https://github.com/chalasr" + }, + { + "name": "Lexik Community", + "homepage": "https://github.com/lexik/LexikJWTAuthenticationBundle/graphs/contributors" + } + ], + "description": "This bundle provides JWT authentication for your Symfony REST API", + "homepage": "https://github.com/lexik/LexikJWTAuthenticationBundle", + "keywords": [ + "Authentication", + "JWS", + "api", + "bundle", + "jwt", + "rest", + "symfony" + ], + "support": { + "issues": "https://github.com/lexik/LexikJWTAuthenticationBundle/issues", + "source": "https://github.com/lexik/LexikJWTAuthenticationBundle/tree/v3.1.0" + }, + "funding": [ + { + "url": "https://github.com/chalasr", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/lexik/jwt-authentication-bundle", + "type": "tidelift" + } + ], + "time": "2024-07-03T20:49:59+00:00" + }, { "name": "mapbender/digitizer", "version": "2.0.1", @@ -1561,16 +1813,16 @@ }, { "name": "mapbender/mapbender", - "version": "v4.0.2", + "version": "dev-feature/mbapi", "source": { "type": "git", "url": "https://github.com/mapbender/mapbender.git", - "reference": "8681dd6d058604d24168e1d99a2b8c9c76fa5fff" + "reference": "50c60b9960813fa41b4d1b7066c112713e041183" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/mapbender/mapbender/zipball/8681dd6d058604d24168e1d99a2b8c9c76fa5fff", - "reference": "8681dd6d058604d24168e1d99a2b8c9c76fa5fff", + "url": "https://api.github.com/repos/mapbender/mapbender/zipball/50c60b9960813fa41b4d1b7066c112713e041183", + "reference": "50c60b9960813fa41b4d1b7066c112713e041183", "shasum": "" }, "require": { @@ -1685,9 +1937,9 @@ ], "support": { "issues": "https://github.com/mapbender/mapbender/issues", - "source": "https://github.com/mapbender/mapbender/tree/v4.0.2" + "source": "https://github.com/mapbender/mapbender/tree/feature/mbapi" }, - "time": "2024-09-25T11:53:00+00:00" + "time": "2024-11-04T13:11:31+00:00" }, { "name": "mapbender/mapbender-icons", @@ -2786,16 +3038,16 @@ }, { "name": "symfony/clock", - "version": "v6.4.8", + "version": "v6.4.13", "source": { "type": "git", "url": "https://github.com/symfony/clock.git", - "reference": "7a4840efd17135cbd547e41ec49fb910ed4f8b98" + "reference": "b2bf55c4dd115003309eafa87ee7df9ed3dde81b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/clock/zipball/7a4840efd17135cbd547e41ec49fb910ed4f8b98", - "reference": "7a4840efd17135cbd547e41ec49fb910ed4f8b98", + "url": "https://api.github.com/repos/symfony/clock/zipball/b2bf55c4dd115003309eafa87ee7df9ed3dde81b", + "reference": "b2bf55c4dd115003309eafa87ee7df9ed3dde81b", "shasum": "" }, "require": { @@ -2840,7 +3092,7 @@ "time" ], "support": { - "source": "https://github.com/symfony/clock/tree/v6.4.8" + "source": "https://github.com/symfony/clock/tree/v6.4.13" }, "funding": [ { @@ -2856,20 +3108,20 @@ "type": "tidelift" } ], - "time": "2024-05-31T14:51:39+00:00" + "time": "2024-09-25T14:18:03+00:00" }, { "name": "symfony/config", - "version": "v6.4.8", + "version": "v6.4.14", "source": { "type": "git", "url": "https://github.com/symfony/config.git", - "reference": "12e7e52515ce37191b193cf3365903c4f3951e35" + "reference": "4e55e7e4ffddd343671ea972216d4509f46c22ef" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/config/zipball/12e7e52515ce37191b193cf3365903c4f3951e35", - "reference": "12e7e52515ce37191b193cf3365903c4f3951e35", + "url": "https://api.github.com/repos/symfony/config/zipball/4e55e7e4ffddd343671ea972216d4509f46c22ef", + "reference": "4e55e7e4ffddd343671ea972216d4509f46c22ef", "shasum": "" }, "require": { @@ -2915,7 +3167,7 @@ "description": "Helps you find, load, combine, autofill and validate configuration values of any kind", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/config/tree/v6.4.8" + "source": "https://github.com/symfony/config/tree/v6.4.14" }, "funding": [ { @@ -2931,7 +3183,7 @@ "type": "tidelift" } ], - "time": "2024-05-31T14:49:08+00:00" + "time": "2024-11-04T11:33:53+00:00" }, { "name": "symfony/console", @@ -3103,16 +3355,16 @@ }, { "name": "symfony/dependency-injection", - "version": "v6.4.12", + "version": "v6.4.13", "source": { "type": "git", "url": "https://github.com/symfony/dependency-injection.git", - "reference": "cfb9d34a1cdd4911bc737a5358fd1cf8ebfb536e" + "reference": "728ae8f4e190133ce99d6d5f0bc1e8c8bd7c7a96" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/dependency-injection/zipball/cfb9d34a1cdd4911bc737a5358fd1cf8ebfb536e", - "reference": "cfb9d34a1cdd4911bc737a5358fd1cf8ebfb536e", + "url": "https://api.github.com/repos/symfony/dependency-injection/zipball/728ae8f4e190133ce99d6d5f0bc1e8c8bd7c7a96", + "reference": "728ae8f4e190133ce99d6d5f0bc1e8c8bd7c7a96", "shasum": "" }, "require": { @@ -3164,7 +3416,7 @@ "description": "Allows you to standardize and centralize the way objects are constructed in your application", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/dependency-injection/tree/v6.4.12" + "source": "https://github.com/symfony/dependency-injection/tree/v6.4.13" }, "funding": [ { @@ -3180,7 +3432,7 @@ "type": "tidelift" } ], - "time": "2024-09-20T08:18:25+00:00" + "time": "2024-10-25T15:07:50+00:00" }, { "name": "symfony/deprecation-contracts", @@ -3433,16 +3685,16 @@ }, { "name": "symfony/error-handler", - "version": "v6.4.10", + "version": "v6.4.14", "source": { "type": "git", "url": "https://github.com/symfony/error-handler.git", - "reference": "231f1b2ee80f72daa1972f7340297d67439224f0" + "reference": "9e024324511eeb00983ee76b9aedc3e6ecd993d9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/error-handler/zipball/231f1b2ee80f72daa1972f7340297d67439224f0", - "reference": "231f1b2ee80f72daa1972f7340297d67439224f0", + "url": "https://api.github.com/repos/symfony/error-handler/zipball/9e024324511eeb00983ee76b9aedc3e6ecd993d9", + "reference": "9e024324511eeb00983ee76b9aedc3e6ecd993d9", "shasum": "" }, "require": { @@ -3488,7 +3740,7 @@ "description": "Provides tools to manage errors and ease debugging PHP code", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/error-handler/tree/v6.4.10" + "source": "https://github.com/symfony/error-handler/tree/v6.4.14" }, "funding": [ { @@ -3504,20 +3756,20 @@ "type": "tidelift" } ], - "time": "2024-07-26T12:30:32+00:00" + "time": "2024-11-05T15:34:40+00:00" }, { "name": "symfony/event-dispatcher", - "version": "v6.4.8", + "version": "v6.4.13", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher.git", - "reference": "8d7507f02b06e06815e56bb39aa0128e3806208b" + "reference": "0ffc48080ab3e9132ea74ef4e09d8dcf26bf897e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/8d7507f02b06e06815e56bb39aa0128e3806208b", - "reference": "8d7507f02b06e06815e56bb39aa0128e3806208b", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/0ffc48080ab3e9132ea74ef4e09d8dcf26bf897e", + "reference": "0ffc48080ab3e9132ea74ef4e09d8dcf26bf897e", "shasum": "" }, "require": { @@ -3568,7 +3820,7 @@ "description": "Provides tools that allow your application components to communicate with each other by dispatching events and listening to them", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/event-dispatcher/tree/v6.4.8" + "source": "https://github.com/symfony/event-dispatcher/tree/v6.4.13" }, "funding": [ { @@ -3584,7 +3836,7 @@ "type": "tidelift" } ], - "time": "2024-05-31T14:49:08+00:00" + "time": "2024-09-25T14:18:03+00:00" }, { "name": "symfony/event-dispatcher-contracts", @@ -3664,16 +3916,16 @@ }, { "name": "symfony/filesystem", - "version": "v6.4.12", + "version": "v6.4.13", "source": { "type": "git", "url": "https://github.com/symfony/filesystem.git", - "reference": "f810e3cbdf7fdc35983968523d09f349fa9ada12" + "reference": "4856c9cf585d5a0313d8d35afd681a526f038dd3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/filesystem/zipball/f810e3cbdf7fdc35983968523d09f349fa9ada12", - "reference": "f810e3cbdf7fdc35983968523d09f349fa9ada12", + "url": "https://api.github.com/repos/symfony/filesystem/zipball/4856c9cf585d5a0313d8d35afd681a526f038dd3", + "reference": "4856c9cf585d5a0313d8d35afd681a526f038dd3", "shasum": "" }, "require": { @@ -3710,7 +3962,7 @@ "description": "Provides basic utilities for the filesystem", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/filesystem/tree/v6.4.12" + "source": "https://github.com/symfony/filesystem/tree/v6.4.13" }, "funding": [ { @@ -3726,7 +3978,7 @@ "type": "tidelift" } ], - "time": "2024-09-16T16:01:33+00:00" + "time": "2024-10-25T15:07:50+00:00" }, { "name": "symfony/finder", @@ -4275,16 +4527,16 @@ }, { "name": "symfony/http-foundation", - "version": "v6.4.12", + "version": "v6.4.14", "source": { "type": "git", "url": "https://github.com/symfony/http-foundation.git", - "reference": "133ac043875f59c26c55e79cf074562127cce4d2" + "reference": "ba020a321a95519303a3f09ec2824d34d601c388" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-foundation/zipball/133ac043875f59c26c55e79cf074562127cce4d2", - "reference": "133ac043875f59c26c55e79cf074562127cce4d2", + "url": "https://api.github.com/repos/symfony/http-foundation/zipball/ba020a321a95519303a3f09ec2824d34d601c388", + "reference": "ba020a321a95519303a3f09ec2824d34d601c388", "shasum": "" }, "require": { @@ -4332,7 +4584,7 @@ "description": "Defines an object-oriented layer for the HTTP specification", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/http-foundation/tree/v6.4.12" + "source": "https://github.com/symfony/http-foundation/tree/v6.4.14" }, "funding": [ { @@ -4348,20 +4600,20 @@ "type": "tidelift" } ], - "time": "2024-09-20T08:18:25+00:00" + "time": "2024-11-05T16:39:55+00:00" }, { "name": "symfony/http-kernel", - "version": "v6.4.12", + "version": "v6.4.14", "source": { "type": "git", "url": "https://github.com/symfony/http-kernel.git", - "reference": "96df83d51b5f78804f70c093b97310794fd6257b" + "reference": "8278a947d0369754a47b758a9e17b72cab970951" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-kernel/zipball/96df83d51b5f78804f70c093b97310794fd6257b", - "reference": "96df83d51b5f78804f70c093b97310794fd6257b", + "url": "https://api.github.com/repos/symfony/http-kernel/zipball/8278a947d0369754a47b758a9e17b72cab970951", + "reference": "8278a947d0369754a47b758a9e17b72cab970951", "shasum": "" }, "require": { @@ -4446,7 +4698,7 @@ "description": "Provides a structured process for converting a Request into a Response", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/http-kernel/tree/v6.4.12" + "source": "https://github.com/symfony/http-kernel/tree/v6.4.14" }, "funding": [ { @@ -4462,7 +4714,7 @@ "type": "tidelift" } ], - "time": "2024-09-21T06:02:57+00:00" + "time": "2024-11-06T09:45:21+00:00" }, { "name": "symfony/intl", @@ -4941,16 +5193,16 @@ }, { "name": "symfony/password-hasher", - "version": "v6.4.8", + "version": "v6.4.13", "source": { "type": "git", "url": "https://github.com/symfony/password-hasher.git", - "reference": "90ebbe946e5d64a5fad9ac9427e335045cf2bd31" + "reference": "e97a1b31f60b8bdfc1fdedab4398538da9441d47" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/password-hasher/zipball/90ebbe946e5d64a5fad9ac9427e335045cf2bd31", - "reference": "90ebbe946e5d64a5fad9ac9427e335045cf2bd31", + "url": "https://api.github.com/repos/symfony/password-hasher/zipball/e97a1b31f60b8bdfc1fdedab4398538da9441d47", + "reference": "e97a1b31f60b8bdfc1fdedab4398538da9441d47", "shasum": "" }, "require": { @@ -4993,7 +5245,7 @@ "password" ], "support": { - "source": "https://github.com/symfony/password-hasher/tree/v6.4.8" + "source": "https://github.com/symfony/password-hasher/tree/v6.4.13" }, "funding": [ { @@ -5009,7 +5261,7 @@ "type": "tidelift" } ], - "time": "2024-05-31T14:49:08+00:00" + "time": "2024-09-25T14:18:03+00:00" }, { "name": "symfony/polyfill-ctype", @@ -5795,16 +6047,16 @@ }, { "name": "symfony/process", - "version": "v6.4.12", + "version": "v6.4.14", "source": { "type": "git", "url": "https://github.com/symfony/process.git", - "reference": "3f94e5f13ff58df371a7ead461b6e8068900fbb3" + "reference": "25214adbb0996d18112548de20c281be9f27279f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/process/zipball/3f94e5f13ff58df371a7ead461b6e8068900fbb3", - "reference": "3f94e5f13ff58df371a7ead461b6e8068900fbb3", + "url": "https://api.github.com/repos/symfony/process/zipball/25214adbb0996d18112548de20c281be9f27279f", + "reference": "25214adbb0996d18112548de20c281be9f27279f", "shasum": "" }, "require": { @@ -5836,7 +6088,7 @@ "description": "Executes commands in sub-processes", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/process/tree/v6.4.12" + "source": "https://github.com/symfony/process/tree/v6.4.14" }, "funding": [ { @@ -5852,20 +6104,20 @@ "type": "tidelift" } ], - "time": "2024-09-17T12:47:12+00:00" + "time": "2024-11-06T09:25:01+00:00" }, { "name": "symfony/property-access", - "version": "v6.4.11", + "version": "v6.4.13", "source": { "type": "git", "url": "https://github.com/symfony/property-access.git", - "reference": "866f6cd84f2094cbc6f66ce9752faf749916e2a9" + "reference": "8cc779d88d12e440adaa26387bcfc25744064afe" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/property-access/zipball/866f6cd84f2094cbc6f66ce9752faf749916e2a9", - "reference": "866f6cd84f2094cbc6f66ce9752faf749916e2a9", + "url": "https://api.github.com/repos/symfony/property-access/zipball/8cc779d88d12e440adaa26387bcfc25744064afe", + "reference": "8cc779d88d12e440adaa26387bcfc25744064afe", "shasum": "" }, "require": { @@ -5913,7 +6165,7 @@ "reflection" ], "support": { - "source": "https://github.com/symfony/property-access/tree/v6.4.11" + "source": "https://github.com/symfony/property-access/tree/v6.4.13" }, "funding": [ { @@ -5929,20 +6181,20 @@ "type": "tidelift" } ], - "time": "2024-08-30T16:10:11+00:00" + "time": "2024-09-25T14:18:03+00:00" }, { "name": "symfony/property-info", - "version": "v6.4.10", + "version": "v6.4.13", "source": { "type": "git", "url": "https://github.com/symfony/property-info.git", - "reference": "edaea9dcc723cb4a0ab6a00f7d6f8c07c0d8ff77" + "reference": "ea388133aadf407dfa54092873d1b7e52f439515" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/property-info/zipball/edaea9dcc723cb4a0ab6a00f7d6f8c07c0d8ff77", - "reference": "edaea9dcc723cb4a0ab6a00f7d6f8c07c0d8ff77", + "url": "https://api.github.com/repos/symfony/property-info/zipball/ea388133aadf407dfa54092873d1b7e52f439515", + "reference": "ea388133aadf407dfa54092873d1b7e52f439515", "shasum": "" }, "require": { @@ -5996,7 +6248,7 @@ "validator" ], "support": { - "source": "https://github.com/symfony/property-info/tree/v6.4.10" + "source": "https://github.com/symfony/property-info/tree/v6.4.13" }, "funding": [ { @@ -6012,7 +6264,7 @@ "type": "tidelift" } ], - "time": "2024-07-26T07:32:07+00:00" + "time": "2024-09-25T14:18:03+00:00" }, { "name": "symfony/routing", @@ -6260,16 +6512,16 @@ }, { "name": "symfony/security-bundle", - "version": "v6.4.11", + "version": "v6.4.13", "source": { "type": "git", "url": "https://github.com/symfony/security-bundle.git", - "reference": "620be16fceded671823ce6332d06f44bb327096d" + "reference": "181d1fcf5f88ef8212ed7f6434e5ff51c9d7dff3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/security-bundle/zipball/620be16fceded671823ce6332d06f44bb327096d", - "reference": "620be16fceded671823ce6332d06f44bb327096d", + "url": "https://api.github.com/repos/symfony/security-bundle/zipball/181d1fcf5f88ef8212ed7f6434e5ff51c9d7dff3", + "reference": "181d1fcf5f88ef8212ed7f6434e5ff51c9d7dff3", "shasum": "" }, "require": { @@ -6352,7 +6604,7 @@ "description": "Provides a tight integration of the Security component into the Symfony full-stack framework", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/security-bundle/tree/v6.4.11" + "source": "https://github.com/symfony/security-bundle/tree/v6.4.13" }, "funding": [ { @@ -6368,20 +6620,20 @@ "type": "tidelift" } ], - "time": "2024-08-20T11:22:16+00:00" + "time": "2024-09-25T14:18:03+00:00" }, { "name": "symfony/security-core", - "version": "v6.4.12", + "version": "v6.4.13", "source": { "type": "git", "url": "https://github.com/symfony/security-core.git", - "reference": "8c7e52155262b3ef6b7885f6d9bd90fb24eaa66f" + "reference": "bbd1a919aec8696a95bf8749d5577fbe74de973c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/security-core/zipball/8c7e52155262b3ef6b7885f6d9bd90fb24eaa66f", - "reference": "8c7e52155262b3ef6b7885f6d9bd90fb24eaa66f", + "url": "https://api.github.com/repos/symfony/security-core/zipball/bbd1a919aec8696a95bf8749d5577fbe74de973c", + "reference": "bbd1a919aec8696a95bf8749d5577fbe74de973c", "shasum": "" }, "require": { @@ -6438,7 +6690,7 @@ "description": "Symfony Security Component - Core Library", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/security-core/tree/v6.4.12" + "source": "https://github.com/symfony/security-core/tree/v6.4.13" }, "funding": [ { @@ -6454,20 +6706,20 @@ "type": "tidelift" } ], - "time": "2024-09-20T08:21:33+00:00" + "time": "2024-10-25T15:07:50+00:00" }, { "name": "symfony/security-csrf", - "version": "v6.4.8", + "version": "v6.4.13", "source": { "type": "git", "url": "https://github.com/symfony/security-csrf.git", - "reference": "f46ab02b76311087873257071559edcaf6d7ab99" + "reference": "c34421b7d34efbaef5d611ab2e646a0ec464ffe3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/security-csrf/zipball/f46ab02b76311087873257071559edcaf6d7ab99", - "reference": "f46ab02b76311087873257071559edcaf6d7ab99", + "url": "https://api.github.com/repos/symfony/security-csrf/zipball/c34421b7d34efbaef5d611ab2e646a0ec464ffe3", + "reference": "c34421b7d34efbaef5d611ab2e646a0ec464ffe3", "shasum": "" }, "require": { @@ -6506,7 +6758,7 @@ "description": "Symfony Security Component - CSRF Library", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/security-csrf/tree/v6.4.8" + "source": "https://github.com/symfony/security-csrf/tree/v6.4.13" }, "funding": [ { @@ -6522,20 +6774,20 @@ "type": "tidelift" } ], - "time": "2024-05-31T14:49:08+00:00" + "time": "2024-09-25T14:18:03+00:00" }, { "name": "symfony/security-http", - "version": "v6.4.12", + "version": "v6.4.14", "source": { "type": "git", "url": "https://github.com/symfony/security-http.git", - "reference": "f6df97af71943cda726dc852335204eac02a716b" + "reference": "cc13b601fc844036fd6c8e7307845da145d5998b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/security-http/zipball/f6df97af71943cda726dc852335204eac02a716b", - "reference": "f6df97af71943cda726dc852335204eac02a716b", + "url": "https://api.github.com/repos/symfony/security-http/zipball/cc13b601fc844036fd6c8e7307845da145d5998b", + "reference": "cc13b601fc844036fd6c8e7307845da145d5998b", "shasum": "" }, "require": { @@ -6594,7 +6846,7 @@ "description": "Symfony Security Component - HTTP Integration", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/security-http/tree/v6.4.12" + "source": "https://github.com/symfony/security-http/tree/v6.4.14" }, "funding": [ { @@ -6610,7 +6862,7 @@ "type": "tidelift" } ], - "time": "2024-09-20T08:18:25+00:00" + "time": "2024-11-05T15:34:40+00:00" }, { "name": "symfony/serializer", @@ -6795,16 +7047,16 @@ }, { "name": "symfony/string", - "version": "v6.4.12", + "version": "v6.4.13", "source": { "type": "git", "url": "https://github.com/symfony/string.git", - "reference": "f8a1ccebd0997e16112dfecfd74220b78e5b284b" + "reference": "38371c60c71c72b3d64d8d76f6b1bb81a2cc3627" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/string/zipball/f8a1ccebd0997e16112dfecfd74220b78e5b284b", - "reference": "f8a1ccebd0997e16112dfecfd74220b78e5b284b", + "url": "https://api.github.com/repos/symfony/string/zipball/38371c60c71c72b3d64d8d76f6b1bb81a2cc3627", + "reference": "38371c60c71c72b3d64d8d76f6b1bb81a2cc3627", "shasum": "" }, "require": { @@ -6861,7 +7113,7 @@ "utf8" ], "support": { - "source": "https://github.com/symfony/string/tree/v6.4.12" + "source": "https://github.com/symfony/string/tree/v6.4.13" }, "funding": [ { @@ -6877,7 +7129,7 @@ "type": "tidelift" } ], - "time": "2024-09-20T08:15:52+00:00" + "time": "2024-09-25T14:18:03+00:00" }, { "name": "symfony/templating", @@ -7410,16 +7662,16 @@ }, { "name": "symfony/var-dumper", - "version": "v6.4.11", + "version": "v6.4.14", "source": { "type": "git", "url": "https://github.com/symfony/var-dumper.git", - "reference": "ee14c8254a480913268b1e3b1cba8045ed122694" + "reference": "93c09246038178717a9c14b809ea8151ffcf7091" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/var-dumper/zipball/ee14c8254a480913268b1e3b1cba8045ed122694", - "reference": "ee14c8254a480913268b1e3b1cba8045ed122694", + "url": "https://api.github.com/repos/symfony/var-dumper/zipball/93c09246038178717a9c14b809ea8151ffcf7091", + "reference": "93c09246038178717a9c14b809ea8151ffcf7091", "shasum": "" }, "require": { @@ -7475,7 +7727,7 @@ "dump" ], "support": { - "source": "https://github.com/symfony/var-dumper/tree/v6.4.11" + "source": "https://github.com/symfony/var-dumper/tree/v6.4.14" }, "funding": [ { @@ -7491,20 +7743,20 @@ "type": "tidelift" } ], - "time": "2024-08-30T16:03:21+00:00" + "time": "2024-11-05T15:34:40+00:00" }, { "name": "symfony/var-exporter", - "version": "v6.4.9", + "version": "v6.4.13", "source": { "type": "git", "url": "https://github.com/symfony/var-exporter.git", - "reference": "f9a060622e0d93777b7f8687ec4860191e16802e" + "reference": "0f605f72a363f8743001038a176eeb2a11223b51" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/var-exporter/zipball/f9a060622e0d93777b7f8687ec4860191e16802e", - "reference": "f9a060622e0d93777b7f8687ec4860191e16802e", + "url": "https://api.github.com/repos/symfony/var-exporter/zipball/0f605f72a363f8743001038a176eeb2a11223b51", + "reference": "0f605f72a363f8743001038a176eeb2a11223b51", "shasum": "" }, "require": { @@ -7552,7 +7804,7 @@ "serialize" ], "support": { - "source": "https://github.com/symfony/var-exporter/tree/v6.4.9" + "source": "https://github.com/symfony/var-exporter/tree/v6.4.13" }, "funding": [ { @@ -7568,7 +7820,7 @@ "type": "tidelift" } ], - "time": "2024-06-24T15:53:56+00:00" + "time": "2024-09-25T14:18:03+00:00" }, { "name": "symfony/web-link", @@ -9963,9 +10215,18 @@ "time": "2024-03-03T12:36:25+00:00" } ], - "aliases": [], + "aliases": [ + { + "package": "mapbender/mapbender", + "version": "dev-feature/mbapi", + "alias": "4.0.0", + "alias_normalized": "4.0.0.0" + } + ], "minimum-stability": "dev", - "stability-flags": [], + "stability-flags": { + "mapbender/mapbender": 20 + }, "prefer-stable": true, "prefer-lowest": false, "platform": { diff --git a/application/config/.gitignore b/application/config/.gitignore index 8febe0ec8..371d58a6b 100644 --- a/application/config/.gitignore +++ b/application/config/.gitignore @@ -1 +1,2 @@ parameters.yaml +jwt diff --git a/application/config/applications/mapbender_digitize_demo.yaml b/application/config/applications/mapbender_digitize_demo.yaml new file mode 100644 index 000000000..18a600c4d --- /dev/null +++ b/application/config/applications/mapbender_digitize_demo.yaml @@ -0,0 +1,1051 @@ +parameters: + applications: + mapbender_digitize_demo: + title: Mapbender Digitize Demo + screenshot: ~ + description: Try the Mapbender Digitize Demo with the Tables defined in the documentation (https://doc.mapbender.org/en/functions/editing/digitizer/digitizer_configuration.html#sql-for-the-demo-tables) or with the PostgreSQL database backup in the workshop repository (https://github.com/mapbender/mapbender-workshop/geobasis.backup). + published: true + persistentView: false + template: Mapbender\CoreBundle\Template\Fullscreen + regionProperties: + - name: sidepane + properties: + name: accordion + layersets: + main: + mapbender_users: + class: Mapbender\WmsBundle\Entity\WmsInstance + title: Mapbender Users + url: https://wms.wheregroup.com/cgi-bin/mapbender_user.xml + version: 1.3.0 + layers: + 10: { name: Mapbender_User, title : User, visible: true, legendurl: https://wms.wheregroup.com/cgi-bin/mapbender_user.xml?version=1.3.0&service=WMS&request=GetLegendGraphic&sld_version=1.1.0&layer=Mapbender_User&format=image/png&STYLE=default } + 22: { name: Mapbender_Names, title : Name, visible: true, queryable: true} + info_format: text/html + visible: true + format: image/png + transparent: true + tiled: false + opacity: 85 + basesource: false + osm: + class: Mapbender\WmsBundle\Entity\WmsInstance + title: OSM Demo + url: https://osm-demo.wheregroup.com/service + version: 1.3.0 + layers: + 30: { name: osm, title : Germany OSM Demo WhereGroup, visible: true } + info_format: text/html + visible: true + format: image/png + transparent: true + tiled: true + opacity: 100 + basesource: false + overview: + osm_overview: + class: Mapbender\WmsBundle\Entity\WmsInstance + title: OSM Demo + url: https://osm-demo.wheregroup.com/service + version: 1.3.0 + layers: + 40: { name: osm, title : Germany OSM Demo WhereGroup, visible: true } + tiled: false + format: image/png + transparent: true + visible: true + opacity: 100 + elements: + toolbar: + html-application: + title: 'HTML About Mapbender' + class: Mapbender\CoreBundle\Element\HTMLElement + classes: html-element-inline + content: "{{ application.title }}" + + fi-button: + title: mb.core.featureinfo.class.title + tooltip: mb.core.featureinfo.class.title + class: Mapbender\CoreBundle\Element\Button + icon: iconInfoActive + label: true + target: featureinfo + group: featureinfo + print-button: + title: mb.core.printclient.class.title + tooltip: mb.core.printclient.class.title + class: Mapbender\CoreBundle\Element\Button + label: false + icon: iconPrint + target: printclient + imageexport-button: + title: mb.print.imageexport.class.title + tooltip: mb.print.imageexport.class.title + class: Mapbender\CoreBundle\Element\Button + label: false + icon: iconImageExport + target: imageexport + legend-button: + title: mb.core.legend.class.title + tooltip: mb.core.legend.class.title + class: Mapbender\CoreBundle\Element\Button + label: false + target: legend + icon: iconLegend + wmsloader-button: + title: mb.wms.wmsloader.class.title + tooltip: mb.wms.wmsloader.class.description + class: Mapbender\CoreBundle\Element\Button + label: false + target: wmsloader + icon: iconWms + linerulerButton: + title: mb.core.ruler.tag.measure + tooltip: mb.core.ruler.tag.line + class: Mapbender\CoreBundle\Element\Button + icon: icon-line-ruler + label: false + target: lineruler + group: rulers + arearulerButton: + title: mb.core.ruler.tag.measure + tooltip: mb.core.ruler.tag.area + class: Mapbender\CoreBundle\Element\Button + icon: icon-area-ruler + label: false + target: arearuler + group: rulers + + poiButton: + title: mb.core.poi.class.title + tooltip: mb.core.poi.class.description + class: Mapbender\CoreBundle\Element\Button + icon: iconPoi + label: false + target: poi + + content: + map: + title: mb.core.map.class.title + class: Mapbender\CoreBundle\Element\Map + layersets: [main] + srs: EPSG:25832 + extents: + start: [361000,5619000,371150,5625000] + max: [-500000,4350000,1600000,6850000] + scales: [5000000,1000000,500000,100000,50000,25000,10000,7500,5000,2500,1000,500,250,100,50] + otherSrs: ["EPSG:25833","EPSG:31466","EPSG:31467","EPSG:3857","EPSG:4326"] + + zoombar: + class: Mapbender\CoreBundle\Element\ZoomBar + target: map + components: + - rotation + - zoom_max + - zoom_in_out + - zoom_slider + - zoom_home + anchor: right-top + draggable: false + + legend: + class: Mapbender\CoreBundle\Element\Legend + target: map + title: mb.core.legend.class.title + elementType: dialog + autoOpen: false + displayType: list + showWmsTitle: true + showLayerTitle: true + showGroupedLayerTitle: true + + featureinfo: + class: Mapbender\CoreBundle\Element\FeatureInfo + title: mb.core.featureinfo.class.title + target: map + deactivateOnClose: false + onlyValid: true + type: dialog + displayType: tabs + autoActivate: false + printResult: true + width: 500 + height: 500 + + wmsloader: + title: mb.wms.wmsloader.class.title + class: Mapbender\WmsBundle\Element\WmsLoader + target: map + autoOpen: false + defaultFormat: 'image/png' + defaultInfoFormat: 'text/html' + splitLayers: false + + imageexport: + class: Mapbender\PrintBundle\Element\ImageExport + target: map + title: Image export + + printclient: + title: mb.core.printclient.class.title + class: Mapbender\CoreBundle\Element\PrintClient + target: map + file_prefix: mapbender + templates: + - { template: a4_portrait_offical, label: A4 Portrait (official)} + - { template: a4_landscape_offical, label: A4 Landscape (official)} + - { template: a4portrait, label: A4 Portrait} + - { template: a4landscape, label: A4 Landscape} + - { template: a3portrait, label: A3 Portrait} + - { template: a3landscape, label: A3 Landscape} + - { template: a4_portrait_official_feature_data_demo, label: A4 Print with Feature Data} + scales: [500, 1000, 5000, 10000, 25000, 50000] + quality_levels: + - { dpi: 72 , label: Draft (72dpi)} + - { dpi: 288, label: Document (288dpi)} + rotatable: true + legend: true + legend_default_behaviour: false + optional_fields: + title: + label: Title # label of the optional field + options: # + required: true # true or false + + lineruler: + title: mb.core.ruler.tag.line + tooltip: 'ruler' + class: Mapbender\CoreBundle\Element\Ruler + target: map + type: line + + arearuler: + title: mb.core.ruler.tag.area + tooltip: 'area' + class: Mapbender\CoreBundle\Element\Ruler + target: map + type: area + + scalebar: + class: Mapbender\CoreBundle\Element\ScaleBar + target: map + anchor: 'left-bottom' + position: ['10px', '10px'] + maxWidth: 200 + units: km + overview: + title: mb.core.overview.class.title + class: Mapbender\CoreBundle\Element\Overview + target: map + layerset: overview + width: 200 + height: 100 + anchor: 'right-bottom' + maximized: true + fixed: false + + scaledisplay: + title: mb.core.scaledisplay.class.title + class: Mapbender\CoreBundle\Element\ScaleDisplay + target: map + anchor: left-top + scalePrefix: Scale + unitPrefix: true + + poi: + title: mb.core.poi.class.title + class: Mapbender\CoreBundle\Element\POI + target: map + body: 'Please take a look at this POI' + useMailto: false + + sidepane: + digitizer: + title: Digitizer + class: Mapbender\DigitizerBundle\Element\Digitizer + target: map + schemes: + # combine_schemes_together: + # label: combine schemes (in this case poi and line) + # searchType: currentExtent # Initial state of checkbox for limiting feature loading to current visible map portion. [all / currentExtent] (default: currentExtent). + # combine: + # - poi + # - line + # # roles: #Show this schema only to users with (at least one of) these roles + # # - root + # # - ROLE_GROUP_EDITING + + poi: + label: 'point digitizing' + maxResults: 500 # only load limited number of feature + zoomBuffer: 100 + #filterUser: true + #trackUser: true + #featureType: poi # you can define a featureType in your parameters.yaml and refer to the name in the configuration + featureType: + connection: geodata_db + table: poi + uniqueId: gid + geomType: point + geomField: geom + srid: 4326 + filter: ~ + #filter: gid < 10000' + #filter: 'user_name = :userName' # use trackUser instead + #userColumn: user_name + styleField: style + #events: + # onBeforeSave: $feature->setAttribute('abstract', 'MAPS'); $feature->setAttribute('user_name', $user ); $feature->setAttribute('group_name', implode(',', $userRoles)); + allowCustomStyle: true + allowChangeVisibility: true # Offer buttons to toggle feature visibility (default true) + allowCreate: true # Allow new feature generation (default true) + allowDelete: true # Allow geometry deletion (default true) + allowDigitize: true # Allow geometry creation and editing (default true) + allowEditData: true # Allow attribute editing (default true) + allowRefresh: true # Offer button to reload data (for tables frequently modified by concurrent users) (default false) + + continueDrawingAfterSave: true # Keep drawing tool active after creating and saving a new feature (~fast batch mode feature creation) (default false) + + displayPermanent: true # Keep features visible on map even after switching to a different schema (default false) + displayOnInactive: true # Keep features visible on map even after deactivating Digitizer (default false) + + refreshLayersAfterFeatureSave: + - mapbender_users # or WMS InstanceID + + # Table + inlineSearch: true # Enables display filtering by search term (default true) + searchType: currentExtent # Initial state of checkbox for limiting feature loading to current visible map portion. [all / currentExtent] (default: currentExtent). + paging: true # De/activate paging in table (default true) + pageLength: 5 # Limits the number of rows per page in table (default 16) + + printable: true + # roles: #Show this schema only to users with (at least one of) these roles + # - root + # - ROLE_GROUP_EDITING + + copy: + enable: true + overwriteValuesWithDefault: true + data: + firstname: 'Paul' # every copied feature will get firstname Paul + lastname: 'Meier' # every copied feature will get lastname Meier + + toolset: + - + type: drawPoint + - + type: moveFeature + - + type: selectFeature + + + popup: + title: 'point test suite' # Popup title text + width: 500px + #width: 50vw # half screen width + #modal: true # Everything except the form window is grayed out and the position and size of the window is fixed for the duration of the data collection. + #position: {at: "left+200px", my: "left top-460px"} # Position of the popup in the browser area + styles: + default: + strokeWidth: 3 + strokeColor: "#00ff00" + fillColor: ${fill_color} + fillOpacity: 0.9 + strokeOpacity: 0.8 + pointRadius: 10 + label: ${name} + fontColor: black + fontSize: 12 + fontFamily: 'Arial, Courier New, monospace' + fontWeight: bold + labelOutlineColor: yellow + labelOutlineWidth: 1 + labelYOffset: -18 + labelXOffset: -18 + graphic: true + externalGraphic: 'https://schulung.foss.academy/symbols/${symbol}.png' + graphicWidth: 30 + graphicHeight: 30 + select: + strokeWidth: 3 + strokeColor: "#00ffff" + fillColor: "#FF00ff" + fillOpacity: 0.5 + pointRadius: 6 + label: ${gid} + fontColor: green + fontSize: 18 + labelOutlineColor: blue + labelOutlineWidth: 2 + labelYOffset: 18 + labelXOffset: -18 + unsaved: + strokeWidth: 3 + strokeColor: "#f0f0f0" + fillColor: "#ffffff" + fillOpacity: 0.5 + pointRadius: 6 + label: 'Please save' + fontColor: red + fontSize: 18 + labelOutlineColor: #ff00ff + labelOutlineWidth: 3 + labelYOffset: -18 + labelXOffset: 18 + + tableFields: + gid: + label: Nr. + width: 20% + name: + label: Name + width: 80% + + formItems: + - + type: tabs + children: + - + title: '1. Basic information' + css: + padding: 10px + children: + - + type: label + title: 'Welcome to the digitize demo. Try the new Mapbender feature!' + #css: + # color: red + - + type: html + html: 'Read more at the Mapbender-Website
' + # - + # type: div + # text: dies ist ein div + # - + # type: span + # text: dies ist ein span + + # - + # type: p + # text: dies ist ein p + - + type: text + title: user_name + text: data.user_name + - + type: input # Type of form input field + title: Name # Label text for form input field + name: name + #value: 'A place to be' # Initial field value on newly created items + + copyClipboard: true + infoText: 'Info: Please give a name to the new object.' # Explanatory text placed in a tooltip next to the label + mandatoryText: 'Mandatory Field: Please give a name to the poi.' + required: true + #mandatory: true #DEPRECATED please use required: true instead + css: + color: green + #cssClass: myClass # Added to the class attribute of the form group (container around label and input) + attr: + placeholder: 'Please give a name to the poi.' # placeholder. Text is not saved + #pattern: '\w{2}\d{3,}' # Two letters followed by at least three digits + - + type: input + title: Title + reuqired: false + name: title + + - + type: textArea + name: abstract + title: Abstract + mandatoryText: 'This field is mandatory' + required: true + attr: + placeholder: 'Please write an abstract' + rows: 3 + + # - type: text + # title: Show text from textarea with line wrap + # text: | + # data.abstract + # css: + # color: green + - + type: select + select2: true # activates full text search for the select box (please not for multi: true full text search is activated by default) + title: Type + name: type + infoText: 'Help: Please choose a type.' + mandatoryText: 'Please give a name to the new object.' + required: true + maximumSelectionLength: 2 # maximum number of possible selections for multi-select + attr: + multiple: true + # options: + # '': 'Please select a type...' + # 'A': 'Type A' + # 'B': 'Type B' + # 'C': 'Type C' + # 'D': 'Type D' + options: + - label: 'Please select a type...' + value: '' + # - label: 'Type A' + # value: 'A' + # - label: 'Type B' + # value: 'B' + # - label: 'Type C' + # value: 'C' + # - label: 'Type D' + # value: 'D' + #- label: 'Type E (disabled)' + # value: 'E' + # attr: + # disabled: disabled + #value: A,C # use comma-separated values for default multi-select value + connection: geodata_db + sql: SELECT type_name, type_id FROM types ORDER BY type_id ASC; + - + type: breakLine + + - type: text # type to generate dynamic text + title: 'Mapbender user/group' # label (optional) + #text: | + # data.name #+ ' ' + data.firstname + ' ' + data.lastname + ' Email:' + data.email + #text: "'user: ' + data.user_name + ' group:' + data.group_name" + text: | + 'user: ' + data.user_name + ' group:' + data.group_name + #- type: text # Typ text zur Generierung von dynamischen Texten aus der Datenbank + # title: 'Text with function type:text' # Beschriftung (optional) + # text: | + # (function(){ var result = ''; + # if(data.user_name){ + # result += 'user: ' + data.user_name; + # }else{ + # result += 'user: -' ; + # } + # if(data.user_group){ + # result += ' group: ' + data.group_name; + # }else{ + # result += ' group: -' ; + # } + # return result;})() + + - type: radioGroup + title: Radiobuttons - Choose one + name: category # column + options: + - label: Category 1 + value: c1 + - label: Category 2 + value: c2 + - label: Category 3 + value: c3 + value: c2 # Pre-select option by default for new items, if not set first option is pre-selected + + - + title: '2. Personal information' + css: + padding: 10px + children: + - + type: label + title: 'Please give us some information about yourself.' + - + type: fieldSet + children: + - + type: input + title: Firstname + name: firstname + css: + width: 30% + #focus: | + # var inputField = el; + # var form1 = inputField.closest(".data-manager-edit-data"); + # form1.css("background-color","#ffc0c0"); + #blur: | + # var inputField = el; + # var form = inputField.closest(".modal-body"); + # form.css("background-color","transparent"); - + - + type: input + title: Lastname + name: lastname + # mandatory: '/^[0-9]+$/' + # mandatoryText: 'Only numbers' + # required: false + css: + width: 30% + - + type: input + title: E-Mail + name: email + css: + width: 40% + - + type: select + multiple: false + title: Interests + name: interests + options: + maps: maps + reading: reading + swimming: swimming + dancing: dancing + beer: beer + flowers: flowers + - + type: fieldSet + children: + - + type: date + title: 'favorite Date' + name: date_favorite + # not supported to predefine a value: 2024-04-01 + attr: + min: '2020-01-01' + max: '2030-01-01' + css: + width: 25% + # Highlight the year column when you edit the date-field + # and automatically insert the year from the date + change: | + var inputField = el; + var form = inputField.closest(".data-manager-edit-data"); + var yearField = form.find("[name='year']"); + var value = inputField.val() + var year = value && value.match(/^\d{4}/)[0] || null; + yearField.val(year); + yearField.css("background-color","#ffc0c0"); + + - + type: input + title: Year + name: year + css: + width: 25% + + - + type: colorPicker + title: 'Fill Color - used for default style' + name: fill_color + value: "#ff00ff" + + - + type: breakLine + + - + type: fieldSet + children: + - + type: checkbox + title: 'public (this new object is public)' + name: public + value: true + # required: true makes no sense as checkbox can not be set false then + #required: false + css: + width: 50% + - + type: text + text: | + 'Status checkbox: ' + data.public + css: + width: 50% + + - + type: file + name: file_reference + title: 'upload a file' # Label + text: File upload # button labeling + attr: + accept: 'image/png' + - type: image + name: file_reference # Link to input established by matching "name" value + #src: './uploads/mapbender_user/screenshot.png' # path to placeholder image + enlargeImage: true + imageCss: + width: 200px + + + line: + label: 'line digitizing' + maxResults: 1500 + featureType: + connection: geodata_db + table: lines + uniqueId: gid + geomType: line + geomField: geom + srid: 4326 + filter: "st_isempty(geom) = false + AND st_intersects(geom,st_geomfromtext('POLYGON((7.078768115095284 50.718742549359874,7.108512203024121 50.71922903890011,7.10792188122481 50.733883032109,7.078168524167035 50.733396290239824,7.078768115095284 50.718742549359874))',4326))" + styleField: style + # file upload location - customization per column on featureType (or dataStore) level + #files: + # - field: file_reference + # path: /data/demo/mapbender_upload_lines/ + allowDigitize: true # Allow geometry creation and editing (default true) + allowEditData: true # Allow attribute editing (default true) + allowDelete: true # Allow geometry deletion (default true) + allowCustomStyle: true # only for geomType line and multi-/polygon needs styleField definition in featureType section + toolset: + - + type: drawLine + - + type: modifyFeature + - + type: moveFeature + + popup: + title: 'line test suite' + width: 500px + searchType: currentExtent + styles: + default: + strokeWidth: 2 + strokeColor: "#0000ff" + strokeOpacity: 0.6 + label: ${name} + fontColor: "#0000ff" + fontSize: 18 + fontFamily: 'Arial, Courier New, monospace' + fontWeight: bold + labelOutlineColor: white + labelOutlineWidth: 1 + labelYOffset: -18 + labelXOffset: -18 + select: + strokeWidth: 5 + strokeOpacity: 0.5 + strokeColor: "#b000b0" + label: ${gid} + fontColor: blue + fontSize: 18 + unsaved: + strokeWidth: 5 + strokeColor: "#ff0000" + label: 'Neu - bitte speichern' + fontColor: red + fontSize: 18 + tableFields: + gid: + label: Nr. + width: 20% + name: + label: Name + width: 80% + formItems: + - type: p + text: This is an introductory paragraph. + # Arrange inputs in Bootstrap grid row + columns + - type: div + cssClass: row + css: + padding: 10px + children: + - type: input + title: Input in left column + name: firstname + attr: + placeholder: Please add first name + cssClass: col-xs-4 col-4 + - type: input + title: Input in middle column + name: lastname + cssClass: col-xs-4 col-4 + - type: input + name: email + title: Input in right column + cssClass: col-xs-4 col-4 + - + type: tabs + children: + - title: 'Tab 1' + children: + - + type: label + title: 'Welcome to the digitize demo. Try the new Mapbender feature!' + - title: 'Tab 2' + children: + - + type: label + title: 'Welcome to the digitize demo. Try the new Mapbender feature!' + - + type: input + title: Name + name: name + mandatory: true + mandatoryText: 'Please give a name to the new object.' + infoText: 'Help: Please give a name to the new object.' + - + type: select + title: Type + name: type + infoText: 'Help: Please choose a type...' + required: true + options: + - label: 'Please select a type...' + value: '' + - label: 'Type A' + value: 'A' + - label: 'Type B' + value: 'B' + - label: 'Type C' + value: 'C' + - label: 'Type D' + value: 'D' + - label: 'Type E' + value: 'E' + - title: 'Tab 3' + children: + - + type: file + name: file_reference + title: 'upload a file' + attr: + accept: 'image/*' + - type: image + name: file_reference # Link to input established by matching "name" value + src: ./uploads/mapbender_user/screenshot.png # path to placeholder image + + polygon: + label: 'polygon digitizing' + maxResults: 1500 + featureType: + connection: geodata_db + table: polygons + uniqueId: gid + geomType: polygon + geomField: geom + srid: 4326 + styleField: style + allowDelete: true + allowCustomStyle: true # needs styleField definition in featureType section + allowCancelButton: true + allowDeleteByCancelNewGeometry: false + toolset: + - + type: drawPolygon + - + type: drawRectangle + - + type: drawDonut + - + type: drawEllipse + - + type: drawCircle + - + type: modifyFeature + - + type: moveFeature + + popup: + title: 'polygon test suite' + width: 500px + searchType: currentExtent + pageLength: 10 + tableFields: + gid: + label: Nr. + width: 20% + name: + label: Name + width: 80% + styles: + default: + strokeWidth: 2 + strokeColor: "#0000ff" + strokeOpacity: 0.6 + label: ${name} + fontColor: "#0000ff" + fontSize: 18 + fontFamily: 'Arial, Courier New, monospace' + fontWeight: bold + labelOutlineColor: white + labelOutlineWidth: 1 + labelYOffset: -18 + labelXOffset: -18 + select: + strokeWidth: 5 + strokeOpacity: 0.5 + strokeColor: "#b000b0" + label: ${gid} + fontColor: blue + fontSize: 18 + unsaved: + strokeWidth: 5 + strokeColor: "#ff0000" + label: 'Neu - bitte speichern' + fontColor: red + fontSize: 18 + formItems: + - + type: label + title: 'Welcome to the digitize demo. Try the new Mapbender feature!' + - + type: input + title: Name + mandatory: true + name: name + mandatoryText: 'Please give a name to the new object.' + infoText: 'Help: Please give a name to the new object.' + - + type: select + title: Type + name: type + infoText: 'Help: Please give a type to the new object.' + required: true + options: + - label: 'Please select a type...' + value: '' + connection: geodata_db + sql: "Select chr(a) || '-Type' as value , chr(a) as key FROM generate_series(65,70) as a order by a;" + + + layertree: + title: mb.core.layertree.class.title + class: Mapbender\CoreBundle\Element\Layertree + target: map + type: element + autoOpen: false + showBaseSource: true + layerRemove: true + menu: [opacity,zoomtolayer,metadata] + sketch: + class: Mapbender\CoreBundle\Element\Sketch + target: map + auto_activate: false + + searchrouter: + target: map + timeoutFactor: 3 + width: 700 + height: 500 + asDialog: false + class: Mapbender\CoreBundle\Element\SearchRouter + routes: + 1-route: + title: Places + class: Mapbender\CoreBundle\Component\SQLSearchEngine + class_options: + connection: geodata_db + relation: brd.qry_gn250_p_ortslage + attributes: + - gid + - name + - gemeinde + - hoehe_ger + geometry_attribute: geom + form: + name: + type: text + options: + required: false + label: Name + attr: + data-autocomplete: 'on' + compare: ilike + gemeinde: + type: text + options: + label: 'Commune' + required: false + compare: ilike + results: + view: table + count: true + headers: + name: Name + gemeinde: Commune + hoehe_ger: Height + callback: + event: click + options: + buffer: 1000 + minScale: null + maxScale: null + styleMap: + default: + strokeColor: '#8000FF' + strokeWidth: 1 + strokeOpacity: 1 + fillColor: '#8000FF' + fillOpacity: 0.8 + fillWidth: 6 + select: + strokeColor: '#ff00ff' + strokeWidth: 2 + strokeOpacity: 1 + fillColor: '#ff00ff' + fillOpacity: 0.6 + fillWidth: 12 + temporary: + strokeColor: '#00FFFF' + strokeOpacity: 1 + strokeWidth: 2 + fillColor: '#00FFFF' + fillWidth: 6 + fillOpacity: 0.6 + + footer: + imprintButton: + title: Imprint & Contact + tooltip: Imprint & Contact + class: Mapbender\CoreBundle\Element\Button + label: true + click: https://mapbender.org/en/contact/ + + privacyButton: + title: Privacy-Policy + tooltip: Privacy-Policy + class: Mapbender\CoreBundle\Element\Button + label: true + click: http://mapbender.org/en/privacy-policy + + activityindicator: + class: Mapbender\CoreBundle\Element\ActivityIndicator + title: mb.core.activityindicator.class.title + activityClass: mb-activity + ajaxActivityClass: mb-activity-ajax + tileActivityClass: mb-activity-tile + + coordinates: + class: Mapbender\CoreBundle\Element\CoordinatesDisplay + title: mb.core.coordinates.class.title + target: map + label: false + empty: "x: - y: -" + prefix: "x: " + separator: " y: " + + srs: + class: Mapbender\CoreBundle\Element\SrsSelector + title: mb.core.srsselector.class.title + tooltip: mb.core.srsselector.class.description + label: false + target: map + + scaleselector: + class: Mapbender\CoreBundle\Element\ScaleSelector + title: mb.core.scaleselector.class.title + tooltip: mb.core.scaleselector.class.description + label: false + target: map + applicationswitcher: + class: Mapbender\CoreBundle\Element\ApplicationSwitcher + applications: [mapbender_user, mapbender_user_basic] + copyrightButton: + title: © OpenStreetMap contributors + tooltip: © OpenStreetMap contributors + class: Mapbender\CoreBundle\Element\Button + label: true + click: https://www.openstreetmap.org/copyright + + HTML: + title: HTML-powered by Mapbender + class: Mapbender\CoreBundle\Element\HTMLElement + content: 'powered by Mapbender' + classes: html-element-inline diff --git a/application/config/bundles.php b/application/config/bundles.php index 3d3116be3..940ef3ad6 100644 --- a/application/config/bundles.php +++ b/application/config/bundles.php @@ -24,4 +24,5 @@ Mapbender\DataSourceBundle\MapbenderDataSourceBundle::class => ['all' => true], Mapbender\DataManagerBundle\MapbenderDataManagerBundle::class => ['all' => true], DAMA\DoctrineTestBundle\DAMADoctrineTestBundle::class => ['test' => true], + Lexik\Bundle\JWTAuthenticationBundle\LexikJWTAuthenticationBundle::class => ['all' => true], ]; diff --git a/application/config/packages/doctrine.yaml b/application/config/packages/doctrine.yaml index 0f014d65c..37e03b8ba 100644 --- a/application/config/packages/doctrine.yaml +++ b/application/config/packages/doctrine.yaml @@ -8,13 +8,6 @@ doctrine: # either here or in the DATABASE_URL env var (see .env file) # server_version: '16' - persistent: true - charset: UTF8 - logging: '%kernel.debug%' - profiling: '%kernel.debug%' - profiling_collect_backtrace: '%kernel.debug%' - use_savepoints: true - # add other connections here orm: auto_generate_proxy_classes: '%kernel.debug%' diff --git a/application/config/packages/lexik_jwt_authentication.yaml b/application/config/packages/lexik_jwt_authentication.yaml new file mode 100644 index 000000000..edfb69dc8 --- /dev/null +++ b/application/config/packages/lexik_jwt_authentication.yaml @@ -0,0 +1,4 @@ +lexik_jwt_authentication: + secret_key: '%env(resolve:JWT_SECRET_KEY)%' + public_key: '%env(resolve:JWT_PUBLIC_KEY)%' + pass_phrase: '%env(JWT_PASSPHRASE)%' diff --git a/application/config/packages/security.yaml b/application/config/packages/security.yaml index ee6a64023..e42342072 100644 --- a/application/config/packages/security.yaml +++ b/application/config/packages/security.yaml @@ -15,6 +15,20 @@ security: login: pattern: ^/user/login$ security: false + + jwt_login: + pattern: ^/api/login_check + stateless: true + json_login: + check_path: /api/login_check # or api_login_check as defined in config/routes.yaml + success_handler: lexik_jwt_authentication.handler.authentication_success + failure_handler: lexik_jwt_authentication.handler.authentication_failure + + api: + pattern: ^/api + stateless: true + jwt: ~ + secured_area: pattern: ^/ form_login: @@ -36,6 +50,8 @@ security: access_control: - { path: ^/user/login, roles: PUBLIC_ACCESS } - { path: ^/manager, roles: ROLE_USER } + - { path: ^/api/login_check, roles: PUBLIC_ACCESS } + - { path: ^/api, roles: IS_AUTHENTICATED_FULLY } password_hashers: FOM\UserBundle\Entity\User: sha512 diff --git a/application/config/routes/attributes.yaml b/application/config/routes/attributes.yaml index 129d8dc38..c6c79a0e2 100644 --- a/application/config/routes/attributes.yaml +++ b/application/config/routes/attributes.yaml @@ -22,3 +22,8 @@ ows_corebundle: namespace: \OwsProxy3\CoreBundle\Controller prefix: "/owsproxy" type: attribute + + +api_login_check: + path: /api/login_check + methods: [POST] diff --git a/application/symfony.lock b/application/symfony.lock index d037220b9..5a60e59fb 100644 --- a/application/symfony.lock +++ b/application/symfony.lock @@ -25,6 +25,18 @@ "src/Repository/.gitignore" ] }, + "lexik/jwt-authentication-bundle": { + "version": "2.21", + "recipe": { + "repo": "github.com/symfony/recipes", + "branch": "main", + "version": "2.5", + "ref": "e9481b233a11ef7e15fe055a2b21fd3ac1aa2bb7" + }, + "files": [ + "config/packages/lexik_jwt_authentication.yaml" + ] + }, "mapbender/digitizer": { "version": "dev-develop" }, diff --git a/bootstrap b/bootstrap index 1a7345765..bcdd47e67 100755 --- a/bootstrap +++ b/bootstrap @@ -5,6 +5,8 @@ php bin/composer install -o --no-scripts --no-suggest php bin/composer init-example php bin/console assets:install --symlink --relative php bin/console mapbender:database:init -v +php bin/console lexik:jwt:generate-keypair +sed -i "s/^JWT_PASSPHRASE=/JWT_PASSPHRASE=$(openssl rand -base64 32)/" application/.env php bin/composer run post-install-cmd echo Bootstrap finished! echo If you want to run the builtin development server, install Symfony CLI from https://symfony.com/download then run: