Re: [asterisk-users] Incoming Fax Issue with Asterisk 11.7 and Digium Fax

2016-02-12 Thread Clemens Leu
Larry Moore  omninet.net.au> writes:

> 
> sip.conf
> 
> [general]
> faxdetect=t38
> 
> [sipcall.ch]
> directmedia=no
> 
> In extensions.conf change Wait(2) to Wait(5), if your VSP sends you a 
> T.38 re-invite this will trigger the switch to the Fax extension.
> 
> If this proves successful you can work on removing the Wait() from your 
> dialplan as Asterisk will remain in the audio path and should 
> successfully switch to the fax extension if extension 200 or 201 answer 
> a call that happens to be a fax.
> 
> Larry.
> 


Hi to all

Sorry to bump this old thread. Well, I found a while ago finally the reason
why T.38 doesn't work in conjunction with Swiss VoIP provider sipcall.

Despite T.38 is stated as "supported", that provider does NOT support T.38.
Their T.38 gateway has some fundamental negotiation problems, - it "exceeds
the T4 timer of the T.30 protocol". Therefore, T.38 faxing does not work.
http://wiki.innovaphone.com/index.php?title=Howto:Sipcall_business_-_SIP_Provider_Compatibility_Test

Sipcall has confirmed me that they work now on a solution. Will see...

Kind regards,

Clemens


-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Incoming Fax Issue with Asterisk 11.7 and Digium Fax

2014-02-03 Thread Larry Moore

On 3/02/2014 3:34 PM, Jakob-Matthias Böttger wrote:
.
.
.


[sipcall.ch]
type=peer
insecure=invite
defaultuser=123456789
fromuser=123456789
fromdomain=voipdomain.com
secret=gueswhat
host=voipdomain.com
qualify=yes
context=from-sip
dtmfmode=rfc2833
callbackextension=123456789



add

directmedia=no
setvar=FAXOPT(gateway)=no

change
insecure=port,invite




[fax-rx]

exten = receive,1,NoOp( FAX RECEIVE )
exten = receive,n,Set(GLOBAL(FAXCOUNT)=$[${GLOBAL(FAXCOUNT)} + 1])
exten = receive,n,Set(FAXCOUNT=${GLOBAL(FAXCOUNT)})


Do you want to keep your received faxes or is it OK to overwrite them 
the next time asterisk is re-started!?




udptl.conf
[general]
udptlstart=4000
udptlend=4999
udptlfecentries = 3
udptlfecspan = 3
use_even_ports = no



You may want to change

use_even_ports=yes

You will need to restart Asterisk for this change.

Some other suggestion if the above doesn't help are;

faxdetect=cng
t38pt_udptl=no

Larry.

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Incoming Fax Issue with Asterisk 11.7 and Digium Fax

2014-02-03 Thread Jakob-Matthias Böttger

Hi, changing

faxdetect=cng
and
t38pt_udptl=no

helped making it work.

Thanks


Am 03.02.2014 11:57, schrieb Larry Moore:

On 3/02/2014 3:34 PM, Jakob-Matthias Böttger wrote:
.
.
.


[sipcall.ch]
type=peer
insecure=invite
defaultuser=123456789
fromuser=123456789
fromdomain=voipdomain.com
secret=gueswhat
host=voipdomain.com
qualify=yes
context=from-sip
dtmfmode=rfc2833
callbackextension=123456789



add

directmedia=no
setvar=FAXOPT(gateway)=no

change
insecure=port,invite




[fax-rx]

exten = receive,1,NoOp( FAX RECEIVE )
exten = receive,n,Set(GLOBAL(FAXCOUNT)=$[${GLOBAL(FAXCOUNT)} + 1])
exten = receive,n,Set(FAXCOUNT=${GLOBAL(FAXCOUNT)})


Do you want to keep your received faxes or is it OK to overwrite them 
the next time asterisk is re-started!?




udptl.conf
[general]
udptlstart=4000
udptlend=4999
udptlfecentries = 3
udptlfecspan = 3
use_even_ports = no



You may want to change

use_even_ports=yes

You will need to restart Asterisk for this change.

Some other suggestion if the above doesn't help are;

faxdetect=cng
t38pt_udptl=no

Larry.




--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Incoming Fax Issue with Asterisk 11.7 and Digium Fax

2014-02-03 Thread Larry Moore

On 3/02/2014 7:15 PM, Jakob-Matthias Böttger wrote:

Hi, changing

faxdetect=cng
and
t38pt_udptl=no

helped making it work.



Hmm, the fax will be received as an audio call rather than T.38, setting 
t38pt_udptl=no has turned off T.38.


Do you know if your upstream provider supports T.38?

Larry.

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Incoming Fax Issue with Asterisk 11.7 and Digium Fax

2014-02-03 Thread Jakob-Matthias Böttger
as He is describing it he should actually provide t.38. but i don't know 
why it is not working thus im now getting


Feb  3 12:32:55] WARNING[9942][C-0004]: chan_sip.c:10353 
process_sdp: Failed to initialize UDPTL, declining image stream
[Feb  3 12:32:55] WARNING[9942][C-0004]: chan_sip.c:10497 
process_sdp: Insufficient information in SDP (c=)...

and then the fax session starts recording data

Am 03.02.2014 12:34, schrieb Larry Moore:

On 3/02/2014 7:15 PM, Jakob-Matthias Böttger wrote:

Hi, changing

faxdetect=cng
and
t38pt_udptl=no

helped making it work.



Hmm, the fax will be received as an audio call rather than T.38, 
setting t38pt_udptl=no has turned off T.38.


Do you know if your upstream provider supports T.38?

Larry.




--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Incoming Fax Issue with Asterisk 11.7 and Digium Fax

2014-02-03 Thread Larry Moore

On 3/02/2014 7:38 PM, Jakob-Matthias Böttger wrote:

as He is describing it he should actually provide t.38. but i don't know
why it is not working thus im now getting

Feb 3 12:32:55] WARNING[9942][C-0004]: chan_sip.c:10353 process_sdp:
Failed to initialize UDPTL, declining image stream
[Feb 3 12:32:55] WARNING[9942][C-0004]: chan_sip.c:10497
process_sdp: Insufficient information in SDP (c=)...
and then the fax session starts recording data



In udptl.conf set use_even_ports=yes and then issue a reload.

You can confirm the settings have been applied by performing udptl show 
config.


Change the the t38 line to read as;

t38pt_udptl=yes,redundancy,maxdatagram=400

Reload sip and test.

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Incoming Fax Issue with Asterisk 11.7 and Digium Fax

2014-02-03 Thread Jakob-Matthias Böttger

Am 03.02.2014 12:56, schrieb Larry Moore:

On 3/02/2014 7:38 PM, Jakob-Matthias Böttger wrote:

as He is describing it he should actually provide t.38. but i don't know
why it is not working thus im now getting

Feb 3 12:32:55] WARNING[9942][C-0004]: chan_sip.c:10353 process_sdp:
Failed to initialize UDPTL, declining image stream
[Feb 3 12:32:55] WARNING[9942][C-0004]: chan_sip.c:10497
process_sdp: Insufficient information in SDP (c=)...
and then the fax session starts recording data



In udptl.conf set use_even_ports=yes and then issue a reload.

You can confirm the settings have been applied by performing udptl 
show config.


Change the the t38 line to read as;

t38pt_udptl=yes,redundancy,maxdatagram=400

Reload sip and test.


after that i started udptl debug as well and now i'm getting lots of

UDPTL (SIP/sipcall.ch-0007): packet to 212.117.203.76:24492 (seq 
152, len 11)


and in between

[Feb  3 13:18:30] WARNING[26313][C-0007]: res_rtp_asterisk.c:3548 
ast_rtp_read: RTP Read too short


and in the end

[Feb  3 13:18:37] WARNING[9942]: chan_sip.c:4409 __sip_autodestruct: 
Autodestruct on dialog '24d15e0d-28df847a-9fae13c-7...@sip.iforb.com~1o' 
with owner SIP/sipcall.ch-0007 in place (Method: BYE). Rescheduling 
destruction for 1 ms
[Feb  3 13:18:41] ERROR[26313][C-0007]: res_fax.c:1535 
generic_fax_exec: channel 'SIP/sipcall.ch-0007' FAX session '7' 
failure, reason: 'fax session timed-out' (TIMEOUT)
  == Spawn extension (fax-rx, receive, 11) exited non-zero on 
'SIP/sipcall.ch-0007'



Thx, Jakob

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Incoming Fax Issue with Asterisk 11.7 and Digium Fax

2014-02-03 Thread Jakob-Matthias Böttger

Am 03.02.2014 13:20, schrieb Jakob-Matthias Böttger:

Am 03.02.2014 12:56, schrieb Larry Moore:

On 3/02/2014 7:38 PM, Jakob-Matthias Böttger wrote:
as He is describing it he should actually provide t.38. but i don't 
know

why it is not working thus im now getting

Feb 3 12:32:55] WARNING[9942][C-0004]: chan_sip.c:10353 
process_sdp:

Failed to initialize UDPTL, declining image stream
[Feb 3 12:32:55] WARNING[9942][C-0004]: chan_sip.c:10497
process_sdp: Insufficient information in SDP (c=)...
and then the fax session starts recording data



In udptl.conf set use_even_ports=yes and then issue a reload.

You can confirm the settings have been applied by performing udptl 
show config.


Change the the t38 line to read as;

t38pt_udptl=yes,redundancy,maxdatagram=400

Reload sip and test.


after that i started udptl debug as well and now i'm getting lots of

UDPTL (SIP/sipcall.ch-0007): packet to 212.117.203.76:24492 (seq 
152, len 11)


and in between

[Feb  3 13:18:30] WARNING[26313][C-0007]: res_rtp_asterisk.c:3548 
ast_rtp_read: RTP Read too short


and in the end

[Feb  3 13:18:37] WARNING[9942]: chan_sip.c:4409 __sip_autodestruct: 
Autodestruct on dialog 
'24d15e0d-28df847a-9fae13c-7...@sip.iforb.com~1o' with owner 
SIP/sipcall.ch-0007 in place (Method: BYE). Rescheduling 
destruction for 1 ms
[Feb  3 13:18:41] ERROR[26313][C-0007]: res_fax.c:1535 
generic_fax_exec: channel 'SIP/sipcall.ch-0007' FAX session '7' 
failure, reason: 'fax session timed-out' (TIMEOUT)
  == Spawn extension (fax-rx, receive, 11) exited non-zero on 
'SIP/sipcall.ch-0007'



Thx, Jakob

may do i have to open more ports then udp 1:2 (RTP), udp 
4000:4999 (UDPTL) and tcp 5060,5061(SIP/TLS)


--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Incoming Fax Issue with Asterisk 11.7 and Digium Fax

2014-02-03 Thread Larry Moore

On 3/02/2014 8:42 PM, Jakob-Matthias Böttger wrote:

Am 03.02.2014 13:20, schrieb Jakob-Matthias Böttger:

Am 03.02.2014 12:56, schrieb Larry Moore:

On 3/02/2014 7:38 PM, Jakob-Matthias Böttger wrote:

as He is describing it he should actually provide t.38. but i don't
know
why it is not working thus im now getting

Feb 3 12:32:55] WARNING[9942][C-0004]: chan_sip.c:10353
process_sdp:
Failed to initialize UDPTL, declining image stream
[Feb 3 12:32:55] WARNING[9942][C-0004]: chan_sip.c:10497
process_sdp: Insufficient information in SDP (c=)...
and then the fax session starts recording data



In udptl.conf set use_even_ports=yes and then issue a reload.

You can confirm the settings have been applied by performing udptl
show config.

Change the the t38 line to read as;

t38pt_udptl=yes,redundancy,maxdatagram=400

Reload sip and test.


after that i started udptl debug as well and now i'm getting lots of

UDPTL (SIP/sipcall.ch-0007): packet to 212.117.203.76:24492 (seq
152, len 11)

and in between

[Feb 3 13:18:30] WARNING[26313][C-0007]: res_rtp_asterisk.c:3548
ast_rtp_read: RTP Read too short

and in the end

[Feb 3 13:18:37] WARNING[9942]: chan_sip.c:4409 __sip_autodestruct:
Autodestruct on dialog
'24d15e0d-28df847a-9fae13c-7...@sip.iforb.com~1o' with owner
SIP/sipcall.ch-0007 in place (Method: BYE). Rescheduling
destruction for 1 ms
[Feb 3 13:18:41] ERROR[26313][C-0007]: res_fax.c:1535
generic_fax_exec: channel 'SIP/sipcall.ch-0007' FAX session '7'
failure, reason: 'fax session timed-out' (TIMEOUT)
== Spawn extension (fax-rx, receive, 11) exited non-zero on
'SIP/sipcall.ch-0007'


Thx, Jakob


may do i have to open more ports then udp 1:2 (RTP), udp
4000:4999 (UDPTL) and tcp 5060,5061(SIP/TLS)



The T.38 connection will be attempted when ReceiveFax is called.

The port number to use should be in the SDP information, yes, allow udp 
ports 4000-4999 in and out. If your firewall can be so configured you 
could set it to allow traffic in and out based upon the user ID Asterisk 
is running as, assuming it is using a unique unprivileged id.


You may like to try the following to see if your SIP provider will 
initiate a T.38 re-invite.


sip.conf

[general]
faxdetect=t38

[sipcall.ch]
directmedia=no


In extensions.conf change Wait(2) to Wait(5), if your VSP sends you a 
T.38 re-invite this will trigger the switch to the Fax extension.


If this proves successful you can work on removing the Wait() from your 
dialplan as Asterisk will remain in the audio path and should 
successfully switch to the fax extension if extension 200 or 201 answer 
a call that happens to be a fax.


Larry.

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] Incoming Fax Issue with Asterisk 11.7 and Digium Fax

2014-02-02 Thread Jakob-Matthias Böttger

Hi, im using a Asterisk Server which is not behind NAT.
First i had problems with the fax detection. But this is now solved 
after adding a wait(2) at the correct place. But i'm still unable to 
receive a fax due to res_rtp_asterisk.c:3548 ast_rtp_read: RTP Read too 
short after the Fax session has started.



My sip.conf includes

[general]
allowguest=no
alwaysauthreject=yes

sendrpid=rpid
trustrpid=yes
language=de
videosupport=yes
callevents=yes
qualify=yes
nat=force_rport,comedia
faxdetect=yes
t38pt_udptl=yes,redundancy,maxdatagram=400
directrtpsetup=yes
disallow=all
allow=ulaw
allow=alaw

and the corresponding Peer

[sipcall.ch]
type=peer
insecure=invite
defaultuser=123456789
fromuser=123456789
fromdomain=voipdomain.com
secret=gueswhat
host=voipdomain.com
qualify=yes
context=from-sip
dtmfmode=rfc2833
callbackextension=123456789

the Dialplan

[inbound]
exten = _X.,1,Answer()
exten = _X.,n,Set(DB(lastcaller/number)=${CALLERID(num)})
exten = _X.,n,GotoIf(${BLACKLIST()}?black,1)
exten = _X.,n,Wait(2)
exten = _X.,n,Dial(SIP/200SIP/201,60,tToxX)
exten = _X.,n,Goto(ausser-zeit,_X.,3)
exten = _X.,n,Hangup()

exten = fax,1,NoOp( FAX DETECTED )
exten = fax,n,Goto(fax-rx,receive,1)

[fax-rx]

exten = receive,1,NoOp( FAX RECEIVE )
exten = receive,n,Set(GLOBAL(FAXCOUNT)=$[${GLOBAL(FAXCOUNT)} + 1])
exten = receive,n,Set(FAXCOUNT=${GLOBAL(FAXCOUNT)})
exten = receive,n,Set(FAXFILE=fax-${FAXCOUNT}-rx.tif)
exten = receive,n,Set(GLOBAL(LASTFAXCALLERoNUM)=${CALLERID(num)})
exten = receive,n,Set(GLOBAL(LASTFAXCALLERNAME)=${CALLERID(name)})
exten = receive,n,NoOp( SETTING FAXOPT )
exten = receive,n,Set(FAXOPT(ecm)=yes)
exten = receive,n,Set(FAXOPT(headerinfo)=MYFAX RX)
exten = receive,n,Set(FAXOPT(localstationid)=1234567890)
exten = receive,n,Set(FAXOPT(maxrate)=14400)
exten = receive,n,Set(FAXOPT(minrate)=2400)
exten = receive,n,NoOp(FAXOPT(ecm) : ${FAXOPT(ecm)})
exten = receive,n,NoOp(FAXOPT(headerinfo) : ${FAXOPT(headerinfo)})
exten = receive,n,NoOp(FAXOPT(localstationid) : ${FAXOPT(localstationid)})
exten = receive,n,NoOp(FAXOPT(maxrate) : ${FAXOPT(maxrate)})
exten = receive,n,NoOp(FAXOPT(minrate) : ${FAXOPT(minrate)})
exten = receive,n,NoOp( RECEIVING FAX : ${FAXFILE} )
exten = receive,n,ReceiveFAX(/var/spool/asterisk/faxin/${FAXFILE},dfs)
exten = h,1,NoOp(FAXOPT(ecm) : ${FAXOPT(ecm)})
exten = h,n,NoOp(FAXOPT(filename) : ${FAXOPT(filename)})
exten = h,n,NoOp(FAXOPT(headerinfo) : ${FAXOPT(headerinfo)})
exten = h,n,NoOp(FAXOPT(localstationid) : ${FAXOPT(localstationid)})
exten = h,n,NoOp(FAXOPT(maxrate) : ${FAXOPT(maxrate)})
exten = h,n,NoOp(FAXOPT(minrate) : ${FAXOPT(minrate)})
exten = h,n,NoOp(FAXOPT(pages) : ${FAXOPT(pages)})
exten = h,n,NoOp(FAXOPT(rate) : ${FAXOPT(rate)})
exten = h,n,NoOp(FAXOPT(remotestationid) : ${FAXOPT(remotestationid)})
exten = h,n,NoOp(FAXOPT(resolution) : ${FAXOPT(resolution)})
exten = h,n,NoOp(FAXOPT(status) : ${FAXOPT(status)})
exten = h,n,NoOp(FAXOPT(statusstr) : ${FAXOPT(statusstr)})
exten = h,n,NoOp(FAXOPT(error) : ${FAXOPT(error)})

udptl.conf
[general]
udptlstart=4000
udptlend=4999
udptlfecentries = 3
udptlfecspan = 3
use_even_ports = no

rtp.conf
[general]
rtpstart=1
rtpend=2

res_fax.conf
[general]
maxrate=14400
minrate=2400
statusevents=yes
modems=v17,v27,v29
ecm=yes


mail*CLI core set verbose 6
Set remote console verbosity to 6
  == Using SIP RTP CoS mark 5
-- Executing [41325122774@from-sip:1] 
Answer(SIP/sipcall.ch-008d, ) in new stack
0x7f3964080f30 -- Probation passed - setting RTP source 
address to 123.456.789.123:20600
Got  RTP packet from123.456.789.123:20600 (type 00, seq 042281, ts 
1387619622, len 000160)
-- Executing [41325122774@from-sip:2] 
Set(SIP/sipcall.ch-008d, DB(lastcaller/number)=987654321) in new 
stack
-- Executing [41325122774@from-sip:3] 
GotoIf(SIP/sipcall.ch-008d, 0?black,1) in new stack
-- Executing [41325122774@from-sip:4] 
Wait(SIP/sipcall.ch-008d, 2) in new stack
Got  RTP packet from123.456.789.123:20600 (type 00, seq 042282, ts 
1387619782, len 000160)
Got  RTP packet from123.456.789.123:20600 (type 00, seq 042283, ts 
1387619942, len 000160)
Got  RTP packet from123.456.789.123:20600 (type 00, seq 042284, ts 
1387620102, len 000160)
Got  RTP packet from123.456.789.123:20600 (type 00, seq 042285, ts 
1387620262, len 000160)
Got  RTP packet from123.456.789.123:20600 (type 00, seq 042286, ts 
1387620422, len 000160)
Got  RTP packet from123.456.789.123:20600 (type 00, seq 042287, ts 
1387620582, len 000160)
Got  RTP packet from123.456.789.123:20600 (type 00, seq 042288, ts 
1387620742, len 000160)
Got  RTP packet from123.456.789.123:20600 (type 00, seq 042289, ts 
1387620902, len 000160)
Got  RTP packet from123.456.789.123:20600 (type 00, seq 042290, ts 
1387621062, len 000160)
Got  RTP packet from123.456.789.123:20600 (type 00, seq 042291, ts 
1387621222, len 000160)
Got  RTP packet from123.456.789.123:20600 (type 00, seq