[Asterisk-code-review] testsuite: add tests to validate the behavior of the flag us... (testsuite[master])

Jenkins2 asteriskteam at digium.com
Mon Oct 29 13:31:43 CDT 2018


Jenkins2 has submitted this change and it was merged. ( https://gerrit.asterisk.org/10502 )

Change subject: testsuite: add tests to validate the behavior of the flag use_callerid_contact
......................................................................

testsuite: add tests to validate the behavior of the flag use_callerid_contact

ASTERISK-28087 #close

Change-Id: I168603c8397557316863116edfd0d611e7ed7ef9
---
M tests/channels/pjsip/tests.yaml
A tests/channels/pjsip/use_callerid_contact/no_privacy/contact_user/configs/ast1/extensions.conf
A tests/channels/pjsip/use_callerid_contact/no_privacy/contact_user/configs/ast1/pjsip.conf
A tests/channels/pjsip/use_callerid_contact/no_privacy/contact_user/sipp/A_PARTY.xml
A tests/channels/pjsip/use_callerid_contact/no_privacy/contact_user/sipp/B_PARTY.xml
A tests/channels/pjsip/use_callerid_contact/no_privacy/contact_user/test-config.yaml
A tests/channels/pjsip/use_callerid_contact/no_privacy/tests.yaml
A tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_disabled/configs/ast1/extensions.conf
A tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_disabled/configs/ast1/pjsip.conf
A tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_disabled/sipp/A_PARTY.xml
A tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_disabled/sipp/B_PARTY.xml
A tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_disabled/test-config.yaml
A tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_enabled/configs/ast1/extensions.conf
A tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_enabled/configs/ast1/pjsip.conf
A tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_enabled/sipp/A_PARTY.xml
A tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_enabled/sipp/B_PARTY.xml
A tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_enabled/test-config.yaml
A tests/channels/pjsip/use_callerid_contact/privacy/contact_user/configs/ast1/extensions.conf
A tests/channels/pjsip/use_callerid_contact/privacy/contact_user/configs/ast1/pjsip.conf
A tests/channels/pjsip/use_callerid_contact/privacy/contact_user/sipp/A_PARTY.xml
A tests/channels/pjsip/use_callerid_contact/privacy/contact_user/sipp/B_PARTY.xml
A tests/channels/pjsip/use_callerid_contact/privacy/contact_user/test-config.yaml
A tests/channels/pjsip/use_callerid_contact/privacy/tests.yaml
A tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_disabled/configs/ast1/extensions.conf
A tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_disabled/configs/ast1/pjsip.conf
A tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_disabled/sipp/A_PARTY.xml
A tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_disabled/sipp/B_PARTY.xml
A tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_disabled/test-config.yaml
A tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_enabled/configs/ast1/extensions.conf
A tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_enabled/configs/ast1/pjsip.conf
A tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_enabled/sipp/A_PARTY.xml
A tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_enabled/sipp/B_PARTY.xml
A tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_enabled/test-config.yaml
A tests/channels/pjsip/use_callerid_contact/tests.yaml
34 files changed, 1,779 insertions(+), 0 deletions(-)

Approvals:
  Joshua Colp: Looks good to me, but someone else must approve
  Kevin Harwell: Looks good to me, but someone else must approve
  George Joseph: Looks good to me, approved
  Jenkins2: Approved for Submit



diff --git a/tests/channels/pjsip/tests.yaml b/tests/channels/pjsip/tests.yaml
index 34ecab7..c8659e4 100644
--- a/tests/channels/pjsip/tests.yaml
+++ b/tests/channels/pjsip/tests.yaml
@@ -54,3 +54,4 @@
     - test: 'multipart_empty_part'
     - test: 'dtmf_info_fallback'
     - test: 'invalid_uris'
+    - test: 'use_callerid_contact'
diff --git a/tests/channels/pjsip/use_callerid_contact/no_privacy/contact_user/configs/ast1/extensions.conf b/tests/channels/pjsip/use_callerid_contact/no_privacy/contact_user/configs/ast1/extensions.conf
new file mode 100644
index 0000000..ad7b155
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/no_privacy/contact_user/configs/ast1/extensions.conf
@@ -0,0 +1,11 @@
+[general]
+static=yes
+writeprotect=yes
+autofallthrough=yes
+clearglobalvars=no
+priorityjumping=yes
+
+[globals]
+
+[default]
+exten => _X.,1,Dial(pjsip/sbc,180)
diff --git a/tests/channels/pjsip/use_callerid_contact/no_privacy/contact_user/configs/ast1/pjsip.conf b/tests/channels/pjsip/use_callerid_contact/no_privacy/contact_user/configs/ast1/pjsip.conf
new file mode 100644
index 0000000..cb633f1
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/no_privacy/contact_user/configs/ast1/pjsip.conf
@@ -0,0 +1,63 @@
+[system]
+type=system
+timer_t1=100
+timer_b=6400
+
+;--
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+Non mapped elements start
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+
+[general]
+sipdebug = yes
+
+[PEER_A]
+port = 5061
+
+[sbc]
+port = 5700
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+Non mapped elements end
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+--;
+
+
+[global]
+type = global
+debug = yes
+use_callerid_contact = yes
+
+[transport-udp]
+type = transport
+protocol = udp
+bind = 0.0.0.0:5060
+
+[PEER_A]
+type = aor
+contact = sip:127.0.0.1:5061
+
+[PEER_A]
+type = identify
+endpoint = PEER_A
+match = 127.0.0.1
+
+[PEER_A]
+type = endpoint
+context = default
+allow = ulaw
+direct_media = no
+aors = PEER_A
+
+[sbc]
+type = aor
+contact = sip:127.0.0.1:5700
+
+[sbc]
+type = endpoint
+context = callcontrol
+allow = ulaw
+direct_media = no
+aors = sbc
+contact_user = forced
+
diff --git a/tests/channels/pjsip/use_callerid_contact/no_privacy/contact_user/sipp/A_PARTY.xml b/tests/channels/pjsip/use_callerid_contact/no_privacy/contact_user/sipp/A_PARTY.xml
new file mode 100644
index 0000000..9c092b1
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/no_privacy/contact_user/sipp/A_PARTY.xml
@@ -0,0 +1,104 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!DOCTYPE scenario SYSTEM "sipp.dtd">
+<!-- This program is free software; you can redistribute it and/or      -->
+<!-- modify it under the terms of the GNU General Public License as     -->
+<!-- published by the Free Software Foundation; either version 2 of the -->
+<!-- License, or (at your option) any later version.                    -->
+<!--                                                                    -->
+<!-- This program is distributed in the hope that it will be useful,    -->
+<!-- but WITHOUT ANY WARRANTY; without even the implied warranty of     -->
+<!-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the      -->
+<!-- GNU General Public License for more details.                       -->
+<!--                                                                    -->
+<!-- You should have received a copy of the GNU General Public License  -->
+<!-- along with this program; if not, write to the                      -->
+<!-- Free Software Foundation, Inc.,                                    -->
+<!-- 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA             -->
+<!--                                                                    -->
+<!--                 Sipp 'uac' scenario with pcap (rtp) play           -->
+<!--                                                                    -->
+<scenario name="CONTENT_TYPE_PARAMS">
+  <!-- In client mode (sipp placing calls), the Call-ID MUST be         -->
+  <!-- generated by sipp. To do so, use [call_id] keyword.                -->
+  <send retrans="500">
+    <![CDATA[
+
+      INVITE sip:[service]@voxbone.com SIP/2.0
+      Via: SIP/2.0/[transport] [local_ip]:[local_port];branch=[branch]
+      From: sipp <sip:test at voxbone.com>;tag=[call_number]
+      To: sut <sip:[service]@voxbone.com:[remote_port]>
+      Call-ID: [call_id]
+      CSeq: 1 INVITE
+      Contact: sip:sipp@[local_ip]:[local_port]
+      Max-Forwards: 70
+      Subject: Performance Test
+      Content-Type: application/sdp
+      Content-Length: [len]
+
+      v=0
+      o=user1 53655765 2353687637 IN IP[local_ip_type] [local_ip]
+      s=-
+      c=IN IP[local_ip_type] [local_ip]
+      t=0 0
+      m=audio 9000 RTP/AVP 0
+      a=rtpmap:0 PCMU/8000
+
+    ]]>
+  </send>
+
+  <recv response="100" optional="true">
+  </recv>
+
+  <recv response="180" optional="true">
+  </recv>
+
+  <!-- By adding rrs="true" (Record Route Sets), the route sets         -->
+  <!-- are saved and used for following messages sent. Useful to test   -->
+  <!-- against stateful SIP proxies/B2BUAs.                             -->
+  <recv response="200" rtd="true" crlf="true">
+  </recv>
+
+  <!-- Packet lost can be simulated in any send/recv message by         -->
+  <!-- by adding the 'lost = "10"'. Value can be [1-100] percent.       -->
+  <send>
+    <![CDATA[
+
+      ACK sip:[service]@voxbone.com SIP/2.0
+      Via: SIP/2.0/[transport] [local_ip]:[local_port];branch=[branch]
+      From: sipp <sip:test@[local_ip]:[local_port]>;tag=[call_number]
+      To: sut <sip:[service]@voxbone.com>[peer_tag_param]
+      Call-ID: [call_id]
+      CSeq: 1 ACK
+      Contact: sip:sipp@[local_ip]:[local_port]
+      Max-Forwards: 70
+      Subject: Performance Test
+      Content-Length: 0
+
+    ]]>
+  </send>
+
+  <pause milliseconds="1000"/>
+  <!-- The 'crlf' option inserts a blank line in the statistics report. -->
+  <send retrans="500">
+    <![CDATA[
+
+      BYE sip:[service]@voxbone.com SIP/2.0
+      Via: SIP/2.0/[transport] [local_ip]:[local_port];branch=[branch]
+      From: sipp <sip:test@[local_ip]:[local_port]>;tag=[call_number]
+      To: sut <sip:[service]@voxbone.com>[peer_tag_param]
+      Call-ID: [call_id]
+      CSeq: 2 BYE
+      Contact: sip:sipp@[local_ip]:[local_port]
+      Max-Forwards: 70
+      Subject: Performance Test
+      Content-Length: 0
+
+    ]]>
+  </send>
+
+  <recv response="200" crlf="true">
+  </recv>
+
+</scenario>
+
+
diff --git a/tests/channels/pjsip/use_callerid_contact/no_privacy/contact_user/sipp/B_PARTY.xml b/tests/channels/pjsip/use_callerid_contact/no_privacy/contact_user/sipp/B_PARTY.xml
new file mode 100644
index 0000000..da341d1
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/no_privacy/contact_user/sipp/B_PARTY.xml
@@ -0,0 +1,88 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!DOCTYPE scenario SYSTEM "sipp.dtd">
+
+<scenario name="CONTENT_TYPE_PARAMS">
+
+<User variables="dummy" />
+<recv request="INVITE" crlf="true" rrs="true">
+  <action>
+        <ereg regexp=".*sip:forced at .*" search_in="hdr" header="Contact:" check_it="true" assign_to="dummy" />
+  </action>
+</recv>
+<Reference variables="dummy" />
+
+
+
+<send>
+<![CDATA[
+
+SIP/2.0 100 Trying
+[last_Via:]
+[last_Call-ID:]
+[last_From:]
+[last_To:]
+[last_CSeq:]
+Content-Length: 0
+
+]]>
+</send>
+
+<send>
+<![CDATA[
+
+SIP/2.0 180 Ringing
+[last_Via:]
+[last_Call-ID:]
+[last_From:]
+[last_To:]
+[last_CSeq:]
+Content-Length: 0
+
+]]>
+</send>
+
+<send retrans="500">
+<![CDATA[
+
+SIP/2.0 200 OK
+[last_Via:]
+[last_Call-ID:]
+[last_From:]
+[last_To:];tag=[call_number]
+[last_CSeq:]
+Contact: <sip:736596371553211257@[local_ip]:[local_port];user=phone>
+Content-Type: application/sdp
+Content-Length: [len]
+
+v=0
+o=HuaweiSoftX3000 6644052 6644052 IN IP[local_ip_type] [local_ip]
+s=Sip Call
+c=IN IP[local_ip_type] [local_ip]
+t=0 0
+m=audio 8000 RTP/AVP 0
+a=rtpmap:0 PCMU/8000
+
+]]>
+</send>
+
+
+<recv request="ACK" rtd="true" crlf="true">
+</recv>
+
+<recv request="BYE">
+</recv>
+
+<send>
+<![CDATA[
+
+SIP/2.0 200 OK
+[last_Via:]
+[last_From:]
+[last_To:]
+[last_Call-ID:]
+[last_CSeq:]
+Content-Length: 0
+
+]]>
+</send>
+</scenario>
diff --git a/tests/channels/pjsip/use_callerid_contact/no_privacy/contact_user/test-config.yaml b/tests/channels/pjsip/use_callerid_contact/no_privacy/contact_user/test-config.yaml
new file mode 100644
index 0000000..d64b0c1
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/no_privacy/contact_user/test-config.yaml
@@ -0,0 +1,29 @@
+testinfo:
+    summary: 'Test that Asterisk contact_user has priority over use_callerid_contact'
+    description: |
+         'Asterisk is configured with use_callerid_contact enabled, however the 
+          endpoint explicitly defines a contact_user.  Verify the contact_user
+          is sent instead of the callerid'
+
+test-modules:
+    test-object:
+        config-section: test-object-config
+        typename: 'sipp.SIPpTestCase'
+
+test-object-config:
+    memcheck-delay-stop: 7
+    fail-on-any: True
+    test-iterations:
+        -
+            scenarios:
+                - { 'key-args': {'scenario': 'A_PARTY.xml', '-i': '127.0.0.1', '-p': '5061', '-s': '3200000000'} }
+                - { 'key-args': {'scenario': 'B_PARTY.xml', '-i': '127.0.0.1', '-p': '5700'} }
+
+
+properties:
+    dependencies:
+        - sipp :
+             version : 'v3.0'
+        - asterisk : 'res_pjsip'
+    tags:
+        - pjsip
diff --git a/tests/channels/pjsip/use_callerid_contact/no_privacy/tests.yaml b/tests/channels/pjsip/use_callerid_contact/no_privacy/tests.yaml
new file mode 100644
index 0000000..3a50d8b
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/no_privacy/tests.yaml
@@ -0,0 +1,4 @@
+tests:
+    - test: 'use_caller_contact_enabled'
+    - test: 'use_caller_contact_disabled'
+    - test: 'contact_user'
diff --git a/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_disabled/configs/ast1/extensions.conf b/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_disabled/configs/ast1/extensions.conf
new file mode 100644
index 0000000..ad7b155
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_disabled/configs/ast1/extensions.conf
@@ -0,0 +1,11 @@
+[general]
+static=yes
+writeprotect=yes
+autofallthrough=yes
+clearglobalvars=no
+priorityjumping=yes
+
+[globals]
+
+[default]
+exten => _X.,1,Dial(pjsip/sbc,180)
diff --git a/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_disabled/configs/ast1/pjsip.conf b/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_disabled/configs/ast1/pjsip.conf
new file mode 100644
index 0000000..b8d0dce
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_disabled/configs/ast1/pjsip.conf
@@ -0,0 +1,62 @@
+[system]
+type=system
+timer_t1=100
+timer_b=6400
+
+
+;--
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+Non mapped elements start
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+
+[general]
+sipdebug = yes
+
+[PEER_A]
+port = 5061
+
+[sbc]
+port = 5700
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+Non mapped elements end
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+--;
+
+
+[global]
+type = global
+debug = yes
+
+[transport-udp]
+type = transport
+protocol = udp
+bind = 0.0.0.0:5060
+
+[PEER_A]
+type = aor
+contact = sip:127.0.0.1:5061
+
+[PEER_A]
+type = identify
+endpoint = PEER_A
+match = 127.0.0.1
+
+[PEER_A]
+type = endpoint
+context = default
+allow = ulaw
+direct_media = no
+aors = PEER_A
+
+[sbc]
+type = aor
+contact = sip:127.0.0.1:5700
+
+[sbc]
+type = endpoint
+context = callcontrol
+allow = ulaw
+direct_media = no
+aors = sbc
+
diff --git a/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_disabled/sipp/A_PARTY.xml b/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_disabled/sipp/A_PARTY.xml
new file mode 100644
index 0000000..9c092b1
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_disabled/sipp/A_PARTY.xml
@@ -0,0 +1,104 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!DOCTYPE scenario SYSTEM "sipp.dtd">
+<!-- This program is free software; you can redistribute it and/or      -->
+<!-- modify it under the terms of the GNU General Public License as     -->
+<!-- published by the Free Software Foundation; either version 2 of the -->
+<!-- License, or (at your option) any later version.                    -->
+<!--                                                                    -->
+<!-- This program is distributed in the hope that it will be useful,    -->
+<!-- but WITHOUT ANY WARRANTY; without even the implied warranty of     -->
+<!-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the      -->
+<!-- GNU General Public License for more details.                       -->
+<!--                                                                    -->
+<!-- You should have received a copy of the GNU General Public License  -->
+<!-- along with this program; if not, write to the                      -->
+<!-- Free Software Foundation, Inc.,                                    -->
+<!-- 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA             -->
+<!--                                                                    -->
+<!--                 Sipp 'uac' scenario with pcap (rtp) play           -->
+<!--                                                                    -->
+<scenario name="CONTENT_TYPE_PARAMS">
+  <!-- In client mode (sipp placing calls), the Call-ID MUST be         -->
+  <!-- generated by sipp. To do so, use [call_id] keyword.                -->
+  <send retrans="500">
+    <![CDATA[
+
+      INVITE sip:[service]@voxbone.com SIP/2.0
+      Via: SIP/2.0/[transport] [local_ip]:[local_port];branch=[branch]
+      From: sipp <sip:test at voxbone.com>;tag=[call_number]
+      To: sut <sip:[service]@voxbone.com:[remote_port]>
+      Call-ID: [call_id]
+      CSeq: 1 INVITE
+      Contact: sip:sipp@[local_ip]:[local_port]
+      Max-Forwards: 70
+      Subject: Performance Test
+      Content-Type: application/sdp
+      Content-Length: [len]
+
+      v=0
+      o=user1 53655765 2353687637 IN IP[local_ip_type] [local_ip]
+      s=-
+      c=IN IP[local_ip_type] [local_ip]
+      t=0 0
+      m=audio 9000 RTP/AVP 0
+      a=rtpmap:0 PCMU/8000
+
+    ]]>
+  </send>
+
+  <recv response="100" optional="true">
+  </recv>
+
+  <recv response="180" optional="true">
+  </recv>
+
+  <!-- By adding rrs="true" (Record Route Sets), the route sets         -->
+  <!-- are saved and used for following messages sent. Useful to test   -->
+  <!-- against stateful SIP proxies/B2BUAs.                             -->
+  <recv response="200" rtd="true" crlf="true">
+  </recv>
+
+  <!-- Packet lost can be simulated in any send/recv message by         -->
+  <!-- by adding the 'lost = "10"'. Value can be [1-100] percent.       -->
+  <send>
+    <![CDATA[
+
+      ACK sip:[service]@voxbone.com SIP/2.0
+      Via: SIP/2.0/[transport] [local_ip]:[local_port];branch=[branch]
+      From: sipp <sip:test@[local_ip]:[local_port]>;tag=[call_number]
+      To: sut <sip:[service]@voxbone.com>[peer_tag_param]
+      Call-ID: [call_id]
+      CSeq: 1 ACK
+      Contact: sip:sipp@[local_ip]:[local_port]
+      Max-Forwards: 70
+      Subject: Performance Test
+      Content-Length: 0
+
+    ]]>
+  </send>
+
+  <pause milliseconds="1000"/>
+  <!-- The 'crlf' option inserts a blank line in the statistics report. -->
+  <send retrans="500">
+    <![CDATA[
+
+      BYE sip:[service]@voxbone.com SIP/2.0
+      Via: SIP/2.0/[transport] [local_ip]:[local_port];branch=[branch]
+      From: sipp <sip:test@[local_ip]:[local_port]>;tag=[call_number]
+      To: sut <sip:[service]@voxbone.com>[peer_tag_param]
+      Call-ID: [call_id]
+      CSeq: 2 BYE
+      Contact: sip:sipp@[local_ip]:[local_port]
+      Max-Forwards: 70
+      Subject: Performance Test
+      Content-Length: 0
+
+    ]]>
+  </send>
+
+  <recv response="200" crlf="true">
+  </recv>
+
+</scenario>
+
+
diff --git a/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_disabled/sipp/B_PARTY.xml b/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_disabled/sipp/B_PARTY.xml
new file mode 100644
index 0000000..da0e0f1
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_disabled/sipp/B_PARTY.xml
@@ -0,0 +1,88 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!DOCTYPE scenario SYSTEM "sipp.dtd">
+
+<scenario name="CONTENT_TYPE_PARAMS">
+
+<User variables="dummy" />
+<recv request="INVITE" crlf="true" rrs="true">
+  <action>
+        <ereg regexp=".*sip:asterisk at .*" search_in="hdr" header="Contact:" check_it="true" assign_to="dummy" />
+  </action>
+</recv>
+<Reference variables="dummy" />
+
+
+
+<send>
+<![CDATA[
+
+SIP/2.0 100 Trying
+[last_Via:]
+[last_Call-ID:]
+[last_From:]
+[last_To:]
+[last_CSeq:]
+Content-Length: 0
+
+]]>
+</send>
+
+<send>
+<![CDATA[
+
+SIP/2.0 180 Ringing
+[last_Via:]
+[last_Call-ID:]
+[last_From:]
+[last_To:]
+[last_CSeq:]
+Content-Length: 0
+
+]]>
+</send>
+
+<send retrans="500">
+<![CDATA[
+
+SIP/2.0 200 OK
+[last_Via:]
+[last_Call-ID:]
+[last_From:]
+[last_To:];tag=[call_number]
+[last_CSeq:]
+Contact: <sip:736596371553211257@[local_ip]:[local_port];user=phone>
+Content-Type: application/sdp
+Content-Length: [len]
+
+v=0
+o=HuaweiSoftX3000 6644052 6644052 IN IP[local_ip_type] [local_ip]
+s=Sip Call
+c=IN IP[local_ip_type] [local_ip]
+t=0 0
+m=audio 8000 RTP/AVP 0
+a=rtpmap:0 PCMU/8000
+
+]]>
+</send>
+
+
+<recv request="ACK" rtd="true" crlf="true">
+</recv>
+
+<recv request="BYE">
+</recv>
+
+<send>
+<![CDATA[
+
+SIP/2.0 200 OK
+[last_Via:]
+[last_From:]
+[last_To:]
+[last_Call-ID:]
+[last_CSeq:]
+Content-Length: 0
+
+]]>
+</send>
+</scenario>
diff --git a/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_disabled/test-config.yaml b/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_disabled/test-config.yaml
new file mode 100644
index 0000000..5b4766f
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_disabled/test-config.yaml
@@ -0,0 +1,28 @@
+testinfo:
+    summary: 'Test that Asterisk puts default_from_user in contact by default'
+    description: |
+         'Asterisk is not configured with use_callerid_contact, the forwarded contact header should have
+          "asterisk" in the user part'
+
+test-modules:
+    test-object:
+        config-section: test-object-config
+        typename: 'sipp.SIPpTestCase'
+
+test-object-config:
+    memcheck-delay-stop: 7
+    fail-on-any: True
+    test-iterations:
+        -
+            scenarios:
+                - { 'key-args': {'scenario': 'A_PARTY.xml', '-i': '127.0.0.1', '-p': '5061', '-s': '3200000000'} }
+                - { 'key-args': {'scenario': 'B_PARTY.xml', '-i': '127.0.0.1', '-p': '5700'} }
+
+
+properties:
+    dependencies:
+        - sipp :
+             version : 'v3.0'
+        - asterisk : 'res_pjsip'
+    tags:
+        - pjsip
diff --git a/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_enabled/configs/ast1/extensions.conf b/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_enabled/configs/ast1/extensions.conf
new file mode 100644
index 0000000..ad7b155
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_enabled/configs/ast1/extensions.conf
@@ -0,0 +1,11 @@
+[general]
+static=yes
+writeprotect=yes
+autofallthrough=yes
+clearglobalvars=no
+priorityjumping=yes
+
+[globals]
+
+[default]
+exten => _X.,1,Dial(pjsip/sbc,180)
diff --git a/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_enabled/configs/ast1/pjsip.conf b/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_enabled/configs/ast1/pjsip.conf
new file mode 100644
index 0000000..cbb2fe0
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_enabled/configs/ast1/pjsip.conf
@@ -0,0 +1,63 @@
+[system]
+type=system
+timer_t1=100
+timer_b=6400
+
+
+;--
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+Non mapped elements start
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+
+[general]
+sipdebug = yes
+
+[PEER_A]
+port = 5061
+
+[sbc]
+port = 5700
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+Non mapped elements end
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+--;
+
+
+[global]
+type = global
+debug = yes
+use_callerid_contact = yes
+
+[transport-udp]
+type = transport
+protocol = udp
+bind = 0.0.0.0:5060
+
+[PEER_A]
+type = aor
+contact = sip:127.0.0.1:5061
+
+[PEER_A]
+type = identify
+endpoint = PEER_A
+match = 127.0.0.1
+
+[PEER_A]
+type = endpoint
+context = default
+allow = ulaw
+direct_media = no
+aors = PEER_A
+
+[sbc]
+type = aor
+contact = sip:127.0.0.1:5700
+
+[sbc]
+type = endpoint
+context = callcontrol
+allow = ulaw
+direct_media = no
+aors = sbc
+
diff --git a/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_enabled/sipp/A_PARTY.xml b/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_enabled/sipp/A_PARTY.xml
new file mode 100644
index 0000000..9c092b1
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_enabled/sipp/A_PARTY.xml
@@ -0,0 +1,104 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!DOCTYPE scenario SYSTEM "sipp.dtd">
+<!-- This program is free software; you can redistribute it and/or      -->
+<!-- modify it under the terms of the GNU General Public License as     -->
+<!-- published by the Free Software Foundation; either version 2 of the -->
+<!-- License, or (at your option) any later version.                    -->
+<!--                                                                    -->
+<!-- This program is distributed in the hope that it will be useful,    -->
+<!-- but WITHOUT ANY WARRANTY; without even the implied warranty of     -->
+<!-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the      -->
+<!-- GNU General Public License for more details.                       -->
+<!--                                                                    -->
+<!-- You should have received a copy of the GNU General Public License  -->
+<!-- along with this program; if not, write to the                      -->
+<!-- Free Software Foundation, Inc.,                                    -->
+<!-- 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA             -->
+<!--                                                                    -->
+<!--                 Sipp 'uac' scenario with pcap (rtp) play           -->
+<!--                                                                    -->
+<scenario name="CONTENT_TYPE_PARAMS">
+  <!-- In client mode (sipp placing calls), the Call-ID MUST be         -->
+  <!-- generated by sipp. To do so, use [call_id] keyword.                -->
+  <send retrans="500">
+    <![CDATA[
+
+      INVITE sip:[service]@voxbone.com SIP/2.0
+      Via: SIP/2.0/[transport] [local_ip]:[local_port];branch=[branch]
+      From: sipp <sip:test at voxbone.com>;tag=[call_number]
+      To: sut <sip:[service]@voxbone.com:[remote_port]>
+      Call-ID: [call_id]
+      CSeq: 1 INVITE
+      Contact: sip:sipp@[local_ip]:[local_port]
+      Max-Forwards: 70
+      Subject: Performance Test
+      Content-Type: application/sdp
+      Content-Length: [len]
+
+      v=0
+      o=user1 53655765 2353687637 IN IP[local_ip_type] [local_ip]
+      s=-
+      c=IN IP[local_ip_type] [local_ip]
+      t=0 0
+      m=audio 9000 RTP/AVP 0
+      a=rtpmap:0 PCMU/8000
+
+    ]]>
+  </send>
+
+  <recv response="100" optional="true">
+  </recv>
+
+  <recv response="180" optional="true">
+  </recv>
+
+  <!-- By adding rrs="true" (Record Route Sets), the route sets         -->
+  <!-- are saved and used for following messages sent. Useful to test   -->
+  <!-- against stateful SIP proxies/B2BUAs.                             -->
+  <recv response="200" rtd="true" crlf="true">
+  </recv>
+
+  <!-- Packet lost can be simulated in any send/recv message by         -->
+  <!-- by adding the 'lost = "10"'. Value can be [1-100] percent.       -->
+  <send>
+    <![CDATA[
+
+      ACK sip:[service]@voxbone.com SIP/2.0
+      Via: SIP/2.0/[transport] [local_ip]:[local_port];branch=[branch]
+      From: sipp <sip:test@[local_ip]:[local_port]>;tag=[call_number]
+      To: sut <sip:[service]@voxbone.com>[peer_tag_param]
+      Call-ID: [call_id]
+      CSeq: 1 ACK
+      Contact: sip:sipp@[local_ip]:[local_port]
+      Max-Forwards: 70
+      Subject: Performance Test
+      Content-Length: 0
+
+    ]]>
+  </send>
+
+  <pause milliseconds="1000"/>
+  <!-- The 'crlf' option inserts a blank line in the statistics report. -->
+  <send retrans="500">
+    <![CDATA[
+
+      BYE sip:[service]@voxbone.com SIP/2.0
+      Via: SIP/2.0/[transport] [local_ip]:[local_port];branch=[branch]
+      From: sipp <sip:test@[local_ip]:[local_port]>;tag=[call_number]
+      To: sut <sip:[service]@voxbone.com>[peer_tag_param]
+      Call-ID: [call_id]
+      CSeq: 2 BYE
+      Contact: sip:sipp@[local_ip]:[local_port]
+      Max-Forwards: 70
+      Subject: Performance Test
+      Content-Length: 0
+
+    ]]>
+  </send>
+
+  <recv response="200" crlf="true">
+  </recv>
+
+</scenario>
+
+
diff --git a/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_enabled/sipp/B_PARTY.xml b/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_enabled/sipp/B_PARTY.xml
new file mode 100644
index 0000000..82778c3
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_enabled/sipp/B_PARTY.xml
@@ -0,0 +1,88 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!DOCTYPE scenario SYSTEM "sipp.dtd">
+
+<scenario name="CONTENT_TYPE_PARAMS">
+
+<User variables="dummy" />
+<recv request="INVITE" crlf="true" rrs="true">
+  <action>
+        <ereg regexp=".*sip:test at .*" search_in="hdr" header="Contact:" check_it="true" assign_to="dummy" />
+  </action>
+</recv>
+<Reference variables="dummy" />
+
+
+
+<send>
+<![CDATA[
+
+SIP/2.0 100 Trying
+[last_Via:]
+[last_Call-ID:]
+[last_From:]
+[last_To:]
+[last_CSeq:]
+Content-Length: 0
+
+]]>
+</send>
+
+<send>
+<![CDATA[
+
+SIP/2.0 180 Ringing
+[last_Via:]
+[last_Call-ID:]
+[last_From:]
+[last_To:]
+[last_CSeq:]
+Content-Length: 0
+
+]]>
+</send>
+
+<send retrans="500">
+<![CDATA[
+
+SIP/2.0 200 OK
+[last_Via:]
+[last_Call-ID:]
+[last_From:]
+[last_To:];tag=[call_number]
+[last_CSeq:]
+Contact: <sip:736596371553211257@[local_ip]:[local_port];user=phone>
+Content-Type: application/sdp
+Content-Length: [len]
+
+v=0
+o=HuaweiSoftX3000 6644052 6644052 IN IP[local_ip_type] [local_ip]
+s=Sip Call
+c=IN IP[local_ip_type] [local_ip]
+t=0 0
+m=audio 8000 RTP/AVP 0
+a=rtpmap:0 PCMU/8000
+
+]]>
+</send>
+
+
+<recv request="ACK" rtd="true" crlf="true">
+</recv>
+
+<recv request="BYE">
+</recv>
+
+<send>
+<![CDATA[
+
+SIP/2.0 200 OK
+[last_Via:]
+[last_From:]
+[last_To:]
+[last_Call-ID:]
+[last_CSeq:]
+Content-Length: 0
+
+]]>
+</send>
+</scenario>
diff --git a/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_enabled/test-config.yaml b/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_enabled/test-config.yaml
new file mode 100644
index 0000000..aac3ce9
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/no_privacy/use_caller_contact_enabled/test-config.yaml
@@ -0,0 +1,28 @@
+testinfo:
+    summary: 'Test that Asterisk puts callerid in contact if enabled'
+    description: |
+         'Asterisk is configured with use_callerid_contact enabled, the forwarded contact header should have
+          the caller numer in the user part'
+
+test-modules:
+    test-object:
+        config-section: test-object-config
+        typename: 'sipp.SIPpTestCase'
+
+test-object-config:
+    memcheck-delay-stop: 7
+    fail-on-any: True
+    test-iterations:
+        -
+            scenarios:
+                - { 'key-args': {'scenario': 'A_PARTY.xml', '-i': '127.0.0.1', '-p': '5061', '-s': '3200000000'} }
+                - { 'key-args': {'scenario': 'B_PARTY.xml', '-i': '127.0.0.1', '-p': '5700'} }
+
+
+properties:
+    dependencies:
+        - sipp :
+             version : 'v3.0'
+        - asterisk : 'res_pjsip'
+    tags:
+        - pjsip
diff --git a/tests/channels/pjsip/use_callerid_contact/privacy/contact_user/configs/ast1/extensions.conf b/tests/channels/pjsip/use_callerid_contact/privacy/contact_user/configs/ast1/extensions.conf
new file mode 100644
index 0000000..661d9cb
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/privacy/contact_user/configs/ast1/extensions.conf
@@ -0,0 +1,12 @@
+[general]
+static=yes
+writeprotect=yes
+autofallthrough=yes
+clearglobalvars=no
+priorityjumping=yes
+
+[globals]
+
+[default]
+exten => _X.,1,Set(CALLERID(pres)=prohib)
+exten => _X.,n,Dial(pjsip/sbc,180)
diff --git a/tests/channels/pjsip/use_callerid_contact/privacy/contact_user/configs/ast1/pjsip.conf b/tests/channels/pjsip/use_callerid_contact/privacy/contact_user/configs/ast1/pjsip.conf
new file mode 100644
index 0000000..dc03716
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/privacy/contact_user/configs/ast1/pjsip.conf
@@ -0,0 +1,64 @@
+[system]
+type=system
+timer_t1=100
+timer_b=6400
+
+
+;--
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+Non mapped elements start
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+
+[general]
+sipdebug = yes
+
+[PEER_A]
+port = 5061
+
+[sbc]
+port = 5700
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+Non mapped elements end
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+--;
+
+
+[global]
+type = global
+debug = yes
+use_callerid_contact = yes
+
+[transport-udp]
+type = transport
+protocol = udp
+bind = 0.0.0.0:5060
+
+[PEER_A]
+type = aor
+contact = sip:127.0.0.1:5061
+
+[PEER_A]
+type = identify
+endpoint = PEER_A
+match = 127.0.0.1
+
+[PEER_A]
+type = endpoint
+context = default
+allow = ulaw
+direct_media = no
+aors = PEER_A
+
+[sbc]
+type = aor
+contact = sip:127.0.0.1:5700
+
+[sbc]
+type = endpoint
+context = callcontrol
+allow = ulaw
+direct_media = no
+aors = sbc
+contact_user = forced
+
diff --git a/tests/channels/pjsip/use_callerid_contact/privacy/contact_user/sipp/A_PARTY.xml b/tests/channels/pjsip/use_callerid_contact/privacy/contact_user/sipp/A_PARTY.xml
new file mode 100644
index 0000000..9c092b1
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/privacy/contact_user/sipp/A_PARTY.xml
@@ -0,0 +1,104 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!DOCTYPE scenario SYSTEM "sipp.dtd">
+<!-- This program is free software; you can redistribute it and/or      -->
+<!-- modify it under the terms of the GNU General Public License as     -->
+<!-- published by the Free Software Foundation; either version 2 of the -->
+<!-- License, or (at your option) any later version.                    -->
+<!--                                                                    -->
+<!-- This program is distributed in the hope that it will be useful,    -->
+<!-- but WITHOUT ANY WARRANTY; without even the implied warranty of     -->
+<!-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the      -->
+<!-- GNU General Public License for more details.                       -->
+<!--                                                                    -->
+<!-- You should have received a copy of the GNU General Public License  -->
+<!-- along with this program; if not, write to the                      -->
+<!-- Free Software Foundation, Inc.,                                    -->
+<!-- 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA             -->
+<!--                                                                    -->
+<!--                 Sipp 'uac' scenario with pcap (rtp) play           -->
+<!--                                                                    -->
+<scenario name="CONTENT_TYPE_PARAMS">
+  <!-- In client mode (sipp placing calls), the Call-ID MUST be         -->
+  <!-- generated by sipp. To do so, use [call_id] keyword.                -->
+  <send retrans="500">
+    <![CDATA[
+
+      INVITE sip:[service]@voxbone.com SIP/2.0
+      Via: SIP/2.0/[transport] [local_ip]:[local_port];branch=[branch]
+      From: sipp <sip:test at voxbone.com>;tag=[call_number]
+      To: sut <sip:[service]@voxbone.com:[remote_port]>
+      Call-ID: [call_id]
+      CSeq: 1 INVITE
+      Contact: sip:sipp@[local_ip]:[local_port]
+      Max-Forwards: 70
+      Subject: Performance Test
+      Content-Type: application/sdp
+      Content-Length: [len]
+
+      v=0
+      o=user1 53655765 2353687637 IN IP[local_ip_type] [local_ip]
+      s=-
+      c=IN IP[local_ip_type] [local_ip]
+      t=0 0
+      m=audio 9000 RTP/AVP 0
+      a=rtpmap:0 PCMU/8000
+
+    ]]>
+  </send>
+
+  <recv response="100" optional="true">
+  </recv>
+
+  <recv response="180" optional="true">
+  </recv>
+
+  <!-- By adding rrs="true" (Record Route Sets), the route sets         -->
+  <!-- are saved and used for following messages sent. Useful to test   -->
+  <!-- against stateful SIP proxies/B2BUAs.                             -->
+  <recv response="200" rtd="true" crlf="true">
+  </recv>
+
+  <!-- Packet lost can be simulated in any send/recv message by         -->
+  <!-- by adding the 'lost = "10"'. Value can be [1-100] percent.       -->
+  <send>
+    <![CDATA[
+
+      ACK sip:[service]@voxbone.com SIP/2.0
+      Via: SIP/2.0/[transport] [local_ip]:[local_port];branch=[branch]
+      From: sipp <sip:test@[local_ip]:[local_port]>;tag=[call_number]
+      To: sut <sip:[service]@voxbone.com>[peer_tag_param]
+      Call-ID: [call_id]
+      CSeq: 1 ACK
+      Contact: sip:sipp@[local_ip]:[local_port]
+      Max-Forwards: 70
+      Subject: Performance Test
+      Content-Length: 0
+
+    ]]>
+  </send>
+
+  <pause milliseconds="1000"/>
+  <!-- The 'crlf' option inserts a blank line in the statistics report. -->
+  <send retrans="500">
+    <![CDATA[
+
+      BYE sip:[service]@voxbone.com SIP/2.0
+      Via: SIP/2.0/[transport] [local_ip]:[local_port];branch=[branch]
+      From: sipp <sip:test@[local_ip]:[local_port]>;tag=[call_number]
+      To: sut <sip:[service]@voxbone.com>[peer_tag_param]
+      Call-ID: [call_id]
+      CSeq: 2 BYE
+      Contact: sip:sipp@[local_ip]:[local_port]
+      Max-Forwards: 70
+      Subject: Performance Test
+      Content-Length: 0
+
+    ]]>
+  </send>
+
+  <recv response="200" crlf="true">
+  </recv>
+
+</scenario>
+
+
diff --git a/tests/channels/pjsip/use_callerid_contact/privacy/contact_user/sipp/B_PARTY.xml b/tests/channels/pjsip/use_callerid_contact/privacy/contact_user/sipp/B_PARTY.xml
new file mode 100644
index 0000000..da341d1
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/privacy/contact_user/sipp/B_PARTY.xml
@@ -0,0 +1,88 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!DOCTYPE scenario SYSTEM "sipp.dtd">
+
+<scenario name="CONTENT_TYPE_PARAMS">
+
+<User variables="dummy" />
+<recv request="INVITE" crlf="true" rrs="true">
+  <action>
+        <ereg regexp=".*sip:forced at .*" search_in="hdr" header="Contact:" check_it="true" assign_to="dummy" />
+  </action>
+</recv>
+<Reference variables="dummy" />
+
+
+
+<send>
+<![CDATA[
+
+SIP/2.0 100 Trying
+[last_Via:]
+[last_Call-ID:]
+[last_From:]
+[last_To:]
+[last_CSeq:]
+Content-Length: 0
+
+]]>
+</send>
+
+<send>
+<![CDATA[
+
+SIP/2.0 180 Ringing
+[last_Via:]
+[last_Call-ID:]
+[last_From:]
+[last_To:]
+[last_CSeq:]
+Content-Length: 0
+
+]]>
+</send>
+
+<send retrans="500">
+<![CDATA[
+
+SIP/2.0 200 OK
+[last_Via:]
+[last_Call-ID:]
+[last_From:]
+[last_To:];tag=[call_number]
+[last_CSeq:]
+Contact: <sip:736596371553211257@[local_ip]:[local_port];user=phone>
+Content-Type: application/sdp
+Content-Length: [len]
+
+v=0
+o=HuaweiSoftX3000 6644052 6644052 IN IP[local_ip_type] [local_ip]
+s=Sip Call
+c=IN IP[local_ip_type] [local_ip]
+t=0 0
+m=audio 8000 RTP/AVP 0
+a=rtpmap:0 PCMU/8000
+
+]]>
+</send>
+
+
+<recv request="ACK" rtd="true" crlf="true">
+</recv>
+
+<recv request="BYE">
+</recv>
+
+<send>
+<![CDATA[
+
+SIP/2.0 200 OK
+[last_Via:]
+[last_From:]
+[last_To:]
+[last_Call-ID:]
+[last_CSeq:]
+Content-Length: 0
+
+]]>
+</send>
+</scenario>
diff --git a/tests/channels/pjsip/use_callerid_contact/privacy/contact_user/test-config.yaml b/tests/channels/pjsip/use_callerid_contact/privacy/contact_user/test-config.yaml
new file mode 100644
index 0000000..d64b0c1
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/privacy/contact_user/test-config.yaml
@@ -0,0 +1,29 @@
+testinfo:
+    summary: 'Test that Asterisk contact_user has priority over use_callerid_contact'
+    description: |
+         'Asterisk is configured with use_callerid_contact enabled, however the 
+          endpoint explicitly defines a contact_user.  Verify the contact_user
+          is sent instead of the callerid'
+
+test-modules:
+    test-object:
+        config-section: test-object-config
+        typename: 'sipp.SIPpTestCase'
+
+test-object-config:
+    memcheck-delay-stop: 7
+    fail-on-any: True
+    test-iterations:
+        -
+            scenarios:
+                - { 'key-args': {'scenario': 'A_PARTY.xml', '-i': '127.0.0.1', '-p': '5061', '-s': '3200000000'} }
+                - { 'key-args': {'scenario': 'B_PARTY.xml', '-i': '127.0.0.1', '-p': '5700'} }
+
+
+properties:
+    dependencies:
+        - sipp :
+             version : 'v3.0'
+        - asterisk : 'res_pjsip'
+    tags:
+        - pjsip
diff --git a/tests/channels/pjsip/use_callerid_contact/privacy/tests.yaml b/tests/channels/pjsip/use_callerid_contact/privacy/tests.yaml
new file mode 100644
index 0000000..3a50d8b
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/privacy/tests.yaml
@@ -0,0 +1,4 @@
+tests:
+    - test: 'use_caller_contact_enabled'
+    - test: 'use_caller_contact_disabled'
+    - test: 'contact_user'
diff --git a/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_disabled/configs/ast1/extensions.conf b/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_disabled/configs/ast1/extensions.conf
new file mode 100644
index 0000000..661d9cb
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_disabled/configs/ast1/extensions.conf
@@ -0,0 +1,12 @@
+[general]
+static=yes
+writeprotect=yes
+autofallthrough=yes
+clearglobalvars=no
+priorityjumping=yes
+
+[globals]
+
+[default]
+exten => _X.,1,Set(CALLERID(pres)=prohib)
+exten => _X.,n,Dial(pjsip/sbc,180)
diff --git a/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_disabled/configs/ast1/pjsip.conf b/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_disabled/configs/ast1/pjsip.conf
new file mode 100644
index 0000000..b8d0dce
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_disabled/configs/ast1/pjsip.conf
@@ -0,0 +1,62 @@
+[system]
+type=system
+timer_t1=100
+timer_b=6400
+
+
+;--
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+Non mapped elements start
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+
+[general]
+sipdebug = yes
+
+[PEER_A]
+port = 5061
+
+[sbc]
+port = 5700
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+Non mapped elements end
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+--;
+
+
+[global]
+type = global
+debug = yes
+
+[transport-udp]
+type = transport
+protocol = udp
+bind = 0.0.0.0:5060
+
+[PEER_A]
+type = aor
+contact = sip:127.0.0.1:5061
+
+[PEER_A]
+type = identify
+endpoint = PEER_A
+match = 127.0.0.1
+
+[PEER_A]
+type = endpoint
+context = default
+allow = ulaw
+direct_media = no
+aors = PEER_A
+
+[sbc]
+type = aor
+contact = sip:127.0.0.1:5700
+
+[sbc]
+type = endpoint
+context = callcontrol
+allow = ulaw
+direct_media = no
+aors = sbc
+
diff --git a/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_disabled/sipp/A_PARTY.xml b/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_disabled/sipp/A_PARTY.xml
new file mode 100644
index 0000000..9c092b1
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_disabled/sipp/A_PARTY.xml
@@ -0,0 +1,104 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!DOCTYPE scenario SYSTEM "sipp.dtd">
+<!-- This program is free software; you can redistribute it and/or      -->
+<!-- modify it under the terms of the GNU General Public License as     -->
+<!-- published by the Free Software Foundation; either version 2 of the -->
+<!-- License, or (at your option) any later version.                    -->
+<!--                                                                    -->
+<!-- This program is distributed in the hope that it will be useful,    -->
+<!-- but WITHOUT ANY WARRANTY; without even the implied warranty of     -->
+<!-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the      -->
+<!-- GNU General Public License for more details.                       -->
+<!--                                                                    -->
+<!-- You should have received a copy of the GNU General Public License  -->
+<!-- along with this program; if not, write to the                      -->
+<!-- Free Software Foundation, Inc.,                                    -->
+<!-- 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA             -->
+<!--                                                                    -->
+<!--                 Sipp 'uac' scenario with pcap (rtp) play           -->
+<!--                                                                    -->
+<scenario name="CONTENT_TYPE_PARAMS">
+  <!-- In client mode (sipp placing calls), the Call-ID MUST be         -->
+  <!-- generated by sipp. To do so, use [call_id] keyword.                -->
+  <send retrans="500">
+    <![CDATA[
+
+      INVITE sip:[service]@voxbone.com SIP/2.0
+      Via: SIP/2.0/[transport] [local_ip]:[local_port];branch=[branch]
+      From: sipp <sip:test at voxbone.com>;tag=[call_number]
+      To: sut <sip:[service]@voxbone.com:[remote_port]>
+      Call-ID: [call_id]
+      CSeq: 1 INVITE
+      Contact: sip:sipp@[local_ip]:[local_port]
+      Max-Forwards: 70
+      Subject: Performance Test
+      Content-Type: application/sdp
+      Content-Length: [len]
+
+      v=0
+      o=user1 53655765 2353687637 IN IP[local_ip_type] [local_ip]
+      s=-
+      c=IN IP[local_ip_type] [local_ip]
+      t=0 0
+      m=audio 9000 RTP/AVP 0
+      a=rtpmap:0 PCMU/8000
+
+    ]]>
+  </send>
+
+  <recv response="100" optional="true">
+  </recv>
+
+  <recv response="180" optional="true">
+  </recv>
+
+  <!-- By adding rrs="true" (Record Route Sets), the route sets         -->
+  <!-- are saved and used for following messages sent. Useful to test   -->
+  <!-- against stateful SIP proxies/B2BUAs.                             -->
+  <recv response="200" rtd="true" crlf="true">
+  </recv>
+
+  <!-- Packet lost can be simulated in any send/recv message by         -->
+  <!-- by adding the 'lost = "10"'. Value can be [1-100] percent.       -->
+  <send>
+    <![CDATA[
+
+      ACK sip:[service]@voxbone.com SIP/2.0
+      Via: SIP/2.0/[transport] [local_ip]:[local_port];branch=[branch]
+      From: sipp <sip:test@[local_ip]:[local_port]>;tag=[call_number]
+      To: sut <sip:[service]@voxbone.com>[peer_tag_param]
+      Call-ID: [call_id]
+      CSeq: 1 ACK
+      Contact: sip:sipp@[local_ip]:[local_port]
+      Max-Forwards: 70
+      Subject: Performance Test
+      Content-Length: 0
+
+    ]]>
+  </send>
+
+  <pause milliseconds="1000"/>
+  <!-- The 'crlf' option inserts a blank line in the statistics report. -->
+  <send retrans="500">
+    <![CDATA[
+
+      BYE sip:[service]@voxbone.com SIP/2.0
+      Via: SIP/2.0/[transport] [local_ip]:[local_port];branch=[branch]
+      From: sipp <sip:test@[local_ip]:[local_port]>;tag=[call_number]
+      To: sut <sip:[service]@voxbone.com>[peer_tag_param]
+      Call-ID: [call_id]
+      CSeq: 2 BYE
+      Contact: sip:sipp@[local_ip]:[local_port]
+      Max-Forwards: 70
+      Subject: Performance Test
+      Content-Length: 0
+
+    ]]>
+  </send>
+
+  <recv response="200" crlf="true">
+  </recv>
+
+</scenario>
+
+
diff --git a/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_disabled/sipp/B_PARTY.xml b/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_disabled/sipp/B_PARTY.xml
new file mode 100644
index 0000000..da0e0f1
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_disabled/sipp/B_PARTY.xml
@@ -0,0 +1,88 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!DOCTYPE scenario SYSTEM "sipp.dtd">
+
+<scenario name="CONTENT_TYPE_PARAMS">
+
+<User variables="dummy" />
+<recv request="INVITE" crlf="true" rrs="true">
+  <action>
+        <ereg regexp=".*sip:asterisk at .*" search_in="hdr" header="Contact:" check_it="true" assign_to="dummy" />
+  </action>
+</recv>
+<Reference variables="dummy" />
+
+
+
+<send>
+<![CDATA[
+
+SIP/2.0 100 Trying
+[last_Via:]
+[last_Call-ID:]
+[last_From:]
+[last_To:]
+[last_CSeq:]
+Content-Length: 0
+
+]]>
+</send>
+
+<send>
+<![CDATA[
+
+SIP/2.0 180 Ringing
+[last_Via:]
+[last_Call-ID:]
+[last_From:]
+[last_To:]
+[last_CSeq:]
+Content-Length: 0
+
+]]>
+</send>
+
+<send retrans="500">
+<![CDATA[
+
+SIP/2.0 200 OK
+[last_Via:]
+[last_Call-ID:]
+[last_From:]
+[last_To:];tag=[call_number]
+[last_CSeq:]
+Contact: <sip:736596371553211257@[local_ip]:[local_port];user=phone>
+Content-Type: application/sdp
+Content-Length: [len]
+
+v=0
+o=HuaweiSoftX3000 6644052 6644052 IN IP[local_ip_type] [local_ip]
+s=Sip Call
+c=IN IP[local_ip_type] [local_ip]
+t=0 0
+m=audio 8000 RTP/AVP 0
+a=rtpmap:0 PCMU/8000
+
+]]>
+</send>
+
+
+<recv request="ACK" rtd="true" crlf="true">
+</recv>
+
+<recv request="BYE">
+</recv>
+
+<send>
+<![CDATA[
+
+SIP/2.0 200 OK
+[last_Via:]
+[last_From:]
+[last_To:]
+[last_Call-ID:]
+[last_CSeq:]
+Content-Length: 0
+
+]]>
+</send>
+</scenario>
diff --git a/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_disabled/test-config.yaml b/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_disabled/test-config.yaml
new file mode 100644
index 0000000..5b4766f
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_disabled/test-config.yaml
@@ -0,0 +1,28 @@
+testinfo:
+    summary: 'Test that Asterisk puts default_from_user in contact by default'
+    description: |
+         'Asterisk is not configured with use_callerid_contact, the forwarded contact header should have
+          "asterisk" in the user part'
+
+test-modules:
+    test-object:
+        config-section: test-object-config
+        typename: 'sipp.SIPpTestCase'
+
+test-object-config:
+    memcheck-delay-stop: 7
+    fail-on-any: True
+    test-iterations:
+        -
+            scenarios:
+                - { 'key-args': {'scenario': 'A_PARTY.xml', '-i': '127.0.0.1', '-p': '5061', '-s': '3200000000'} }
+                - { 'key-args': {'scenario': 'B_PARTY.xml', '-i': '127.0.0.1', '-p': '5700'} }
+
+
+properties:
+    dependencies:
+        - sipp :
+             version : 'v3.0'
+        - asterisk : 'res_pjsip'
+    tags:
+        - pjsip
diff --git a/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_enabled/configs/ast1/extensions.conf b/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_enabled/configs/ast1/extensions.conf
new file mode 100644
index 0000000..661d9cb
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_enabled/configs/ast1/extensions.conf
@@ -0,0 +1,12 @@
+[general]
+static=yes
+writeprotect=yes
+autofallthrough=yes
+clearglobalvars=no
+priorityjumping=yes
+
+[globals]
+
+[default]
+exten => _X.,1,Set(CALLERID(pres)=prohib)
+exten => _X.,n,Dial(pjsip/sbc,180)
diff --git a/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_enabled/configs/ast1/pjsip.conf b/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_enabled/configs/ast1/pjsip.conf
new file mode 100644
index 0000000..c52860a
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_enabled/configs/ast1/pjsip.conf
@@ -0,0 +1,62 @@
+[system]
+type=system
+timer_t1=100
+timer_b=6400
+
+;--
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+Non mapped elements start
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+
+[general]
+sipdebug = yes
+
+[PEER_A]
+port = 5061
+
+[sbc]
+port = 5700
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+Non mapped elements end
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+--;
+
+
+[global]
+type = global
+debug = yes
+use_callerid_contact = yes
+
+[transport-udp]
+type = transport
+protocol = udp
+bind = 0.0.0.0:5060
+
+[PEER_A]
+type = aor
+contact = sip:127.0.0.1:5061
+
+[PEER_A]
+type = identify
+endpoint = PEER_A
+match = 127.0.0.1
+
+[PEER_A]
+type = endpoint
+context = default
+allow = ulaw
+direct_media = no
+aors = PEER_A
+
+[sbc]
+type = aor
+contact = sip:127.0.0.1:5700
+
+[sbc]
+type = endpoint
+context = callcontrol
+allow = ulaw
+direct_media = no
+aors = sbc
+
diff --git a/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_enabled/sipp/A_PARTY.xml b/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_enabled/sipp/A_PARTY.xml
new file mode 100644
index 0000000..9c092b1
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_enabled/sipp/A_PARTY.xml
@@ -0,0 +1,104 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!DOCTYPE scenario SYSTEM "sipp.dtd">
+<!-- This program is free software; you can redistribute it and/or      -->
+<!-- modify it under the terms of the GNU General Public License as     -->
+<!-- published by the Free Software Foundation; either version 2 of the -->
+<!-- License, or (at your option) any later version.                    -->
+<!--                                                                    -->
+<!-- This program is distributed in the hope that it will be useful,    -->
+<!-- but WITHOUT ANY WARRANTY; without even the implied warranty of     -->
+<!-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the      -->
+<!-- GNU General Public License for more details.                       -->
+<!--                                                                    -->
+<!-- You should have received a copy of the GNU General Public License  -->
+<!-- along with this program; if not, write to the                      -->
+<!-- Free Software Foundation, Inc.,                                    -->
+<!-- 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA             -->
+<!--                                                                    -->
+<!--                 Sipp 'uac' scenario with pcap (rtp) play           -->
+<!--                                                                    -->
+<scenario name="CONTENT_TYPE_PARAMS">
+  <!-- In client mode (sipp placing calls), the Call-ID MUST be         -->
+  <!-- generated by sipp. To do so, use [call_id] keyword.                -->
+  <send retrans="500">
+    <![CDATA[
+
+      INVITE sip:[service]@voxbone.com SIP/2.0
+      Via: SIP/2.0/[transport] [local_ip]:[local_port];branch=[branch]
+      From: sipp <sip:test at voxbone.com>;tag=[call_number]
+      To: sut <sip:[service]@voxbone.com:[remote_port]>
+      Call-ID: [call_id]
+      CSeq: 1 INVITE
+      Contact: sip:sipp@[local_ip]:[local_port]
+      Max-Forwards: 70
+      Subject: Performance Test
+      Content-Type: application/sdp
+      Content-Length: [len]
+
+      v=0
+      o=user1 53655765 2353687637 IN IP[local_ip_type] [local_ip]
+      s=-
+      c=IN IP[local_ip_type] [local_ip]
+      t=0 0
+      m=audio 9000 RTP/AVP 0
+      a=rtpmap:0 PCMU/8000
+
+    ]]>
+  </send>
+
+  <recv response="100" optional="true">
+  </recv>
+
+  <recv response="180" optional="true">
+  </recv>
+
+  <!-- By adding rrs="true" (Record Route Sets), the route sets         -->
+  <!-- are saved and used for following messages sent. Useful to test   -->
+  <!-- against stateful SIP proxies/B2BUAs.                             -->
+  <recv response="200" rtd="true" crlf="true">
+  </recv>
+
+  <!-- Packet lost can be simulated in any send/recv message by         -->
+  <!-- by adding the 'lost = "10"'. Value can be [1-100] percent.       -->
+  <send>
+    <![CDATA[
+
+      ACK sip:[service]@voxbone.com SIP/2.0
+      Via: SIP/2.0/[transport] [local_ip]:[local_port];branch=[branch]
+      From: sipp <sip:test@[local_ip]:[local_port]>;tag=[call_number]
+      To: sut <sip:[service]@voxbone.com>[peer_tag_param]
+      Call-ID: [call_id]
+      CSeq: 1 ACK
+      Contact: sip:sipp@[local_ip]:[local_port]
+      Max-Forwards: 70
+      Subject: Performance Test
+      Content-Length: 0
+
+    ]]>
+  </send>
+
+  <pause milliseconds="1000"/>
+  <!-- The 'crlf' option inserts a blank line in the statistics report. -->
+  <send retrans="500">
+    <![CDATA[
+
+      BYE sip:[service]@voxbone.com SIP/2.0
+      Via: SIP/2.0/[transport] [local_ip]:[local_port];branch=[branch]
+      From: sipp <sip:test@[local_ip]:[local_port]>;tag=[call_number]
+      To: sut <sip:[service]@voxbone.com>[peer_tag_param]
+      Call-ID: [call_id]
+      CSeq: 2 BYE
+      Contact: sip:sipp@[local_ip]:[local_port]
+      Max-Forwards: 70
+      Subject: Performance Test
+      Content-Length: 0
+
+    ]]>
+  </send>
+
+  <recv response="200" crlf="true">
+  </recv>
+
+</scenario>
+
+
diff --git a/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_enabled/sipp/B_PARTY.xml b/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_enabled/sipp/B_PARTY.xml
new file mode 100644
index 0000000..b1ebfde
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_enabled/sipp/B_PARTY.xml
@@ -0,0 +1,88 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!DOCTYPE scenario SYSTEM "sipp.dtd">
+
+<scenario name="CONTENT_TYPE_PARAMS">
+
+<User variables="dummy" />
+<recv request="INVITE" crlf="true" rrs="true">
+  <action>
+        <ereg regexp=".*sip:anonymous at .*" search_in="hdr" header="Contact:" check_it="true" assign_to="dummy" />
+  </action>
+</recv>
+<Reference variables="dummy" />
+
+
+
+<send>
+<![CDATA[
+
+SIP/2.0 100 Trying
+[last_Via:]
+[last_Call-ID:]
+[last_From:]
+[last_To:]
+[last_CSeq:]
+Content-Length: 0
+
+]]>
+</send>
+
+<send>
+<![CDATA[
+
+SIP/2.0 180 Ringing
+[last_Via:]
+[last_Call-ID:]
+[last_From:]
+[last_To:]
+[last_CSeq:]
+Content-Length: 0
+
+]]>
+</send>
+
+<send retrans="500">
+<![CDATA[
+
+SIP/2.0 200 OK
+[last_Via:]
+[last_Call-ID:]
+[last_From:]
+[last_To:];tag=[call_number]
+[last_CSeq:]
+Contact: <sip:736596371553211257@[local_ip]:[local_port];user=phone>
+Content-Type: application/sdp
+Content-Length: [len]
+
+v=0
+o=HuaweiSoftX3000 6644052 6644052 IN IP[local_ip_type] [local_ip]
+s=Sip Call
+c=IN IP[local_ip_type] [local_ip]
+t=0 0
+m=audio 8000 RTP/AVP 0
+a=rtpmap:0 PCMU/8000
+
+]]>
+</send>
+
+
+<recv request="ACK" rtd="true" crlf="true">
+</recv>
+
+<recv request="BYE">
+</recv>
+
+<send>
+<![CDATA[
+
+SIP/2.0 200 OK
+[last_Via:]
+[last_From:]
+[last_To:]
+[last_Call-ID:]
+[last_CSeq:]
+Content-Length: 0
+
+]]>
+</send>
+</scenario>
diff --git a/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_enabled/test-config.yaml b/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_enabled/test-config.yaml
new file mode 100644
index 0000000..d53bc0d
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/privacy/use_caller_contact_enabled/test-config.yaml
@@ -0,0 +1,28 @@
+testinfo:
+    summary: 'Test that Asterisk honors privacy in contact if user_callerid_contact is enabled'
+    description: |
+         'Asterisk is configured with use_callerid_contact enabled, and the caller requests privacy, the forwarded contact header should have
+          anonymous in the user part'
+
+test-modules:
+    test-object:
+        config-section: test-object-config
+        typename: 'sipp.SIPpTestCase'
+
+test-object-config:
+    memcheck-delay-stop: 7
+    fail-on-any: True
+    test-iterations:
+        -
+            scenarios:
+                - { 'key-args': {'scenario': 'A_PARTY.xml', '-i': '127.0.0.1', '-p': '5061', '-s': '3200000000'} }
+                - { 'key-args': {'scenario': 'B_PARTY.xml', '-i': '127.0.0.1', '-p': '5700'} }
+
+
+properties:
+    dependencies:
+        - sipp :
+             version : 'v3.0'
+        - asterisk : 'res_pjsip'
+    tags:
+        - pjsip
diff --git a/tests/channels/pjsip/use_callerid_contact/tests.yaml b/tests/channels/pjsip/use_callerid_contact/tests.yaml
new file mode 100644
index 0000000..7522429
--- /dev/null
+++ b/tests/channels/pjsip/use_callerid_contact/tests.yaml
@@ -0,0 +1,3 @@
+tests:
+    - dir: 'no_privacy'
+    - dir: 'privacy'

-- 
To view, visit https://gerrit.asterisk.org/10502
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings

Gerrit-Project: testsuite
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I168603c8397557316863116edfd0d611e7ed7ef9
Gerrit-Change-Number: 10502
Gerrit-PatchSet: 2
Gerrit-Owner: Torrey Searle <tsearle at gmail.com>
Gerrit-Reviewer: George Joseph <gjoseph at digium.com>
Gerrit-Reviewer: Jenkins2 (1000185)
Gerrit-Reviewer: Joshua Colp <jcolp at digium.com>
Gerrit-Reviewer: Kevin Harwell <kharwell at digium.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20181029/8ede6432/attachment-0001.html>


More information about the asterisk-code-review mailing list