oops, not sure how the LICENSE got deleted, removed AD identity nuspec since that is in a diff repo now. Removes commented out code in umb module for auth - this is done by cookie middleware now.

This commit is contained in:
Shannon
2015-04-01 13:55:33 +11:00
parent ad92006f54
commit f019900619
4 changed files with 9 additions and 66 deletions

9
LICENSE.md Normal file
View File

@@ -0,0 +1,9 @@
# The MIT License (MIT) #
Copyright (c) 2013 Umbraco
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

View File

@@ -1,26 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd">
<metadata minClientVersion="2.8">
<id>UmbracoCms.Identity.ActiveDirectory</id>
<version>1.0.0</version>
<title>Umbraco Extensibility for ASP.Net Identity Active Directory</title>
<authors>Umbraco HQ</authors>
<owners>Umbraco HQ</owners>
<licenseUrl>http://opensource.org/licenses/MIT</licenseUrl>
<projectUrl>http://umbraco.com/</projectUrl>
<iconUrl>http://umbraco.com/media/357769/100px_transparent.png</iconUrl>
<requireLicenseAcceptance>false</requireLicenseAcceptance>
<description>Installs files/classes to help with ASP.Net Identity Active Directory provider extensibility for Umbraco back office</description>
<summary>Installs classes to help with ASP.Net Identity Active Directory extensibility for Umbraco</summary>
<language>en-US</language>
<tags>umbraco aspnet identity activedirectory</tags>
<dependencies>
<dependency id="UmbracoCms" version="[7.3.0, 8.0.0)" />
<dependency id="Microsoft.Owin.Security.OpenIdConnect" version="3.0.1,4.0.0)" />
<dependency id="Microsoft.IdentityModel.Clients.ActiveDirectory" version="2.14.201151115,3.0.0)" />
</dependencies>
</metadata>
<files>
<file src="..\_BuildOutput\IdentityTemplates\App_Start\**\*.pp" target="content\App_Start" />
</files>
</package>

View File

@@ -166,43 +166,6 @@ namespace Umbraco.Web
RewriteToUmbracoHandler(httpContext, pcr); RewriteToUmbracoHandler(httpContext, pcr);
} }
/// <summary>
/// Authenticates the request by reading the FormsAuthentication cookie and setting the
/// context and thread principle object
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
/// <remarks>
/// We will set the identity, culture, etc... for any request that is:
/// * A back office request
/// * An installer request
/// * A /base request (since these can be back office web service requests)
/// </remarks>
static void AuthenticateRequest(object sender, EventArgs e)
{
//var app = (HttpApplication)sender;
//var http = new HttpContextWrapper(app.Context);
//// do not process if client-side request
//if (http.Request.Url.IsClientSideRequest())
// return;
//var req = new HttpRequestWrapper(app.Request);
//if (ShouldAuthenticateRequest(req, UmbracoContext.Current.OriginalRequestUrl))
//{
// //TODO: Here we should have an authentication mechanism, this mechanism should be smart in the way that the ASP.Net 5 pipeline works
// // in which each registered handler will attempt to authenticate and if it fails it will just call Next() so the next handler
// // executes. If it is successful, it doesn't call next and assigns the current user/principal.
// // This might actually all be possible with ASP.Net Identity and how it is setup to work already, need to investigate.
// var ticket = http.GetUmbracoAuthTicket();
// http.AuthenticateCurrentRequest(ticket, ShouldIgnoreTicketRenew(UmbracoContext.Current.OriginalRequestUrl, http) == false);
//}
}
#endregion #endregion
#region Methods #region Methods
@@ -590,8 +553,6 @@ namespace Umbraco.Web
BeginRequest(new HttpContextWrapper(httpContext)); BeginRequest(new HttpContextWrapper(httpContext));
}; };
app.AuthenticateRequest += AuthenticateRequest;
app.PostResolveRequestCache += (sender, e) => app.PostResolveRequestCache += (sender, e) =>
{ {
var httpContext = ((HttpApplication)sender).Context; var httpContext = ((HttpApplication)sender).Context;

View File

@@ -27,7 +27,6 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Tests", "Tests", "{B5BD12C1
EndProject EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "NuSpecs", "NuSpecs", "{227C3B55-80E5-4E7E-A802-BE16C5128B9D}" Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "NuSpecs", "NuSpecs", "{227C3B55-80E5-4E7E-A802-BE16C5128B9D}"
ProjectSection(SolutionItems) = preProject ProjectSection(SolutionItems) = preProject
..\build\NuSpecs\UmbracoCms.ActiveDirectory.nuspec = ..\build\NuSpecs\UmbracoCms.ActiveDirectory.nuspec
..\build\NuSpecs\UmbracoCms.Core.AllBinaries.nuspec = ..\build\NuSpecs\UmbracoCms.Core.AllBinaries.nuspec ..\build\NuSpecs\UmbracoCms.Core.AllBinaries.nuspec = ..\build\NuSpecs\UmbracoCms.Core.AllBinaries.nuspec
..\build\NuSpecs\UmbracoCms.Core.nuspec = ..\build\NuSpecs\UmbracoCms.Core.nuspec ..\build\NuSpecs\UmbracoCms.Core.nuspec = ..\build\NuSpecs\UmbracoCms.Core.nuspec
..\build\NuSpecs\UmbracoCms.Core.Symbols.nuspec = ..\build\NuSpecs\UmbracoCms.Core.Symbols.nuspec ..\build\NuSpecs\UmbracoCms.Core.Symbols.nuspec = ..\build\NuSpecs\UmbracoCms.Core.Symbols.nuspec