Skip to content

Commit 05f23b1

Browse files
committed
http/tls: Index banned_ciphers by standard cipher name
This alleviates the need for our own standard name to openssl name map for ciphers. Requires a new luaossl release
1 parent cd9ff6b commit 05f23b1

File tree

6 files changed

+7
-352
lines changed

6 files changed

+7
-352
lines changed

NEWS

+1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ UNRELEASED
44
- Fix incorrect timeout handling in `websocket:receive()`
55
- Add workaround to allow being required in openresty (#98)
66
- Add http.tls.old_cipher_list (#112)
7+
- Change http.tls.banned_ciphers to be indexed by standard cipher name (#116)
78

89

910
0.2 - 2017-05-28

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ This will automatically install run-time lua dependencies for you.
3030
## Dependencies
3131

3232
- [cqueues](http://25thandclement.com/~william/projects/cqueues.html) >= 20161214 (Note: cqueues currently doesn't support Microsoft Windows operating systems)
33-
- [luaossl](http://25thandclement.com/~william/projects/luaossl.html) >= 20161208
33+
- [luaossl](http://25thandclement.com/~william/projects/luaossl.html) >= 20180803
3434
- [basexx](https://github.com/aiq/basexx/) >= 0.2.0
3535
- [lpeg](http://www.inf.puc-rio.br/~roberto/lpeg/lpeg.html)
3636
- [lpeg_patterns](https://github.com/daurnimator/lpeg_patterns) >= 0.3

doc/modules/http.tls.md

+1-3
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,7 @@ The [Mozilla "Old" cipher list](https://wiki.mozilla.org/Security/Server_Side_TL
3131

3232
### `banned_ciphers` <!-- --> {#http.tls.banned_ciphers}
3333

34-
A set (table with string keys and values of `true`) of the [ciphers banned in HTTP 2](https://http2.github.io/http2-spec/#BadCipherSuites) where the keys are OpenSSL cipher names.
35-
36-
Ciphers not known by OpenSSL are missing from the set.
34+
A set (table with string keys and values of `true`) of the [ciphers banned in HTTP 2](https://http2.github.io/http2-spec/#BadCipherSuites) where the keys are standard cipher names.
3735

3836

3937
### `new_client_context()` <!-- --> {#http.tls.new_client_context}

http-scm-0.rockspec

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ dependencies = {
1616
"compat53 >= 0.3"; -- Only if lua < 5.3
1717
"bit32"; -- Only if lua == 5.1
1818
"cqueues >= 20161214";
19-
"luaossl >= 20161208";
19+
"luaossl >= 20180803";
2020
"basexx >= 0.2.0";
2121
"lpeg";
2222
"lpeg_patterns >= 0.3";

http/h2_connection.lua

+2-2
Original file line numberDiff line numberDiff line change
@@ -102,8 +102,8 @@ local function new_connection(socket, conn_type, settings)
102102
local ssl = socket:checktls()
103103
if ssl then
104104
local cipher = ssl:getCipherInfo()
105-
if h2_banned_ciphers[cipher.name] then
106-
h2_error.errors.INADEQUATE_SECURITY("bad cipher: " .. cipher.name)
105+
if h2_banned_ciphers[cipher.standard_name] then
106+
h2_error.errors.INADEQUATE_SECURITY("bad cipher: " .. cipher.standard_name)
107107
end
108108
end
109109

0 commit comments

Comments
 (0)