Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

User-Agent header and Server header not sent in the requests/responses #1126

Closed
logslie opened this issue May 11, 2017 · 1 comment
Closed

Comments

@logslie
Copy link

logslie commented May 11, 2017

Description

When configuring as a global configuration the following parameters:

user_agent_header="User-Agent: foobar-1.0.0"
server_header="Server: foobar-1.0.0"

I expected to have in every responses the Server header and in every requests the User-Agent header. But I'm only see the Server header in the first 100 response and the User Agent header is never sent in the responses.

Log Messages

I don't have any error message in the log.

SIP Traffic

  • First response to an INVITE with Server header.
    responsewithserverheader

  • First resquest without User-Agent header:
    requestwithoutuseragentheader

  • Second response without Server header:
    responsewithoutserverheader

Additional Information

  • Kamailio Version - output of kamailio -v
kamailio-4.4.5
  • Operating System:
Linux test200 2.6.32-642.15.1.el6.x86_64 #1 SMP Fri Feb 24 14:31:22 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux

Is there something that I'm doing wrong?

Thanks

@miconda
Copy link
Member

miconda commented May 13, 2017

Those headers are added by kamailio only when it is the origin of the request (adding user-agent) or the response (adding server). If kamailio is forwarding the request or response, it doesn't add any of these headers.

You can add them using append_hf(...) in the request_route{} or reply_route{}.

I am going to close this issue, if you need to seek further clarifications, use the sr-users@lists.kamailio.org for discussions.

@miconda miconda closed this as completed May 13, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants