Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
T
Titanium-Web-Proxy
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
Titanium-Web-Proxy
Commits
3584b878
Commit
3584b878
authored
Jul 24, 2016
by
Jehonathan
Committed by
GitHub
Jul 24, 2016
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #104 from justcoding121/release
rename Upstreamproxy =>ExternalProxy
parents
6a3a07bf
3e818727
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
16 additions
and
34 deletions
+16
-34
README.md
README.md
+2
-2
HttpWebClient.cs
Titanium.Web.Proxy/Http/HttpWebClient.cs
+0
-1
TcpConnection.cs
Titanium.Web.Proxy/Network/TcpConnection.cs
+0
-15
TcpConnectionFactory.cs
Titanium.Web.Proxy/Network/TcpConnectionFactory.cs
+1
-2
ProxyServer.cs
Titanium.Web.Proxy/ProxyServer.cs
+12
-13
RequestHandler.cs
Titanium.Web.Proxy/RequestHandler.cs
+1
-1
No files found.
README.md
View file @
3584b878
...
@@ -69,8 +69,8 @@ Setup HTTP proxy:
...
@@ -69,8 +69,8 @@ Setup HTTP proxy:
};
};
proxyServer
.
AddEndPoint
(
transparentEndPoint
);
proxyServer
.
AddEndPoint
(
transparentEndPoint
);
//proxyServer.
UpStream
HttpProxy = new ExternalProxy() { HostName = "localhost", Port = 8888 };
//proxyServer.
External
HttpProxy = new ExternalProxy() { HostName = "localhost", Port = 8888 };
//proxyServer.
UpStream
HttpsProxy = new ExternalProxy() { HostName = "localhost", Port = 8888 };
//proxyServer.
External
HttpsProxy = new ExternalProxy() { HostName = "localhost", Port = 8888 };
foreach
(
var
endPoint
in
proxyServer
.
ProxyEndPoints
)
foreach
(
var
endPoint
in
proxyServer
.
ProxyEndPoints
)
Console
.
WriteLine
(
"Listening on '{0}' endpoint at Ip {1} and port: {2} "
,
Console
.
WriteLine
(
"Listening on '{0}' endpoint at Ip {1} and port: {2} "
,
...
...
Titanium.Web.Proxy/Http/HttpWebClient.cs
View file @
3584b878
...
@@ -39,7 +39,6 @@ namespace Titanium.Web.Proxy.Http
...
@@ -39,7 +39,6 @@ namespace Titanium.Web.Proxy.Http
/// <param name="Connection"></param>
/// <param name="Connection"></param>
internal
void
SetConnection
(
TcpConnection
Connection
)
internal
void
SetConnection
(
TcpConnection
Connection
)
{
{
Connection
.
LastAccess
=
DateTime
.
Now
;
ServerConnection
=
Connection
;
ServerConnection
=
Connection
;
}
}
...
...
Titanium.Web.Proxy/Network/TcpConnection.cs
View file @
3584b878
...
@@ -15,11 +15,6 @@ namespace Titanium.Web.Proxy.Network
...
@@ -15,11 +15,6 @@ namespace Titanium.Web.Proxy.Network
internal
bool
IsHttps
{
get
;
set
;
}
internal
bool
IsHttps
{
get
;
set
;
}
/// <summary>
/// Http version
/// </summary>
internal
Version
Version
{
get
;
set
;
}
internal
TcpClient
TcpClient
{
get
;
set
;
}
internal
TcpClient
TcpClient
{
get
;
set
;
}
/// <summary>
/// <summary>
...
@@ -32,16 +27,6 @@ namespace Titanium.Web.Proxy.Network
...
@@ -32,16 +27,6 @@ namespace Titanium.Web.Proxy.Network
/// </summary>
/// </summary>
internal
Stream
Stream
{
get
;
set
;
}
internal
Stream
Stream
{
get
;
set
;
}
/// <summary>
/// Last time this connection was used
/// </summary>
internal
DateTime
LastAccess
{
get
;
set
;
}
internal
TcpConnection
()
{
LastAccess
=
DateTime
.
Now
;
}
public
void
Dispose
()
public
void
Dispose
()
{
{
Stream
.
Close
();
Stream
.
Close
();
...
...
Titanium.Web.Proxy/Network/TcpConnectionFactory.cs
View file @
3584b878
...
@@ -127,8 +127,7 @@ namespace Titanium.Web.Proxy.Network
...
@@ -127,8 +127,7 @@ namespace Titanium.Web.Proxy.Network
IsHttps
=
isHttps
,
IsHttps
=
isHttps
,
TcpClient
=
client
,
TcpClient
=
client
,
StreamReader
=
new
CustomBinaryReader
(
stream
),
StreamReader
=
new
CustomBinaryReader
(
stream
),
Stream
=
stream
,
Stream
=
stream
Version
=
httpVersion
};
};
}
}
}
}
...
...
Titanium.Web.Proxy/ProxyServer.cs
View file @
3584b878
...
@@ -17,6 +17,15 @@ namespace Titanium.Web.Proxy
...
@@ -17,6 +17,15 @@ namespace Titanium.Web.Proxy
/// </summary>
/// </summary>
public
partial
class
ProxyServer
:
IDisposable
public
partial
class
ProxyServer
:
IDisposable
{
{
/// <summary>
/// Does the root certificate used by this proxy is trusted by the machine?
/// </summary>
private
bool
certTrusted
{
get
;
set
;
}
/// <summary>
/// Is the proxy currently running
/// </summary>
private
bool
proxyRunning
{
get
;
set
;
}
/// <summary>
/// <summary>
/// Manages certificates used by this proxy
/// Manages certificates used by this proxy
...
@@ -35,16 +44,6 @@ namespace Titanium.Web.Proxy
...
@@ -35,16 +44,6 @@ namespace Titanium.Web.Proxy
private
FireFoxProxySettingsManager
firefoxProxySettingsManager
{
get
;
set
;
}
private
FireFoxProxySettingsManager
firefoxProxySettingsManager
{
get
;
set
;
}
/// <summary>
/// Does the root certificate used by this proxy is trusted by the machine?
/// </summary>
private
bool
certTrusted
{
get
;
set
;
}
/// <summary>
/// Is the proxy currently running
/// </summary>
private
bool
proxyRunning
{
get
;
set
;
}
/// <summary>
/// <summary>
/// Buffer size used throughout this proxy
/// Buffer size used throughout this proxy
/// </summary>
/// </summary>
...
@@ -89,12 +88,12 @@ namespace Titanium.Web.Proxy
...
@@ -89,12 +88,12 @@ namespace Titanium.Web.Proxy
/// <summary>
/// <summary>
/// External proxy for Http
/// External proxy for Http
/// </summary>
/// </summary>
public
ExternalProxy
UpStream
HttpProxy
{
get
;
set
;
}
public
ExternalProxy
External
HttpProxy
{
get
;
set
;
}
/// <summary>
/// <summary>
/// External proxy for Http
/// External proxy for Http
s
/// </summary>
/// </summary>
public
ExternalProxy
UpStream
HttpsProxy
{
get
;
set
;
}
public
ExternalProxy
External
HttpsProxy
{
get
;
set
;
}
/// <summary>
/// <summary>
/// Verifies the remote Secure Sockets Layer (SSL) certificate used for authentication
/// Verifies the remote Secure Sockets Layer (SSL) certificate used for authentication
...
...
Titanium.Web.Proxy/RequestHandler.cs
View file @
3584b878
...
@@ -332,7 +332,7 @@ namespace Titanium.Web.Proxy
...
@@ -332,7 +332,7 @@ namespace Titanium.Web.Proxy
args
.
IsHttps
,
SupportedSslProtocols
,
args
.
IsHttps
,
SupportedSslProtocols
,
new
RemoteCertificateValidationCallback
(
ValidateServerCertificate
),
new
RemoteCertificateValidationCallback
(
ValidateServerCertificate
),
new
LocalCertificateSelectionCallback
(
SelectClientCertificate
),
new
LocalCertificateSelectionCallback
(
SelectClientCertificate
),
UpStreamHttpProxy
,
UpStream
HttpsProxy
,
clientStream
);
ExternalHttpProxy
,
External
HttpsProxy
,
clientStream
);
}
}
args
.
WebSession
.
Request
.
RequestLocked
=
true
;
args
.
WebSession
.
Request
.
RequestLocked
=
true
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment