[Feb 24 05:16:52] NOTICE[1311][C-00000002]: chan_pjsip.c:789 chan_pjsip_cng_tone_detected: FAX CNG detected on 'PJSIP/fax_ext-00000001' but no fax extension in 'incoming-faxuser'

I’m trying to send fax from fax machine to asterisk (16.16.1) running on Pi Zero. But I’m getting a Notice
" [Feb 24 05:16:52] NOTICE[1311][C-00000002]: chan_pjsip.c:789 chan_pjsip_cng_tone_detected: FAX CNG detected on ‘PJSIP/fax_ext-00000001’ but no fax extension in ‘incoming-faxuser’ "

This is my extensions.conf file

[general]
static=yes
writeprotect=no
clearglobalvars=no

[incoming-faxuser]
exten => _008333030359,1,NoOp(fax-starting)
same => n,Set(FAXDEST=/etc/asterisk)
same => n,Set(fax_number={EXTEN:2}) same => n,NoOp(This is the fax number: {fax_number})
same => n,Set(tempfax={STRFTIME(,,%C%y%m%d%H%M)}) same => n,System(/bin/echo "{fax_number}" > {FAXDEST}/{tempfax} &)
same => n,ReceiveFax({FAXDEST}/{tempfax}.tif,f,F,d)

exten => 800001,1,NoOp(fax-sending)
same => n,Set(FAXOPT(ecm)=yes)
same => n,Set(faxfilename=/tmp/fax_file/fax-12362-tif);
same => n,SendFax(${faxfilename},z,f,d)

and this is pjsip.conf file

[global]
type=global
keep_alive_interval=20
endpoint_identifier_order=username,ip,anonymous

[simple]
type=transport
protocol=udp
bind=0.0.0.0
tos=cs7
cos=7
local_net=192.168.10.0/24
external_media_address=50.209.180.113
external_signaling_address=50.209.180.113

[simpletrans]
type=transport
protocol=tcp
bind=0.0.0.0:5060
tos=cs7
cos=7
local_net=192.168.10.0/24
external_media_address=50.209.180.113
external_signaling_address=50.209.180.113

[fax_ext]
type=endpoint
transport=simple
context=incoming-faxuser
send_pai=yes
send_rpid=yes
disallow=all
tos_audio=cs7
cos_audio=7
fax_detect=yes
t38_udptl=yes
t38_udptl_nat=yes
rewrite_contact=yes
dtmf_mode=rfc4733
allow=ulaw,h263,h264
auth=fax_ext
aors=fax_ext

[fax_ext]
type=auth
auth_type=userpass
password=test123
username=fax_ext

[fax_ext]
type=aor
max_contacts=2

On the successful transmission of the fax from the fax machine to asterisks, two files will be generated one will be without .tif extension and another will be with .tif extension. I’m getting only one file which is without .tif extension.

Content of files will be:
The file without .tif extension will contain the dialed fax number only.
Another file will contain the document which was sent from a fax machine.

So, How to receive that second file?

That statement is true, and describes the problem.

Incidentally, doing pattern matches on a string with no character classes and no wildcards is inefficient.

@david551 can you please explain in brief?

You have no extension called “fax” in your context called “incoming-faxuser”, but you have fax detection enabled, and you received a fax call.

@david551

ast

Is that what you meant?
I added an extension called fax in my context

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.