[sr-dev] [kamailio/kamailio] pua_dialoginfo: Add display attributes to identity tags. (#2617)

Daniel-Constantin Mierla notifications at github.com
Wed Feb 3 14:50:27 CET 2021


@miconda commented on this pull request.



> @@ -188,6 +188,8 @@ str* build_dialoginfo(char *state, str *entity, str *peer, str *callid,
 			LM_ERR("while adding child\n");
 			goto error;
 		}
+		/* Testing(POC) - Add a display attribute to the remote/identity tag */
+		xmlNewProp(tag_node, BAD_CAST "display", BAD_CAST "RemoteCallerName");	

I understand that you want the user part from SIP URI set in identity tag, then practically you have to parse it with parse_uri() function, which fills a structure with a field point to user part. Like:

```
parse_uri(remotetarget->s, remotetarget->len, &puri);
```
Then use `puri.user.s` and `puri.user.len`, which point to the start of user part and give the length. Similar will be for localtarget part. 

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/2617#pullrequestreview-582380703
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-dev/attachments/20210203/5e0ba7cb/attachment.htm>


More information about the sr-dev mailing list