security: add API to return context name
commit9259953aa52bd78011764ffdbf1236d49b81baee
authorStefan Becker <chemobejk@gmail.com>
Mon, 21 Oct 2013 12:59:11 +0000 (21 15:59 +0300)
committerStefan Becker <chemobejk@gmail.com>
Mon, 21 Oct 2013 18:11:22 +0000 (21 21:11 +0300)
tree15db35af9fd1ed5eb88457441f1189223977b700
parentf7a813dc76e8b9025d36b8064a698f025629ddba
security: add API to return context name

SPNEGO authentication scheme (RFC 4559) requires wrapping of raw NTLM
messages. Only wrapped NTLM messages should be sent with the
"Authorization: Negotiate" header. sip-sec-negotiate.c does *NOT*
implement SPNEGO. Instead we send raw NTLM messages and therefore should
use "Authorization: NTLM" header.

Add a new sip-sec.c API that returns the current name of the security
context, so that sipe-http-request.c can generate the correct header.
src/core/sip-sec-basic.c
src/core/sip-sec-krb5.c
src/core/sip-sec-mech.h
src/core/sip-sec-negotiate.c
src/core/sip-sec-ntlm.c
src/core/sip-sec-sspi.c
src/core/sip-sec-tls-dsk.c
src/core/sip-sec.c
src/core/sip-sec.h
src/core/sipe-http-request.c