Commit Graph

18 Commits

Author SHA1 Message Date
Elitsa
1bc5466a8d Update the HttpContext's user with the authenticated user's principal 2024-10-21 12:45:38 +02:00
Sebastiaan Janssen
db5d05d641 Revert files that shouldn't change back in v11 2022-09-19 16:37:24 +02:00
Sebastiaan Janssen
87c06f5f98 Back to 10.2.0-ish 2022-09-19 16:14:16 +02:00
Nikolaj Geisle
1b5225f4cd V11/feature/update to dotnet 7 (#12712)
* Update projects to .NET 7

* Fix nullability errors

* Fix up pipelines to run 7.0

* Update langversion to preview

* Revert "Fix up pipelines to run 7.0"

This reverts commit d0fa8d01b8126a4eaa59832a3814a567705419ae.

* Fix up pipelines again, this time without indentation changes

* Include preview versions

* Versions not Version

* Fix ModelTypeTests

* Fix MemberPasswordHasherTests

Microsoft wants to use SHA512 instead of SHA256, so our old hashes will return SuccessRehashNeeded now

* Use dotnet cli instead of nuget restore

* Update src/Umbraco.Web.UI/Umbraco.Web.UI.csproj

* Update dependencies

* Fix nullability issues

* Fix unit test

* Fix nullability in ChangingPasswordModel

OldPassword can be null, if we're changing the password with password reset enabled. Additionally, we might as well use the new required keyword instead of supressing null.

* Use required keyword instead of supressing null

* Fix up pipelines again

* fix up spelling-error

* Use dotnet cli instead of nuget restore

* Fix up another NuGet command

* Use dotnet version 7 before building

* Include preview versions

* Remove condition

* Use dotnet 7 before running powershell script

* Update templates to .net 7

* Download version 7 before running linux container

* Move use dotnet 7 even earlier in E2E process

* Remove dotnet 7

* Reintroduce .NET 7 task

* Update linux docker container and remove dotnet 7 from yml

* Fix up dockerfile with ARG

* Fix up docker file with nightly builds of dotnet 7

* Reintroduce dotnet 7 so windows can use it

* Use aspnet 7 in docker

Co-authored-by: Nikolaj <nikolajlauridsen@protonmail.ch>
Co-authored-by: Zeegaan <nge@umbraco.dk>
2022-08-23 11:31:05 +02:00
Bjarke Berg
faf06be618 Changes to Basic Auth to support external logins (#12434)
* Fixed issues with basic auth middleware to support Umbraco Cloud usecase

* Fix redirects to return url, now allows website urls

* Strip potential domain part of returnPath

* Fix default value in appsettings schema

* Reintroduce check of basic auth enabled.

* Fix wrong negation introduced in #12349

* Fixed issues with redirects

* Also check external login cookie, while authenticating backoffice
2022-06-02 12:19:22 +02:00
Nikolaj Geisle
c576bbea03 v10: Fix build warnings in Web.Common (#12349)
* Run code cleanup

* Run dotnet format

* Start manual cleanup in Web.Common

* Finish up manual cleanup

* Fix tests

* Fix up InMemoryModelFactory.cs

* Inject proper macroRenderer

* Update src/Umbraco.Web.Common/Filters/JsonDateTimeFormatAttribute.cs

Co-authored-by: Mole <nikolajlauridsen@protonmail.ch>

* Update src/Umbraco.Web.Common/Filters/ValidateUmbracoFormRouteStringAttribute.cs

Co-authored-by: Mole <nikolajlauridsen@protonmail.ch>

* Fix based on review

Co-authored-by: Nikolaj Geisle <niko737@edu.ucl.dk>
Co-authored-by: Mole <nikolajlauridsen@protonmail.ch>
2022-05-09 09:39:46 +02:00
Nikolaj Geisle
4571ecb0e3 More work on nullable reference types 2022-03-31 14:35:23 +02:00
Nikolaj Geisle
b52c4e50cf Add nullability to web.common 2022-03-29 13:44:21 +02:00
Andy Butland
9732381933 Added unit test for TryGetBasicAuthCredentials extension method and minor code tidy. 2021-08-06 12:13:16 +02:00
Bjarke Berg
bbd935a0b8 Updates based on review feedback 2021-08-06 11:26:31 +02:00
Bjarke Berg
4f2cb09939 Added POC of basic auth middleware 2021-08-05 21:42:47 +02:00
Shannon
1ef60a7c7d removes unneeded ctor dependency on UmbracoContext 2021-03-04 16:44:09 +11:00
Mole
d413bf49f9 Merge remote-tracking branch 'origin/netcore/dev' into 9622-remove-backofficeidentity
# Conflicts:
#	src/Umbraco.Core/Security/AuthenticationExtensions.cs
#	src/Umbraco.Core/Security/UmbracoBackOfficeIdentity.cs
#	src/Umbraco.Infrastructure/Security/BackOfficeClaimsPrincipalFactory.cs
#	src/Umbraco.Tests.UnitTests/Umbraco.Core/BackOffice/UmbracoBackOfficeIdentityTests.cs
#	src/Umbraco.Tests.UnitTests/Umbraco.Core/Extensions/ClaimsPrincipalExtensionsTests.cs
#	src/Umbraco.Tests.UnitTests/Umbraco.Web.BackOffice/Security/BackOfficeAntiforgeryTests.cs
#	src/Umbraco.Tests/TestHelpers/ControllerTesting/AuthenticateEverythingMiddleware.cs
#	src/Umbraco.Web.BackOffice/Security/BackOfficeSecureDataFormat.cs
#	src/Umbraco.Web.BackOffice/Security/ConfigureBackOfficeCookieOptions.cs
#	src/Umbraco.Web.Common/Security/BackOfficeUserManager.cs
2021-02-22 08:38:12 +01:00
Mole
bf41c2eeaa Netcore: Align namespaces (#9801)
* Rename Umbraco.Core namespace to Umbraco.Cms.Core

* Move extension methods in core project to Umbraco.Extensions

* Move extension methods in core project to Umbraco.Extensions

* Rename Umbraco.Examine namespace to Umbraco.Cms.Examine

* Move examine extensions to Umbraco.Extensions namespace

* Reflect changed namespaces in Builder and fix unit tests

* Adjust namespace in Umbraco.ModelsBuilder.Embedded

* Adjust namespace in Umbraco.Persistence.SqlCe

* Adjust namespace in Umbraco.PublishedCache.NuCache

* Align namespaces in Umbraco.Web.BackOffice

* Align namespaces in Umbraco.Web.Common

* Ensure that SqlCeSupport is still enabled after changing the namespace

* Align namespaces in Umbraco.Web.Website

* Align namespaces in Umbraco.Web.UI.NetCore

* Align namespaces in Umbraco.Tests.Common

* Align namespaces in Umbraco.Tests.UnitTests

* Align namespaces in Umbraco.Tests.Integration

* Fix errors caused by changed namespaces

* Fix integration tests

* Undo the Umbraco.Examine.Lucene namespace change

This breaks integration tests on linux, since the namespace wont exists there because it's only used on windows.

* Fix merge

* Fix Merge
2021-02-18 11:06:02 +01:00
Mole
33a99df73f Remove usage of FromClaimsIdentity 2021-02-17 11:50:19 +01:00
Shannon
de03dae46f Moving namespaces, cleaning up some stuff on the underlying base identity classes 2020-12-03 23:49:32 +11:00
Bjarke Berg
609c1ffc5b Migrated content controller + related
Signed-off-by: Bjarke Berg <mail@bergmania.dk>
2020-06-12 08:27:22 +02:00
Shannon
9dcad544a9 Implements more BackOfficeController and AuthenticationController, some web security and more, gets the back office UI almost rendering 2020-05-25 23:15:32 +10:00