Skip to content
This repository was archived by the owner on Nov 20, 2018. It is now read-only.

Remove IsLocal #538

Merged
merged 1 commit into from
Jan 19, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions src/Microsoft.AspNet.Http.Abstractions/ConnectionInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,6 @@ public abstract class ConnectionInfo

public abstract int LocalPort { get; set; }

public abstract bool IsLocal { get; set; }

public abstract X509Certificate2 ClientCertificate { get; set; }

public abstract Task<X509Certificate2> GetClientCertificateAsync(CancellationToken cancellationToken = new CancellationToken());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,5 @@ public interface IHttpConnectionFeature
IPAddress LocalIpAddress { get; set; }
int RemotePort { get; set; }
int LocalPort { get; set; }
bool IsLocal { get; set; }
}
}
6 changes: 0 additions & 6 deletions src/Microsoft.AspNet.Http/DefaultConnectionInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -59,12 +59,6 @@ public override int LocalPort
set { HttpConnectionFeature.LocalPort = value; }
}

public override bool IsLocal
{
get { return HttpConnectionFeature.IsLocal; }
set { HttpConnectionFeature.IsLocal = value; }
}

public override X509Certificate2 ClientCertificate
{
get { return TlsConnectionFeature.ClientCertificate; }
Expand Down
2 changes: 0 additions & 2 deletions src/Microsoft.AspNet.Http/Features/HttpConnectionFeature.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@ public HttpConnectionFeature()
{
}

public bool IsLocal { get; set; }

public IPAddress LocalIpAddress { get; set; }

public int LocalPort { get; set; }
Expand Down
1 change: 0 additions & 1 deletion src/Microsoft.AspNet.Owin/OwinConstants.cs
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,6 @@ internal static class CommonKeys
public const string RemotePort = "server.RemotePort";
public const string LocalIpAddress = "server.LocalIpAddress";
public const string LocalPort = "server.LocalPort";
public const string IsLocal = "server.IsLocal";
public const string TraceOutput = "host.TraceOutput";
public const string Addresses = "host.Addresses";
public const string AppName = "host.AppName";
Expand Down
2 changes: 0 additions & 2 deletions src/Microsoft.AspNet.Owin/OwinEnvironment.cs
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,6 @@ public OwinEnvironment(HttpContext context)
{ OwinConstants.CommonKeys.RemoteIpAddress, new FeatureMap<IHttpConnectionFeature>(feature => feature.RemoteIpAddress.ToString(),
(feature, value) => feature.RemoteIpAddress = IPAddress.Parse(Convert.ToString(value))) },

{ OwinConstants.CommonKeys.IsLocal, new FeatureMap<IHttpConnectionFeature>(feature => feature.IsLocal, (feature, value) => feature.IsLocal = Convert.ToBoolean(value)) },

{ OwinConstants.SendFiles.SendAsync, new FeatureMap<IHttpSendFileFeature>(feature => new SendFileFunc(feature.SendFileAsync)) },

{ OwinConstants.Security.User, new FeatureMap<IHttpAuthenticationFeature>(feature => feature.User,
Expand Down
6 changes: 0 additions & 6 deletions src/Microsoft.AspNet.Owin/OwinFeatureCollection.cs
Original file line number Diff line number Diff line change
Expand Up @@ -190,12 +190,6 @@ int IHttpConnectionFeature.LocalPort
set { Prop(OwinConstants.CommonKeys.LocalPort, value.ToString(CultureInfo.InvariantCulture)); }
}

bool IHttpConnectionFeature.IsLocal
{
get { return Prop<bool>(OwinConstants.CommonKeys.IsLocal); }
set { Prop(OwinConstants.CommonKeys.LocalPort, value); }
}

private bool SupportsSendFile
{
get
Expand Down