<div dir="ltr"><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:#000099">Hello Grant, thank you </div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:#000099"> I was thinking of writing a perl module for this if i still cant do it.</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:#000099">I will try tomorrow :)</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:#000099"><br></div><div><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><font color="#000000" face="verdana, sans-serif">Regards,<br>Gordon Yeong</font></div></div></div></div></div></div></div></div></div></div></div><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, 31 Mar 2020 at 21:20, Grant Bagdasarian <<a href="mailto:grantbagdasarian@gmail.com">grantbagdasarian@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div><div dir="auto">Hi Gordon,</div></div><div dir="auto"><br></div><div dir="auto">I believe you’re looking for the username in the From header.</div><div dir="auto">It’s the $fU variable.</div><div dir="auto"><br></div><div dir="auto"><div><a href="https://www.opensips.org/Documentation/Script-CoreVar-3-1#toc47" target="_blank">https://www.opensips.org/Documentation/Script-CoreVar-3-1#toc47</a></div><br></div><div dir="auto">That should give you 12345688.</div><div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, 31 Mar 2020 at 08:56 Gordon Yeong <<a href="mailto:anexiole@gmail.com" target="_blank">anexiole@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)">Hi guys,</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)"><br></div><div class="gmail_default"><span style="color:rgb(0,0,153);font-family:arial,helvetica,sans-serif">I looked up <a href="https://tools.ietf.org/html/rfc3261" style="font-size:13.3333px;font-family:Arial,Helvetica,sans-serif;color:rgb(119,119,119)" target="_blank">RFC 3261</a>.</span><font color="#777777"><span style="font-size:13.3333px"> and the </span></font><span style="color:rgb(0,0,153);font-family:arial,helvetica,sans-serif">from-spec (page 229) says:</span></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)"><div class="gmail_default"><pre style="font-size:13.3333px;margin-top:0px;margin-bottom:0px;break-before:page;color:rgb(0,0,0)">from-spec   =  ( name-addr / addr-spec )
               *( SEMI from-param )</pre></div></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)">I have the following FROM tag in a SIP header.</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)">"Mr Invite-R-Us <<a href="http://sip:12345688@192.168.136.134:5060" target="_blank">sip:12345688@192.168.136.134:5060</a>>;tag=784"</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)">In my opensips.cfg, I got the following results using the <span style="color:rgb(0,0,0);font-size:13.3333px;font-family:Arial,Helvetica,sans-serif">compact forms, m and f</span></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)">$var(CALLING2)=$hdr(m); --> printed out <sip:sipp@192.168.136.134:5060;transport=UDP><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)">$var(CALLING3)=$hdr(f);  --> printed out Mr Invite-R-Us <<a href="http://sip:12345688@192.168.136.134:5060" target="_blank">sip:12345688@192.168.136.134:5060</a>>;tag=784<br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)">I have looked through the RFC document again but could not find  how one could get the "name-addr" (ie. "

12345688"). I have also looked through the Opensips Core variable documentation.</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)">Can anyone please tell me how to get the name-addr within a From header? What is the attribute name or compact form? </div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)">Thank you</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,153)">Gordon</div></div>
_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@lists.opensips.org" target="_blank">Users@lists.opensips.org</a><br>
<a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" rel="noreferrer" target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><br>
</blockquote></div></div>
_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@lists.opensips.org" target="_blank">Users@lists.opensips.org</a><br>
<a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" rel="noreferrer" target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><br>
</blockquote></div>