Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Variable substitution ads extra quotes and fails to execute #113

Open
royalpinto opened this issue Dec 22, 2022 · 0 comments
Open

Variable substitution ads extra quotes and fails to execute #113

royalpinto opened this issue Dec 22, 2022 · 0 comments

Comments

@royalpinto
Copy link

The extra quotes added around From and <action> for variables in XML throws syntax error on SIPp
As explained in the SIPp documentation and an example image here, it should have any quotes around the field variables.

Scenario file

source: 192.168.0.1 # Masked
destination: 192.168.0.2:5060 # Masked
max_concurrent: 120
calls_per_second: 2
number_of_calls: 1000
to_user: 2156546
from_user: [field0]
dtmf_mode: 'info'
scenario_variables: variables.csv
steps:
  - invite
  - wait_for_answer
  - ack_answer
  - sleep 10
  - send_digits 3
  - sleep 1000
  - send_bye

Run

sippy_cup -r 1000calls.yml
.
.
2022-12-22	05:17:15.292803	1671686235.292803: Unsupported keyword '"field0"' in xml scenario file
2022-12-22	05:17:15.292803	1671686235.292803: Unsupported keyword '"field0"' in xml scenario fileI, [2022-12-22T05:17:15.294324 #23710] INFO -- : Test completed successfully but some calls failed.

Compile

sippy_cup --compile 1000calls.yml

Extra quotes and &quot; in two sections:

From: "["field0"]" <sip:["field0"]@[local_ip]:[local_port]>;tag=[call_number]
.
.
.
<action>
  <assignstr assign_to="remote_addr" value="[service]@[remote_ip]:[remote_port]"/>
  <assignstr assign_to="local_addr" value="[&quot;field0&quot;]@[local_ip]:[local_port]"/>
  <assignstr assign_to="call_addr" value="[service]@[remote_ip]:[remote_port]"/>
</action>

NOTE: When compiled and manually cleaned up the quotes and given to SIPp, it works perfectly fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant