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

SIP diversion header available in RVD #1201

Merged
merged 1 commit into from Jun 28, 2016

Conversation

Projects
None yet
4 participants
@antonmry
Collaborator

antonmry commented Jun 18, 2016

It allows to have the value of SIP DIversion Header in a new RVD variable named $core_diversion. Also, it publish the variable $core_ForwardedFrom with the number so it may be used (only if the variable is empty).

We have tested with Voxbone, returning the following values:

  • $core_diversion: \u003csip:YYXXXXXXXXX@voxbone.com\u003e;counter\u003d1;reason\u003dUSER-BUSY"
  • $core_ForwardedFrom: YYXXXXXXXXX

A sipp scenario I've used to test it: https://gist.github.com/antonmry/cbb9383e4199fe294cbcb01d6ba1e573

@otsakir otsakir added the Peer Review label Jun 18, 2016

@deruelle deruelle added this to the 7.8.0 milestone Jun 23, 2016

@deruelle

This comment has been minimized.

Member

deruelle commented Jun 23, 2016

Thanks @antonmry ! @gvagenas will review

@otsakir

This comment has been minimized.

Contributor

otsakir commented Jun 23, 2016

@antonmry, i'm reviewing your patch from RVD side. I found no reference of $core_diversion variable inside RVD. Am i missing sth?
$core_ForwardedFrom is fine.

if (logger.isDebugEnabled()) {
logger.debug("%%%%%%%%%%% Identified diversion header: " + sipDiversionHeader);
}
parameters.add(new BasicNameValuePair(prefix + headerName, sipDiversionHeader));

This comment has been minimized.

@antonmry

antonmry Jun 23, 2016

Collaborator

@otsakir , I have use this nice feature where the custom headers are added with a prefix, in this case, the Header is "diversion", so that's the RVD variable

@antonmry

This comment has been minimized.

Collaborator

antonmry commented Jun 23, 2016

@otsakir , not sure if you are notified with line notes, check my comment, please.

@otsakir

This comment has been minimized.

Contributor

otsakir commented Jun 24, 2016

@antonmry, indeed the direction SipHeader_diversion is forwarded to RVD nicely as you describe. The behaviour was not really expected since it relies on the fact that we don't do much of sanitization for SipHeader_* paramaters from the RVD side.

Anyway, let's not bother now about it. It's clear from my side (RVD). @gvagenas , please proceed to reviewing.

@antonmry

This comment has been minimized.

Collaborator

antonmry commented Jun 25, 2016

@otsakir, yes, I agree it's not obvious. I did it in that way because that variable is more for debugging and it avoided to have "not important" variables in RVD, as it's the case with custom headers.

@gvagenas gvagenas merged commit 84c65b6 into RestComm:master Jun 28, 2016

@gvagenas gvagenas removed the Peer Review label Jun 28, 2016

@otsakir

This comment has been minimized.

Contributor

otsakir commented Jun 28, 2016

It makes sense. Thanks for contributing this @antonmry ;-)

@antonmry antonmry deleted the antonmry:diversionheader#3 branch Jun 28, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment