Avoid segfault when skey is not set in config
authorSimo Sorce <simo@redhat.com>
Sat, 13 Jun 2015 22:52:53 +0000 (18:52 -0400)
committerSimo Sorce <simo@redhat.com>
Sat, 13 Jun 2015 23:01:35 +0000 (19:01 -0400)
commitc01b7aa059ea8ff9b82407615571962a58839bd8
tree36c46d7692f6195d67a4dd86b6d4a4fa6b018ed7
parent83930b81b95c3dbb650e5878ec4ecacde7947733
Avoid segfault when skey is not set in config

When the skey is generated on the fly, we will get an empty key on the very
first auth attempt. If that uses basic auth then we'll segfault when trying
to compute the hmac as we pass in a NULL key and immediately dereference it.

Signed-off-by: Simo Sorce <simo@redhat.com>
src/sessions.c