[asterisk-bugs] [JIRA] (ASTERISK-28445) res_pjsip_session: ast_json_vpack: Invalid UTF-8 string on hangup when TEST_FRAMEWORK enabled

Kevin Harwell (JIRA) noreply at issues.asterisk.org
Thu Sep 12 16:01:47 CDT 2019


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

Kevin Harwell updated ASTERISK-28445:
-------------------------------------

    Attachment: endpoints.2000.sql
                endpoints.1000.sql
                invite_recv.xml
                invite.xml
                invite.csv

_pjsip.conf_:
{noformat}
[transport_t](!)
type=transport
bind=0.0.0.0

[transport_udp](transport_t)
protocol=udp
{noformat}
Not sure if it matters, but had caching enabled in _sorcery.conf_ at the time:
{noformat}
[res_pjsip]
endpoint/cache = memory_cache,maximum_objects=2000,expire_on_reload=yes,object_lifetime_maximum=3600,object_lifetime_stale=60
endpoint=config,pjsip.conf,criteria=type=endpoint
endpoint=realtime,ps_endpoints

auth/cache = memory_cache,maximum_objects=2000,expire_on_reload=yes,object_lifetime_maximum=3600,object_lifetime_stale=60
auth=config,pjsip.conf,criteria=type=auth
auth=realtime,ps_auths

aor/cache = memory_cache,maximum_objects=2000,expire_on_reload=yes,object_lifetime_maximum=3600,object_lifetime_stale=60
aor=config,pjsip.conf,criteria=type=aor
aor=realtime,ps_aors
{noformat}
_extensions.conf_:
{noformat}
[globals]
TECH=PJSIP

[default]
exten => _.,hint,${TECH}/{$EXTEN}

exten => _2XXX,1,NoOp()
	same => n,Dial(${TECH}/${EXTEN},10)
	same => n,Hangup()
{noformat}
_extconfig.conf_:
{noformat}
[settings]
ps_endpoints => odbc,asterisk
ps_auths => odbc,asterisk
ps_aors => odbc,asterisk
{noformat}
And don't forget to configure _res_odbc.conf_:
{noformat}
[asterisk]
enabled => yes
dsn => postgres
username => <your username>
password => <your password>
max_connections => 10
pre-connect => yes
{noformat}
Use alembic to create the tables in the db, insert the records, start Asterisk, then start the receiving SIPp scenario:
{noformat}
sipp 127.0.0.1 -p 5062 -aa -sf invite_recv.xml
{noformat}
Lastly, start the caller scenario:
{noformat}
sipp 127.0.0.1 -p 5061 -sf invite.xml -inf invite.csv -aa -r 50
{noformat}

> res_pjsip_session: ast_json_vpack: Invalid UTF-8 string on hangup when TEST_FRAMEWORK enabled
> ---------------------------------------------------------------------------------------------
>
>                 Key: ASTERISK-28445
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-28445
>             Project: Asterisk
>          Issue Type: Bug
>      Security Level: None
>          Components: Resources/res_pjsip_session
>    Affects Versions: 16.2.1
>         Environment: Debian Buster
>            Reporter: Bernhard Schmidt
>            Severity: Minor
>              Labels: pjsip
>         Attachments: aor, endpoint, endpoints.1000.sql, endpoints.2000.sql, invite.csv, invite_recv.xml, invite.xml
>
>
> On every hangup the following error is logged
> {code}
> [2019-06-12 00:11:07] ERROR[12584]: json.c:607 ast_json_vpack: Error building JSON from '{s: s, s: s, s: s, s: s, s: i, s: s}': Invalid UTF-8 string.
> [2019-06-12 00:11:07] ERROR[12584]:   Got 11 backtrace records
> # 0: /usr/sbin/asterisk(ast_json_pack+0x99) [0x5557a3eda459]
> # 1: /usr/sbin/asterisk(__ast_test_suite_event_notify+0x1be) [0x5557a3f6bbae]
> # 2: /usr/sbin/asterisk(__ao2_ref+0xa6) [0x5557a3e503a6]
> # 3: /usr/lib/asterisk/modules/res_pjsip_session.so(+0x6564) [0x7f8665c19564]
> # 4: /usr/sbin/asterisk(ast_taskprocessor_execute+0xd8) [0x5557a3f62f58]
> # 5: /usr/sbin/asterisk(+0x1821c0) [0x5557a3f6d1c0]
> # 6: /usr/sbin/asterisk(ast_taskprocessor_execute+0xd8) [0x5557a3f62f58]
> # 7: /usr/sbin/asterisk(+0x1819a4) [0x5557a3f6c9a4]
> # 8: /usr/sbin/asterisk(+0x18843f) [0x5557a3f7343f]
> # 9: /lib/x86_64-linux-gnu/libpthread.so.0(+0x7fa3) [0x7f868888efa3]
> #10: /lib/x86_64-linux-gnu/libc.so.6(clone+0x3f) [0x7f86885e94cf]
> {code}
> Other than being a big fat RED ERROR in the console it seems to have no ill consequences. 
> There is no non-ASCII character in the callerid or in the dialplan
> Possibly related judging from the backtrace, the Debian package for Asterisk builds with TEST_FRAMEWORK to run the testsuite in CI tests.



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



More information about the asterisk-bugs mailing list