I need to authenticate against a proxy server, and after the first HTTP request the I need to parse the proxy-authenticate header string to get the relevant values.
The response headers look something like this,
{ 'content-type': 'text/plain',
'proxy-authenticate': 'Digest realm="zippy", qop="auth",nonce="c1e1c76b5df5a8cdc921b48d6a7b5493", algorithm="MD5", stale="false"',
date: 'Thu, 21 Apr 2016 00:19:28 GMT',
connection: 'close',
'transfer-encoding': 'chunked' }
I want to extract the proxy-authenticate parameters (i.e. realm, qop, etc.), from the string.
It seems like there must be some super simple way to do this, but I'm just not finding it.