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
1589642a
Commit
1589642a
authored
Jun 27, 2017
by
Jehonathan Thomas
Committed by
GitHub
Jun 27, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #288 from honfika/develop
Parse ssl extensions
parents
c8338bfe
82f88814
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
445 additions
and
18 deletions
+445
-18
CustomBufferedPeekStream.cs
Titanium.Web.Proxy/Helpers/CustomBufferedPeekStream.cs
+2
-1
ConnectRequest.cs
Titanium.Web.Proxy/Http/ConnectRequest.cs
+15
-0
HttpsTools.cs
Titanium.Web.Proxy/Http/HttpsTools.cs
+428
-17
No files found.
Titanium.Web.Proxy/Helpers/CustomBufferedPeekStream.cs
View file @
1589642a
...
@@ -17,10 +17,11 @@ namespace Titanium.Web.Proxy.Helpers
...
@@ -17,10 +17,11 @@ namespace Titanium.Web.Proxy.Helpers
position
=
startPosition
;
position
=
startPosition
;
}
}
public
int
Available
=>
baseStream
.
Available
-
position
;
public
async
Task
<
bool
>
EnsureBufferLength
(
int
length
)
public
async
Task
<
bool
>
EnsureBufferLength
(
int
length
)
{
{
var
val
=
await
baseStream
.
PeekByteAsync
(
length
-
1
);
var
val
=
await
baseStream
.
PeekByteAsync
(
position
+
length
-
1
);
return
val
!=
-
1
;
return
val
!=
-
1
;
}
}
...
...
Titanium.Web.Proxy/Http/ConnectRequest.cs
View file @
1589642a
...
@@ -36,6 +36,12 @@ namespace Titanium.Web.Proxy.Http
...
@@ -36,6 +36,12 @@ namespace Titanium.Web.Proxy.Http
public
byte
[]
SessionId
{
get
;
set
;
}
public
byte
[]
SessionId
{
get
;
set
;
}
public
byte
[]
CiphersData
{
get
;
set
;
}
public
byte
[]
CompressionData
{
get
;
set
;
}
public
List
<
Extension
>
Extensions
{
get
;
set
;
}
private
static
string
SslVersionToString
(
int
major
,
int
minor
)
private
static
string
SslVersionToString
(
int
major
,
int
minor
)
{
{
string
str
=
"Unknown"
;
string
str
=
"Unknown"
;
...
@@ -69,6 +75,15 @@ namespace Titanium.Web.Proxy.Http
...
@@ -69,6 +75,15 @@ namespace Titanium.Web.Proxy.Http
sb
.
AppendLine
(
$"\"Time\":
{
Time
}
"
);
sb
.
AppendLine
(
$"\"Time\":
{
Time
}
"
);
sb
.
AppendLine
(
$"SessionID:
{
string
.
Join
(
" "
,
SessionId
.
Select
(
x
=>
x
.
ToString
(
"X2"
)))}
"
);
sb
.
AppendLine
(
$"SessionID:
{
string
.
Join
(
" "
,
SessionId
.
Select
(
x
=>
x
.
ToString
(
"X2"
)))}
"
);
if
(
Extensions
!=
null
)
{
sb
.
AppendLine
(
"Extensions:"
);
foreach
(
var
extension
in
Extensions
)
{
sb
.
AppendLine
(
$"
{
extension
.
Name
}
:
{
extension
.
Data
}
"
);
}
}
return
sb
.
ToString
();
return
sb
.
ToString
();
}
}
}
}
...
...
Titanium.Web.Proxy/Http/HttpsTools.cs
View file @
1589642a
This diff is collapsed.
Click to expand it.
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