<p></p>
<p>Hi Aleksandar,</p>
<p>According to Kamalio naming, top via is the first via, and bottom via header is the last via.<br>
For each request, UAC puts its via header to the top of the list.  And for each response,  UAC deletes the top via header.<br>
So the bottom via  (last via) always belongs to the UE's UAC (it doesn't matter if it is Request or Response).<br>
Why we use first Via header to identify the UE?</p>
<p>BR,<br>
Erhan Sendag</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you commented.<br />Reply to this email directly, <a href="https://github.com/kamailio/kamailio/issues/2864#issuecomment-934345369">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/ABO7UZPLYQ5HOGOGCTJOHCLUFLSRBANCNFSM5E6NWBGA">unsubscribe</a>.<br />Triage notifications on the go with GitHub Mobile for <a href="https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675">iOS</a> or <a href="https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub">Android</a>.
<img src="https://github.com/notifications/beacon/ABO7UZMXXSB4TUW5OYGDSMLUFLSRBA5CNFSM5E6NWBGKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOG6YPVGI.gif" height="1" width="1" alt="" /></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/kamailio/kamailio/issues/2864#issuecomment-934345369",
"url": "https://github.com/kamailio/kamailio/issues/2864#issuecomment-934345369",
"name": "View Issue"
},
"description": "View this Issue on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>