Commit 95900411 authored by justcoding121's avatar justcoding121

remove obsolete already pushed to beta

parent 1ce0f7fa
...@@ -88,11 +88,8 @@ namespace Titanium.Web.Proxy.Examples.Wpf ...@@ -88,11 +88,8 @@ namespace Titanium.Web.Proxy.Examples.Wpf
////note : load now (if existed) ////note : load now (if existed)
//proxyServer.CertificateManager.LoadRootCertificate(@"C:\NameFolder\rootCert.pfx", "PfxPassword"); //proxyServer.CertificateManager.LoadRootCertificate(@"C:\NameFolder\rootCert.pfx", "PfxPassword");
var explicitEndPoint = new ExplicitProxyEndPoint(IPAddress.Any, 8000, true) var explicitEndPoint = new ExplicitProxyEndPoint(IPAddress.Any, 8000, true);
{
ExcludedHttpsHostNameRegex = new[] { "ssllabs.com" },
//IncludedHttpsHostNameRegex = new string[0],
};
proxyServer.AddEndPoint(explicitEndPoint); proxyServer.AddEndPoint(explicitEndPoint);
//proxyServer.UpStreamHttpProxy = new ExternalProxy //proxyServer.UpStreamHttpProxy = new ExternalProxy
......
...@@ -75,42 +75,6 @@ namespace Titanium.Web.Proxy.Models ...@@ -75,42 +75,6 @@ namespace Titanium.Web.Proxy.Models
/// </summary> /// </summary>
public X509Certificate2 GenericCertificate { get; set; } public X509Certificate2 GenericCertificate { get; set; }
/// <summary>
/// List of host names to exclude using Regular Expressions.
/// </summary>
[Obsolete("ExcludedHttpsHostNameRegex is deprecated, please use BeforeTunnelConnect event instead.")]
public IEnumerable<string> ExcludedHttpsHostNameRegex
{
get { return ExcludedHttpsHostNameRegexList?.Select(x => x.ToString()).ToList(); }
set
{
if (IncludedHttpsHostNameRegex != null)
{
throw new ArgumentException("Cannot set excluded when included is set");
}
ExcludedHttpsHostNameRegexList = value?.Select(x => new Regex(x, RegexOptions.Compiled)).ToList();
}
}
/// <summary>
/// List of host names to exclude using Regular Expressions.
/// </summary>
[Obsolete("IncludedHttpsHostNameRegex is deprecated, please use BeforeTunnelConnect event instead.")]
public IEnumerable<string> IncludedHttpsHostNameRegex
{
get { return IncludedHttpsHostNameRegexList?.Select(x => x.ToString()).ToList(); }
set
{
if (ExcludedHttpsHostNameRegex != null)
{
throw new ArgumentException("Cannot set included when excluded is set");
}
IncludedHttpsHostNameRegexList = value?.Select(x => new Regex(x, RegexOptions.Compiled)).ToList();
}
}
/// <summary> /// <summary>
/// Return true if this HTTP connect request should'nt be decrypted and instead be relayed /// Return true if this HTTP connect request should'nt be decrypted and instead be relayed
/// Valid only for explicit endpoints /// Valid only for explicit endpoints
......
...@@ -67,16 +67,6 @@ namespace Titanium.Web.Proxy ...@@ -67,16 +67,6 @@ namespace Titanium.Web.Proxy
//filter out excluded host names //filter out excluded host names
bool excluded = false; bool excluded = false;
if (endPoint.ExcludedHttpsHostNameRegex != null)
{
excluded = endPoint.ExcludedHttpsHostNameRegexList.Any(x => x.IsMatch(connectHostname));
}
if (endPoint.IncludedHttpsHostNameRegex != null)
{
excluded = !endPoint.IncludedHttpsHostNameRegexList.Any(x => x.IsMatch(connectHostname));
}
if(endPoint.BeforeTunnelConnect!=null) if(endPoint.BeforeTunnelConnect!=null)
{ {
excluded = await endPoint.BeforeTunnelConnect(connectHostname); excluded = await endPoint.BeforeTunnelConnect(connectHostname);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment