Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
nghttp2
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Libraries
nghttp2
Commits
19b4da64
Commit
19b4da64
authored
Sep 26, 2021
by
Tatsuhiro Tsujikawa
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
nghttpx: Support h3-29
parent
886dc93f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
10 deletions
+16
-10
src/shrpx_tls.cc
src/shrpx_tls.cc
+16
-10
No files found.
src/shrpx_tls.cc
View file @
19b4da64
...
...
@@ -703,20 +703,26 @@ namespace {
int
quic_alpn_select_proto_cb
(
SSL
*
ssl
,
const
unsigned
char
**
out
,
unsigned
char
*
outlen
,
const
unsigned
char
*
in
,
unsigned
int
inlen
,
void
*
arg
)
{
for
(
auto
p
=
in
,
end
=
in
+
inlen
;
p
<
end
;)
{
auto
proto_id
=
p
+
1
;
auto
proto_len
=
*
p
;
constexpr
StringRef
alpnlist
[]
=
{
StringRef
::
from_lit
(
"h3"
),
StringRef
::
from_lit
(
"h3-29"
),
};
if
(
proto_id
+
proto_len
<=
end
&&
util
::
streq_l
(
"h3"
,
StringRef
{
proto_id
,
proto_len
}))
{
for
(
auto
&
alpn
:
alpnlist
)
{
for
(
auto
p
=
in
,
end
=
in
+
inlen
;
p
<
end
;)
{
auto
proto_id
=
p
+
1
;
auto
proto_len
=
*
p
;
*
out
=
reinterpret_cast
<
const
unsigned
char
*>
(
proto_id
);
*
outlen
=
proto_len
;
if
(
alpn
.
size
()
==
proto_len
&&
memcmp
(
alpn
.
byte
(),
proto_id
,
alpn
.
size
())
==
0
)
{
*
out
=
proto_id
;
*
outlen
=
proto_len
;
return
SSL_TLSEXT_ERR_OK
;
}
return
SSL_TLSEXT_ERR_OK
;
}
p
+=
1
+
proto_len
;
p
+=
1
+
proto_len
;
}
}
return
SSL_TLSEXT_ERR_ALERT_FATAL
;
...
...
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