[erlang-questions] how to know who is the caller id from an httpc:request?

11 views
Skip to first unread message

Brisa Jiménez

unread,
Apr 2, 2013, 7:10:12 PM4/2/13
to erlang-q...@erlang.org
Hi,
Another question:
How to know who is the caller id from an httpc:request?
Thank again!

John Kemp

unread,
Apr 2, 2013, 7:47:34 PM4/2/13
to Brisa Jiménez, erlang-q...@erlang.org
On Apr 2, 2013, at 7:10 PM, Brisa Jiménez <brisa.j...@gmail.com> wrote:

> Hi,
> Another question:
> How to know who is the caller id from an httpc:request?

If you are using a (generic) HTTP server to receive the request, you could set, in the httpc request, the User-Agent HTTP header to a known value and then extract the vaue of the User-Agent HTTP header at your server. Another option would be to set a cookie from the server to client upon first connection, and then send the cookie on all subsequent requests from httpc.

Depending on what HTTP server technology you're using, there may also be other mechanisms available. What HTTP server are you using?

Cheers,

JohnK

> Thank again!
> _______________________________________________
> erlang-questions mailing list
> erlang-q...@erlang.org
> http://erlang.org/mailman/listinfo/erlang-questions

_______________________________________________
erlang-questions mailing list
erlang-q...@erlang.org
http://erlang.org/mailman/listinfo/erlang-questions
Reply all
Reply to author
Forward
0 new messages