[asterisk-bugs] [JIRA] (ASTERISK-25885) res_pjsip: Race condition between adding contact and automatic expiration

Asterisk Team (JIRA) noreply at issues.asterisk.org
Wed Jul 27 10:16:17 CDT 2016


     [ https://issues.asterisk.org/jira/browse/ASTERISK-25885?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Asterisk Team updated ASTERISK-25885:
-------------------------------------

    Target Release Version/s: 14.0.0

> res_pjsip: Race condition between adding contact and automatic expiration
> -------------------------------------------------------------------------
>
>                 Key: ASTERISK-25885
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-25885
>             Project: Asterisk
>          Issue Type: Bug
>      Security Level: None
>          Components: Resources/res_pjsip, Resources/res_pjsip_registrar
>    Affects Versions: 13.8.0
>            Reporter: Joshua Colp
>            Assignee: George Joseph
>      Target Release: 13.9.0, 14.0.0
>
>
> There exists a race condition between res_pjsip_registrar and the code which expires contacts when querying contacts of an AOR. It is possible for the registrar thread and another thread to both retrieve and delete the contact. This is problematic given the following scenario:
> 1. Registrar retrieves contacts
> 2. Other thread retrieves contacts
> 3. Registrar causes deletion of expired contacts
> 4. Registrar adds new contacts
> 5. Other thread deletes expired contacts (as it has stale/old contacts)
> 6. Newly added contacts are gone that were expired
> This requires the same contacts to be expired and added, and for it to happen close.
> This is seen often enough in the tests/channels/pjsip/registration/inbound/nominal/multiple_contacts/ tests.



--
This message was sent by Atlassian JIRA
(v6.2#6252)



More information about the asterisk-bugs mailing list