Skip to content

Commit

Permalink
update lua-openssl.supp for valgrind
Browse files Browse the repository at this point in the history
  • Loading branch information
zhaozg committed Apr 5, 2024
1 parent 16562a8 commit def7b96
Show file tree
Hide file tree
Showing 2 changed files with 81 additions and 1 deletion.
59 changes: 58 additions & 1 deletion .github/lua-openssl.supp
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,6 @@
fun:_dlerror_run
}

# OpenSSL 1.1.1
{
asn1.c ASN1_TYPE_set1 in openssl_asn1type_new
Memcheck:Leak
Expand All @@ -203,3 +202,61 @@
fun:ASN1_TYPE_set1
obj:*
}

{
asn1.c ASN1_TYPE_set1 in openssl_asn1type_new
Memcheck:Leak
match-leak-kinds: definite
fun:malloc
fun:CRYPTO_zalloc
fun:ASN1_STRING_type_new
fun:ASN1_STRING_dup
fun:ASN1_TYPE_set1
obj:*
}

{
dlopen_doit
Memcheck:Leak
match-leak-kinds: reachable
fun:malloc
fun:_dl_new_object
fun:_dl_map_object_from_fd
fun:_dl_map_object
fun:openaux
fun:_dl_catch_exception
fun:_dl_map_object_deps
fun:dl_open_worker
fun:_dl_catch_exception
fun:_dl_open
fun:dlopen_doit
fun:_dl_catch_exception
}

{
dlopen_doit
Memcheck:Leak
match-leak-kinds: reachable
fun:calloc
fun:_dl_new_object
fun:_dl_map_object_from_fd
fun:_dl_map_object
fun:openaux
fun:_dl_catch_exception
fun:_dl_map_object_deps
fun:dl_open_worker
fun:_dl_catch_exception
fun:_dl_open
fun:dlopen_doit
fun:_dl_catch_exception
}

{
ASN1_item_d2i
Memcheck:Leak
match-leak-kinds: indirect
fun:malloc
fun:CRYPTO_zalloc
obj:/usr/lib/x86_64-linux-gnu/libcrypto.so.1.1
fun:BN_bin2bn
}
23 changes: 23 additions & 0 deletions test/8.ssl.lua
Original file line number Diff line number Diff line change
Expand Up @@ -587,4 +587,27 @@ function TestSSL:testSNI()

sess = ssl.session_new()
sess:id(id)

bs, bc = bio.pair()
srv = assert(srv_ctx:ssl(bs))
srv:set_accept_state()
cli = assert(cli_ctx:ssl(bc))
cli:use(cert, pkey)
cli:set_connect_state()
cli:set('hostname', 'serverB')
repeat
cs, ec = cli:handshake()
rs, es = srv:handshake()
srv:want()
until (rs and cs) or (rs == nil or cs == nil)

local sbio = bio.filter('ssl', ssl)
sbio:close()

cli:clear()
cli:shutdown()

bs:close()
bc:close()

end

0 comments on commit def7b96

Please sign in to comment.