curl / Mailing Lists / curl-users / Single Mail

curl-users

Suggestion: -H from a file...

From: Timothe Litt <litt_at_acm.org>
Date: Mon, 15 May 2017 08:57:06 -0400

I had reason to use curl to interact with a service that requires a
secret key in
 a (proprietary) authorization header.

As far as I can tell, the only way to specify the header is with -H,
which works.

But it has the unfortunate side-effect of showing up in a 'ps' listing
since it's on
the command line. This can reveal the authorization secrets to other system
users, which is not good.

--config might be a work-around, but would require finding and merging the
  'real' curlrc into a temporary file - and securing that..

Suggestion: add a way to specify -H from a file, perhaps -H_at_filespec as is
                      provided for-d & friends? This would also make it
easy to put
                      multiple headers into an @file. And @- would
allow a HERE
                      document to be used in a script.

Thanks for your consideration.

-- 
Timothe Litt
ACM Distinguished Engineer
--------------------------
This communication may not represent the ACM or my employer's views,
if any, on the matters discussed. 
-----------------------------------------------------------
Unsubscribe: https://cool.haxx.se/list/listinfo/curl-users
Etiquette:   https://curl.haxx.se/mail/etiquette.html
Received on 2017-05-15