Use regexes to match ALPN protocols (#5651)
nginx presents the client's list of ALPN protocols as $ssl_preread_alpn_protocols, a comma-separated string. Use regular expressions to match each item in the list, rather than the exact value of the entire list at once.
This commit is contained in:
parent
f66a919e08
commit
0e16008085
|
@ -11,9 +11,8 @@ stream {
|
|||
}
|
||||
# since 1.13.10
|
||||
map $ssl_preread_alpn_protocols $upstream {
|
||||
"h2" web;
|
||||
"http/1.1" web;
|
||||
"h2,http/1.1" web;
|
||||
~\bh2\b web;
|
||||
~\bhttp/1\. web;
|
||||
default turn;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue