* Update Swashbuckle to v10
* Regenerate backoffice api client
* Add missing space for consistency
* Simplify nullability check
* Small improvement
Didn't notice that these classes were internal, so tried keeping compatibility, but it wasn't needed.
* Fix failing integration test
* Apply suggestions from code review
Co-authored-by: Andy Butland <abutland73@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Remove unnecessary comma
---------
Co-authored-by: Andy Butland <abutland73@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Redact back-office PKCE codes from the server
* Update src/Umbraco.Cms.Api.Common/DependencyInjection/HideBackOfficeTokensHandler.cs
---------
Co-authored-by: Andy Butland <abutland73@gmail.com>
* Move access/refresh tokens to secure cookies (#20779)
* feat: adds the `credentials: include` header to all manual requests
* feat: adds `credentials: include` as a configurable option to xhr requests (and sets it by default to true)
* feat: configures the auto-generated fetch client from hey-api to include credentials by default
* Add OpenIddict handler to hide tokens from the back-office client
* Make back-office token redaction optional (default false)
* Clear back-office token cookies on logout
* Add configuration for backoffice cookie settings
* Make cookies forcefully secure + move cookie handler enabling to the BackOfficeTokenCookieSettings
* Use the "__Host-" prefix for cookie names
* docs: adds documentation on cookie settings
* build: sets up launch profile for vscode with new cookie recommended settings
* docs: adds extra note around SameSite settings
* docs: adds extra note around SameSite settings
* Respect sites that do not use HTTPS
* Explicitly invalidate potentially valid, old refresh tokens that should no longer be used
* Removed obsolete const
---------
Co-authored-by: Jacob Overgaard <752371+iOvergaard@users.noreply.github.com>
* Remove configuration option
* Invalidate all existing access tokens on upgrade
* docs: updates recommended settings for development
* build: removes non-existing variable
* Skip flaky test
* Bumped version of our test helpers to fix failing tests
---------
Co-authored-by: Jacob Overgaard <752371+iOvergaard@users.noreply.github.com>
Co-authored-by: Andreas Zerbst <andr317c@live.dk>
* Start work
* Introduce dto
* Start making repository
* Add migrations
* Implement fetchable first job
* Fix up to also finish tasks
* Refactor jobs to distributed background jobs
* Filter jobs correctly on LastRun
* Hardcode delay
* Add settings to configure delay and period
* Fix formatting
* Add default data
* Add update on startup, which will update periods on startup
* Refactor service to return job directly
* Update src/Umbraco.Infrastructure/Services/Implement/DistributedJobService.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Update src/Umbraco.Infrastructure/BackgroundJobs/DistributedBackgroundJobHostedService.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Update src/Umbraco.Infrastructure/Migrations/Install/DatabaseDataCreator.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Update src/Umbraco.Infrastructure/Migrations/Install/DatabaseDataCreator.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Update src/Umbraco.Infrastructure/BackgroundJobs/DistributedBackgroundJobHostedService.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Remove unused
* Move jobs and make internal
* make OpenIddictCleanupJob.cs public, as it is used elsewhere
* Minor docstring changes
* Update src/Umbraco.Core/Persistence/Constants-Locks.cs
Co-authored-by: Mole <nikolajlauridsen@protonmail.ch>
* ´Throw correct exceptions
* Update xml doc
* Remove business logic from repository
* Remove more business logic from repository into service
* Remove adding jobs from migration
* fix creation
* Rename to ExecuteAsync
---------
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: mole <nikolajlauridsen@protonmail.ch>
* Bump Azure.Identity from 1.13.2 to 1.16.0
* Bump BenchmarkDotNet from 0.14.0 to 0.15.4
* Bump Bogus from 35.6.3 to 35.6.4
* Bump HtmlAgilityPack from 1.12.1 to 1.12.4
* Bump MailKit from 4.11.0 to 4.14.0
* Bump MessagePack from 3.1.3 to 3.1.4
* Bump Microsoft.AspNetCore.Mvc.Testing from 9.0.4 to 9.0.9
* Bump Microsoft.Data.SqlClient from 6.0.1 to 6.1.1
* Bump Microsoft.Extensions.Caching.Hybrid from 9.8.0 to 9.9.0
* Bump Microsoft.Extensions.Logging.Debug from 9.0.4 to 9.0.9
* Bump Microsoft.NET.Test.Sdk from 17.13.0 to 18.0.0
* Bump ncrontab from 3.3.3 to 3.4.0
* Bump Nerdbank.GitVersioning from 3.7.115 to 3.8.118
* Bump OpenIddict packages from 6.2.1 to 7.1.0
* Bump Serilog from 4.2.0 to 4.3.0
* Bump Serilog.Sinks.File from 6.0.0 to 7.0.0
* Bump Swashbuckle.AspNetCore from 8.1.1 to 9.0.6
* Bump System.Data.Odbc from 9.0.4 to 9.0.9
* Bump System.Data.OleDb from 9.0.4 to 9.0.9
* Bump Microsoft.IdentityModel.JsonWebTokens from 8.8.0 to 8.14.0
* Bump SixLabors.ImageSharp.Web from 3.1.5 to 3.2.0
- Implicit global usings were made opt-in (https://github.com/SixLabors/ImageSharp.Web/pull/391)
* Bump NJsonSchema from 11.0.2 to 11.5.1
* Bump Microsoft packages from 10.0.0-preview.7.25380.108 to 10.0.0-rc.1.25451.107
* Remove Azure.Identity package reference as implicitly referenced versions are no longer vulnerable
* Remove System.Runtime.Caching package reference as it is not used
* Remove System.Net.Http package reference as it is not used
* Set 'allowPrerelease' to true
Global.json was showing as invalid due to a pre-release version being referenced while 'allowPrerelease' was set to 'false'. This can be set to 'false' again later on.
* Remove System.Security.Cryptography.Xml package reference as implicitly referenced versions are no longer vulnerable
* Remove System.Text.RegularExpressions package reference as implicitly referenced versions are no longer vulnerable
* Remove Microsoft.IdentityModel.JsonWebTokens package reference as implicitly referenced versions are no longer vulnerable
* Remove System.Text.Encodings.Web package reference as it is not used
* Remove Microsoft.Data.SqlClient package reference as implicitly referenced versions are no longer vulnerable
* Remove Lucene.Net.Replicator package reference as implicitly referenced versions are no longer vulnerable
* Remove Microsoft.Extensions.Caching.Memory package reference where not used
* Add EFCore migration for OpenIddict v7 update
* Apply suggestion from @kjac
Cosmetic update: Removed blank line as suggested by Copilot
---------
Co-authored-by: Kenn Jacobsen <kja@umbraco.dk>
* Use EndpointMetadata to check for existing MapToApiAttribute at runtime
* fix api breaking change
* revert MethodInfoApiCommonExtensions.cs
* remove empty line in ActionDescriptorApiCommonExtensions.cs
* Add xml comments to ActionDescriptorApiCommonExtensions
* Revert boy scout refactoring to primary constructur
* Better xml comments in ActionDescriptorApiCommonExtensions
---------
Co-authored-by: Marcus Wilhelmson <marcus.wilhelmson@consid.se>
* Added user start node restrictions to sibling endpoints.
* Further integration tests.
* Tidy up.
* Apply suggestions from code review
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Revert previous update.
* Retrieves item counts before and after the target for sibling endpoints and returns in API response.
* Applied previous update correctly.
* Removed blank line.
* Fix build and test asserts following merge.
* Update OpenApi.json.
---------
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: mole <nikolajlauridsen@protonmail.ch>
* Fix nullability of Children extension
* Fix nullability of methods throughout the CMS
* Fix return types of some methods that cannot return null
* Revert nullable changes to result of ConvertSourceToIntermediate for property editors (whilst some property editors we know won't return null, it seems more consistent to adhere to the base class and interface nullability definition).
* Updated new webhook events to align with new nullability definitions.
* Reverted content editing service updates to align with base classes.
* Applied collection nullability updates on content repository to interface.
* Reverted value converter updates to match interface.
* Applied further collection updates to interface.
* Aligned media service interface with implementation for nullability.
* Update from code review.
---------
Co-authored-by: Ivo van der Bruggen <ivo@dutchbreeze.com>
Co-authored-by: Ivo van der Bruggen <ivo@vdbruggensoftware.com>
Co-authored-by: Andy Butland <abutland73@gmail.com>
* feat: conditionally install and build the 'login' and 'backoffice' targets depending on source files
* feat: remove the preconditions target, because we are now compiling a file list to check if we need to build
* feat: remove the 'clean' targets, because the project will be cleaned if any of the compiled file lists do not exist
* feat: remove the preserve.* files as they are no longer needed
* Enable default content items again
* Remove package.json from restore target inputs
* Include generated files as static assets after build
* Clean up project files
* Exclude CS0618 warning as error and fix CA2264
* Exclude CS0612 warning as error
* Suppress removal of test fixture
* Use separate property/item groups for backoffice and login project
---------
Co-authored-by: Ronald Barendse <ronald@barend.se>
* Updated to .NET9 RC2 and a few other nuget packages. Most notable is OpenIddict v6 preview that supports .net 9
* Revert "temp remove tag helpers (#16977)"
This reverts commit 84cc3051ad.
* Treat warnings as errors for Umbraco.Cms, Umbraco.Cms.Api.Common and Umbraco.Cms.Api.Delivery projects.
* Treat warnings as errors for Umbraco.Cms.Imaging.ImageSharp and Umbraco.Cms.Imaging.ImageSharp2 projects
* Treat warnings as errors for Umbraco.Cms.Persistence.EFCore.Sqlite, Umbraco.Cms.Persistence.EFCore.SqlServer and Umbraco.Cms.StaticAssets
* Treat warnings as errors for Umbraco.Cms.Targets
* Treat warnings as errors for templates/Umbraco.Templates and Umbraco.JsonSchema
* More projects with warnings as errors.
* Reverted warnings as errors due to some file changes since the update.
* Remove unwanted tag
* Removed warnings as errors on TestData project
* Implement warnings as errors in props file, and exclude specific warnings where appropriate as per PR review suggestions.
* Reverted spaces
* Revert "Reverted spaces"
This reverts commit 3734c45e2270c3324768b33e459aefcc6a8c4739.
* Update sdk version to fully support Umbraco.code 2.2.0 dependency on Microsoft.CodeAnalysis.CSharp.Workspaces 4.10.0
* Ignore PathToLongErrors for now in static assets
---------
Co-authored-by: Emma Garland <emma.garland@rocksolidknowledge.com>
Co-authored-by: Sven Geusens <sge@umbraco.dk>
* First stab
* Delivery API client credentials + a little refactor to ensure unique client IDs
* Introduce user type
* Support user type in the Management API
* Clean up TODOs
* Update API user last login date when issuing a token
* Better error reporting for mismatched user types
* Do not allow password change or reset for API users
* Update OpenApi.json
* Revert change
* Remove obsolete comment
* Make applicable classes abstract or sealed
* Review changes
* Add endpoint for retrieving all user client IDs
* Update to dotnet 9 and update nuget packages
* Update umbraco code version
* Update Directory.Build.props
Co-authored-by: Elitsa Marinovska <21998037+elit0451@users.noreply.github.com>
* Include preview version in pipeline
* update template projects
* update global json with specific version
* Update version.json to v15
* Rename TrimStart and TrimEnd to string specific
* Rename to Exact
* Update global.json
Co-authored-by: Ronald Barendse <ronald@barend.se>
* Remove includePreviewVersion
* Rename to trim exact
---------
Co-authored-by: Elitsa Marinovska <21998037+elit0451@users.noreply.github.com>
Co-authored-by: Ronald Barendse <ronald@barend.se>
* Update integration test base class to verify that calls to ServiceDescriptor.ImplementationType are guarded for keyed services
* Fix unguarded calls to ServiceDescriptor.ImplementationType for keyed services
* Consider max login lifetime with access and refresh tokens
* Adding clarification comment
* Updated comment and added a little explanation for future clarity
---------
Co-authored-by: kjac <kja@umbraco.dk>
* Adding ISchemaIdHandler and core implementation enabling custom package implementations
* Adding IOperationIdSelector and refactoring core implementation to enable custom package implementations
* Adding OperationIdSelector core implementation enabling custom package
* Removing old way of Operation id extensibility
* Registering schema and operation id handlers
* Refactoring based on unnecessary param
* Obsoletion
* Refactoring SchemaIdSelector to make use of the new ISchemaIdHandler
* Update OpenApi.json
* Revert "Update OpenApi.json"
This reverts commit c9165f174b814cddd869e69960fc504758f73ae5.
---------
Co-authored-by: kjac <kja@umbraco.dk>