[Libwebsockets] Custom HTTP Headers

Mike Mathews Mike.Mathews at comtechtel.com
Tue Aug 15 08:03:16 CEST 2017


Hi:

We have an application of libwebsockets where we are passing custom headers, for example a header might include:

POST /SomeEndpoint HTTP/1.1
Host: localhost:3000
api_key: Fv-xkmMYQ0OdEQH-TPbMUupFYuFpYTKl45r1tmpR
Content-Type: application/json
Cache-Control: no-cache
Postman-Token: ae1e83a7-cd6a-f02c-d830-3f8c11f75e4b

...


What is the proper way to access the custom header elements?  The lws_hdr_copy(...) method requiring predefined tokens only works for predefined 'standard' headers.

Thank you,

Mike M.
NOTICE TO RECIPIENT: This email, including attachments, may contain information which is confidential, proprietary, attorney-client privileged and/or controlled under U.S. export laws and regulations and may be restricted from disclosure by applicable State and Federal law. Nothing in this email shall create any legal binding agreement between the parties unless expressly stated herein and provided by an authorized representative of Comtech Telecommunications Corp. or its subsidiaries. If you are not the intended recipient of this message, be advised that any dissemination, distribution, or use of the contents of this message is strictly prohibited. If you received this message in error, please notify us immediately by return email and permanently delete all copies of the original email and any attached documentation from any computer or other media.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://libwebsockets.org/pipermail/libwebsockets/attachments/20170815/7c11160b/attachment.html>


More information about the Libwebsockets mailing list