spdylay icon indicating copy to clipboard operation
spdylay copied to clipboard

spdycat does not support basic authentication

Open jarmo opened this issue 9 years ago • 3 comments

I cannot find a way to use spdycat with basic authentication, because it does not have curl like option --user nor does it support url in format https://user:password@host.

Is there any way to use spdycat when basic authentication is used?

jarmo avatar Jan 01 '15 13:01 jarmo

Use -H option and specify authorization header field directory like this:

-H 'authorization: basic aGVsbG86d29ybGQ='

tatsuhiro-t avatar Jan 02 '15 05:01 tatsuhiro-t

It's not very convenient, but possible indeed. I knew about that option, but thought that there's a little more user-friendly way to do that.

This is how you would do that without precalculating base64:

-H "Authorization: Basic `echo -n user:password | base64 -`"

jarmo avatar Jan 05 '15 07:01 jarmo

We have base64 encoder, so it is not hard to add this functionality. Just add new option and add authorization header to custom header fields added by -H option.

tatsuhiro-t avatar Jan 05 '15 07:01 tatsuhiro-t