Re: [OpenSIPS-Devel] [opensips] [RFC] An initial attempt of porting rtpproxy-ng module from your twin project to OpenSIPS. (#152)

2014-03-06 Thread Iñaki Baz Castillo
Even if this new protocol (rtpproxy-ng) is based on the original rtpproxy 
protocol, naming it as rtpproxy-ng seems a bad idea IMHO as it will generate 
unavoidable confusion. The fact that the Sippy RTP relayer is named RtpProxy 
(same name as the protocol) does not help, and things become worse given that 
there is a protocol (and proxy module) called x-ng which connects to a 
media relayer called y-ng (where x != y, and y is 
already used by other protocol, module and server, this is: mediaproxy).

I strongly suggest choosing a new name for the protocol (eg. SMCP - Sipwise 
Media Control Protocol, or whatever), rename the SIP proxy module with that 
name, and then rename the current mediaproxy-ng server with any name (may not 
include the SMCP keyword), eg. SipWise Media Relayer.

---
Reply to this email directly or view it on GitHub:
https://github.com/OpenSIPS/opensips/pull/152#issuecomment-36883844___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [opensips] Via branch non RFC 3261 compliant (#145)

2013-12-02 Thread Iñaki Baz Castillo
2013/12/2 Varun notificati...@github.com

 When sending the options packet to non-webrtc clients there is no problem,
 but when sending it to webrtc clients through oversip, oversip expects the
 branch tag to have a value.


Yes, that 's a bug in OpenSIPS as it sets ;branch=0 which is not RFC 3261
compliant.


-- 
Iñaki Baz Castillo
i...@aliax.net

---
Reply to this email directly or view it on GitHub:
https://github.com/OpenSIPS/opensips/issues/145#issuecomment-29628394___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [OpenSIPS-Users] [RELEASES] Planing OpenSIPS 1.9.0 major release

2012-11-02 Thread Iñaki Baz Castillo
2012/11/2 Binan AL Halabi binanalhal...@yahoo.com:

 Hi All,

 If oversip uses Path extension OpenSIPS must support it.

 1- Sending Path header values in 200 ok REGISTER response

Even if this is required by RFC, the fact is that it's not needed at
all for this stuff to work.


 2- Path header files syntax must confom to Route syntax

Right.


 3- When look up the opensips must copies the stored path header fileds into
 Route header fileds - preloaded route.
 Reference: RFC 3327

Right.



 Here i think adding one Route header pointing to OverSIP (second Path URI)
 is enough in simple case (UA  OverSIP--- OpenSIPS).
 OverSIP removes the Route header and route the request based on RURI (first
 Path URI).

Also right, but due the design of OverSIP (basically an Outbound EDGE
proxy) it was easier for me to always use double Record-Route and
double Path header. In Outbound (RFC 5626) the Record-Route header
added by the EDGE proxy contains a username in the URI that identifies
the client connection. For some reasons it was easier always to use
double Path.

Anyhow, consider also the case in which there are two proxies between
clients and OpenSIPS, so increasing the size of the path column is
required.




--
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [OpenSIPS-Users] [RELEASES] Planing OpenSIPS 1.9.0 major release

2012-11-02 Thread Iñaki Baz Castillo
2012/11/2 Bogdan-Andrei Iancu bog...@opensips.org:
 Yes the patch is there, we need to review it. Also Inaki sugested some
 tunings in the PATH module (to fully support websocket).

Well, there is no special needs for the PATH module to support
WebSocket. In fact, nothing must be done if it already works ok (but
just increasing the path column size to be able to store two URIs).

Regards.

--
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] SF.net SVN: opensips:[7319] trunk

2010-12-12 Thread Iñaki Baz Castillo
2010/10/22 Ovidiu Sas o...@voipembedded.com:
 presence: support for extra headers in NOTIFY

  - extra headers received in PUBLISH requests can be
 stored and sent to the subscrber via NOTIFY requests

As I told in other mail in devel maillist, this feature is totally
wrong and it's based on a wrong/buggy assumption and misunderstanding
of the standard.

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] contact param missing in active_watchers table (resend)

2010-11-26 Thread Iñaki Baz Castillo
2010/11/25 Iñaki Baz Castillo i...@aliax.net:
 2010/11/25 Juha Heinanen j...@tutpro.com:
 not including the param if s are missing around the uri looks like a
 bug to me, since according to sip syntax in both cases ;param should be
 interpreted as uri parameter, not header parameter.

 comments?

 I agree.


Sorry, I didn't read properly your mail. When you say:


 i noticed that when presence server receives subscribe that has this kind of 
 contact header:
   Contact: sip:u...@172.17.49.100:5060;param=x
 then ;param in NOT included in active_watchers contact field and notify is 
 not delivered properly.

This is correct as param is a header parameter and not a SIP URI parameter.



-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] contact param missing in active_watchers table (resend)

2010-11-25 Thread Iñaki Baz Castillo
2010/11/25 Juha Heinanen j...@tutpro.com:
 not including the param if s are missing around the uri looks like a
 bug to me, since according to sip syntax in both cases ;param should be
 interpreted as uri parameter, not header parameter.

 comments?

I agree.

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [OpenSIPS-Users] New OpenXCAP release 2.0.0 with support for OMA XDM SIP SIMPLE specifications

2010-10-17 Thread Iñaki Baz Castillo
2010/10/17 Saúl Ibarra Corretgé s...@ag-projects.com:
 allow_external_references = No

 And what about if the document cointaining foreign XCAP roots where
 stored prior to setting allow_external_references = No (after
 restarting OpenXCAP)?


 Next time you try to do a PUT it'll fail.

So such PUT will be rejected, but the existing document (containing
external references) will remain *active*.


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] New OpenXCAP release 2.0.0 with support for OMA XDM SIP SIMPLE specifications

2010-10-09 Thread Iñaki Baz Castillo
2010/10/8 Saúl Ibarra Corretgé s...@ag-projects.com:
  * Check entry-ref entries in resource-lists

 OMA prohibits the usage of entry-ref. Just external-ref is allowed.
 entry-ref just exists in IETF's incomplete specs. What does OpenXCAP
 implement exactly?


 Can you point me to the document where that is stated please?


I'm sorry but I can't remember it. But for sure I've read it in some
OMA spec. In fact you won't find 'entry-ref' in any XCAP document
defined by OMA.



-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] proposal of removal of lcr module (deprecated by drouting)

2010-09-29 Thread Iñaki Baz Castillo
2010/9/28 Ovidiu Sas o...@voipembedded.com:
 there is a proposal to remove the lcr module for the next release.

 Why:
  - lcr module was deprecated by drouting module
  - lcr module is no longer actively maintained

 If there are any objections, please let us know.

Just a question: What about loading contacts based on registration
;q parameter? LCR provides this feature by using load_contacts() and
next_contacts().




-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] how to use the db_http module

2010-07-17 Thread Iñaki Baz Castillo
2010/7/16 heiio098 heiio...@163.com:
 HI
     thank for you replay
     If I use APACHE as a WEB server ,The need to write a apache module,to
 replay like this

 int;string;string
 6;something=something;1000
 100;mine;10002030


So great.

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [OpenSIPS-Users] New features in BLF and presence

2010-04-21 Thread Iñaki Baz Castillo
2010/4/20 Saúl Ibarra Corretgé s...@ag-projects.com:
 May I suggest something: instead of using terms like 'on the phone' that
 suggest only telephony we could use a more generic ones, to match the
 concept of a 'session'. A user may establish an audio, video, msrp, t140
 session with another, so instead of being 'on the phone' he would be 'In
 session...', instead of being 'Ringing...' it would be 'Alerting...' or
 some more appropriate messages. How does it sound?

Common users wont understand what on a session means.
IMHO a IM session should never be notified to watchers as a different status.

Also, if I set offline status (other not to see me online) and I do
a call, will then my watchers receive a NOTIFY with status on the
phone?


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [OpenSIPS-Users] New features in BLF and presence

2010-04-16 Thread Iñaki Baz Castillo
2010/4/14 Anca Vamanu a...@opensips.org:
 The second important feature is the possibility to mix dialog
 information with presence. Until now, dialog and presence were two
 different things. If you wanted to know if someone is currently in a
 call, your phone had to support BLF and send Subscribes for dialog
 event. Knowing if someone is in a call is quite a demanded feature. The
 simplest example is with the assistant manager that first answer the
 calls and needs to know if the manager line is idle and she can transfer
 the call to him. The reality is that few phones have support for dialog
 event notifications, but more have support for presence.

Let me a question:

In case the INVITE has a SDP just containing a MSRP path (without
audio/video), would also the pua_dialog generate a ringing
dialog-info Publish?
This is, if Alice starts a MSRP messaging session with Bob, would
Carol see both Alice and Bob with activity On the phone?  :)


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [OpenSIPS-Users] New features in BLF and presence

2010-04-14 Thread Iñaki Baz Castillo
2010/4/14 Anca Vamanu a...@opensips.org:
 Therefore, we decided to mix the dialog information with presence at the
 presence server. Now, the presence server is able to tell you if a buddy
 is in a call through presence Notifications even if his phone did not
 send a presence Publish with this information. The mixing in fact
 generates presence from dialog info when a call is in progress and mixes
 this with the presence information received from his phone through
 Publish. The result is that when a buddy is in a call you will see a
 status indicating this and in the rest of the time you will see the
 presence state that the buddy set in his client.

Hi, this feature sounds really reasonable for the real world in which we live :)
Could I see how such NOTIFY (mixing presence and dialog information)
looks? (just an example).

Thanks.

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Can I increase the number of process in openser-1.3.1?

2009-12-03 Thread Iñaki Baz Castillo
El Jueves, 3 de Diciembre de 2009, 徐飞 escribió:
 Hi All,
 
 Recently, i need to improve the performace of openser 1.3.1.
 
 I need more processes to deal with multiple calls, so how can i increase
  the process number?

This is not a question for teh devel maillist. Please use the users maillist.
Thanks.

-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Enlarging xcap table doc field

2009-11-28 Thread Iñaki Baz Castillo
2009/11/27 Saul Ibarra Corretge s...@ag-projects.com:

 In a high load environment I wouldn't like to imagine a MySQL MyISAM
 table (xcap) storing millions of rows with a MEDIUMBLOB field. Such
 kind of tables get corrupted after some time and so, for sure.
 IMHO is not a good design.


 No binary data gets stored, it's just text.

It doesn't matter fi it's text or binary, finally it's MySQL data :)


 An XML with a base64 encoded image. Do you think storing at most 16MB of text 
 (there are size constraints for the image so i'll never get bigger than a few 
 MBs) it could get corrupted?

Let's suppose a provider with 1 users using XCAP.
Also imagine 50Kb per image/icon plus 1Kb per text XML document. Let's
suppose 3 documents per user (pres-rules, resource-list and icon). So
we end with more than 500 MB in the xcap table.

Under my experience, MySQL large tables get corrupted some times,
and that's really more probable if the table contains long fields.
This is as least what I've issued working with MySQL MyISAM long
tables.




-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Enlarging xcap table doc field

2009-11-26 Thread Iñaki Baz Castillo
El Jueves, 26 de Noviembre de 2009, Saul Ibarra Corretge escribió:
 Hi again,
 
 My previous mail maybe wasn't really clear, let me explain it again:
 
 There is an OMA spec (OMA-TS-Presence-SIMPLE_Content_XDM-V1_0) regarding
  icon storage on an XCAP server. We are actually implementing it in
  OpenXCAP when using OpenSIPS backend the 'doc' field is not able to
  accommodate the size of the icon.
 
 This could also happen with larger documents in the future so Anca, I would
  like to enlarge the field to MEDIUMBLOB if you have no objection?

IMHO a more scalable and suitable solution would be using different tables (or 
also databases) for each XCAP auid.

-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Add X-XCAP-Preferred-Identity header to XCAP clients

2009-11-20 Thread Iñaki Baz Castillo
El Viernes, 20 de Noviembre de 2009, Adrian Georgescu escribió:
 See OMA *icon auid.
 It is well documented and it makes sense except for those X- headers
 that are completely useless on the public Internet.

But will you implement OMA icon auid?


-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Add X-XCAP-Preferred-Identity header to XCAP clients

2009-11-19 Thread Iñaki Baz Castillo
El Jueves, 19 de Noviembre de 2009, Thiago Rondon escribió:
 Iñaki,
 
 In this scenario that you said, alice could fetch bob's icon store in
 the XCAP server by authentication as alice, how the security roles works?
 
 For example, if you can just give access to alice to see bob's icon if
 alice in the 'whitelist' of presence-rules.xml ?

That's a very good question for which there is no specifications (AFAIK).
However the server could have local policies (i.e: alice can get bob's icon, 
after authentication, since alice's domain matches bob's domain).

Inspecting the pres-rules of bob would be the more ellegant solution: if bob 
allows alice to see his status, then it makes sense that alice could fetch 
bob's icon (same as in XMPP, MSN networks).

However it requires that the XCAP server inspect bob's pres-rules, but it 
could be feasible.



 
 Thanks!
 -Thiago Rondon
 
 Iñaki Baz Castillo escreveu:
  Hi, authorization in IETF's pure XCAP is not defined. This is: a XCAP
  request doesn't identify the originator but just the requested user's
  document.
 
  A too much simplistic workaround is requiring authentication for all the
  requests and just allow the request if the credentials username matches
  the request XUI.
 
  However this is not valid for some cool XCAP applications as fetching
  users' icon (alice couldn't fetch bob's icon stored in the XCAP server as
  alice cannot authenticate as bob).
 
  As I sad above, IETF didn't manage it. Instead there are some solutions
  born in OMA, 3GPP and so...
 
  The solution is adding an identity header in the client request
  identifying the desired identity (SIP or TEL URI), so the server would
  ask authentication based on  the identity rather than on the XUI. This
  would allow the server to authorize alice (after authentication) to
  access bob's icon.
 
  This header can be:
 
X-XCAP-Preferred-Identity
  and/or
X-3GPP-Preferred-Identity
 
  In OMA architecture, where there is an aggregation proxy in front of the
  XCAP servers, the proxy authenticates the client and asserts its identity
  by adding X-XCAP/3GPP-Asserted-Identity (some mechanism as in pure SIP
  protocol).
 
  I've already implemented it in my Ruby XCAP client library (version 1.2):
http://dev.sipdoc.net/projects/ruby-xcapclient/news
 
  I suggest to include it in other XCAP clients (AG's Python xcapclient,
  sipsimpleclient, Blink...).
 
  Regards.
 
 ___
 Devel mailing list
 Devel@lists.opensips.org
 http://lists.opensips.org/cgi-bin/mailman/listinfo/devel
 


-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Add X-XCAP-Preferred-Identity header to XCAP clients

2009-11-19 Thread Iñaki Baz Castillo
El Jueves, 19 de Noviembre de 2009, Adrian Georgescu escribió:
 First of all, there is no correlation on protocols level between the
 SIP Subscribe from a foreign domain and the HTTP GET requests the
 watcher performs for fetching an icon stored in an XCAP server in a
 foreign domain. So technically you cannot enforce  a policy about who
 is allowed to HTTP GET your icon.

At least you can implement a local policy. The SIP proxy and the HTTP 
proxy/server can ask for authentication just in case the From domain and the 
X-XCAP-Preferred-Identity domain is a provider local domain.
Other domains (untrusted) can be considered as others and the local policy 
could be different for trusted and untrusted domains.


 According to OMA everything is pipe between operators that have
 agreements between them. So by proxying all HTTP requests to an
 outbound proxy of operator A the HTTP request will arrive with some
 extra asserted headers to operator B who will then trust them and
 honor the HTTP request based on them. This is non-sense on the Internet.

Sure.

 
 Protecting an icon is also complete non-sense as once somebody fetched
 it no matter by what means or credentials it can post it on Facebook
 and the rest of the universe got it. Is a picture in the end,
 something you display in a small area of a remote device, something
 you published in the first place to be reachable and not some credit
 card secret details. If you think you need high security for an icon
 do not publish it in the first place.

The icon is just an example. I expect there could be other kind of documents a 
user desires to share just to others.

 

 The only reasonable thing you can do with the icon is to anonymize the
 URL so that people cannot simply guess it. The ones who obtain the URL
 from the Notify with presence Event can fetch it because they know
 where it is.

And he can also upload it to Facebook again.


 This is what we are now building in OpenXCAP.

Another propietary (even if it's open source) XCAP application? good, and 
which client will implement it (uploading an naming an icon in a propietary 
way)? Let me guess... Blink?

I could agree with these kind of new features if they would be, at least, 
documented as proposed drafts.

This is, now pres-dialog-rules has been released and supported by OpenSIPS, 
OpenXCAP and Blink. Will be a concise documentation of this custom format? or 
should I inspect the requests Blink generates to imitate them?
The same for this new XCAP icon storage application: which mime-type will be 
used? which format and size is allowed? which kind od transfer type? or should 
I do a ngrep?

Please don't take wrong Adrian, I want to be constructive.

Regards.


-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Adding support for 'dialog-rules'

2009-11-18 Thread Iñaki Baz Castillo
El Miércoles, 18 de Noviembre de 2009, Adrian Georgescu escribió:
 Inaki,
 
 So what are you gonna do about it?

Code :)


-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Add X-XCAP-Preferred-Identity header to XCAP clients

2009-11-18 Thread Iñaki Baz Castillo
El Jueves, 19 de Noviembre de 2009, Iñaki Baz Castillo escribió:
 This header can be:
 
   X-XCAP-Preferred-Identity
 and/or
   X-3GPP-Preferred-Identity

References:
- OMA-TS-XDM_Core-V1_1-20080627-A (6.3.2 XDM Client identity assertion)
- 3GPP TS 24.109 (7.2 Authentication)


However there is other approach:

1) The client doesn't include a identity header.

2) The XCAP proxy/server requires autentication, but it *doesn't* set the 
realm based on the XUI domain. Instead it sets the realm with a constant value 
(i.e.: provider.com) even if it's a multidomain environment.

3) The client creates the credentials and sets as username the *full* SPI URI 
(sip:al...@domain.org).

4) The servers checks the credentials and parses the credentials username so 
it already knows the identity of the client and can check authorization based 
on the identity, the xui and the requested document.


But it's important to understand that Digest credentials username should 
contain a SIP URI (or TEL URI) rather than just the SIP username or a pseudo-
uri (al...@domain.org).

In fact, I would like that OpenSIPS itself adds a new field ha1c in 
subscriber table so:

  ha1  = credentials username = alice
  ha1b = credentials username = al...@domain.org
  ha1c = credentials username = sip:al...@domain.org


Also, OMA specs mandate it:

--
OMA-TS-XDM_Core_V2

 5.1 Security Procedures
   3. The “username” parameter SHALL have the value of the XUI (i.e. the SIP
  URI or Tel URI) identifying the user (the public user identity);
--


Regards.


-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] segmenfault in db_mysql_do_prepared_query

2009-10-28 Thread Iñaki Baz Castillo
Hi, opensips trunk rev 5738 working as presence server. It was running
properly (note that there is no traffic yet, just some times). But 8
days ago there was a segmenfault:


(gdb) bt full
#0  0x7fc95c7f7197 in memcpy () from /lib/libc.so.6
No symbol table info available.
#1  0x7fc95bfa14d1 in mysql_stmt_bind_param () from
/usr/lib/libmysqlclient.so.15
No symbol table info available.
#2  0x7fc95c3564fb in db_mysql_do_prepared_query (conn=0x734fe8,
query=0x7fc95c56d6f0, v=0x7fff650ff1c0, n=9, uv=0x0, un=0) at
dbase.c:497
i = 0
code = 9
cols = 7571504
pq_ptr = (struct prep_stmt *) 0x73c2e8
ctx = (struct my_stmt_ctx *) 0x73b950
mysql_bind = (MYSQL_BIND *) 0x73c328
id = value optimized out
__FUNCTION__ = db_mysql_do_prepared_query
#3  0x7fc95c357c86 in db_mysql_query (_h=0x734fe8,
_k=0x7fff650ff300, _op=0x0, _v=0x7fff650ff1c0, _c=0x7fff650ff350,
_n=9, _nc=7, _o=0x0, _r=0x7fff650ff3a8) at dbase.c:763
ret = 0
__FUNCTION__ = db_mysql_query
#4  0x7fc95a5cbd53 in get_database_info (msg=value optimized
out, subs=0x7fff650ff5f0, reply_code=0x7fff650ff724,
reply_str=0x7fff650ff700) at subscribe.c:1222
query_cols = {0x7fc95a7d5b90, 0x7fc95a7d5bd0, 0x7fc95a7d5be0,
0x7fc95a7d5bf0, 0x7fc95a7d5c10, 0x7fc95a7d5c00, 0x7fc95a7d5c50,
0x7fc95a7d5c40, 0x7fc95a7d5c30, 0x40}
query_vals = {{type = DB_STR, nul = 0, free = 1554811360, val
= {int_val = 7352181, double_val = 3.6324600541067419e-317, time_val =
7352181,
  string_val = 0x702f75
5...@sip.mydomain.net;tag=13b52bc3e9f25b251a1546eb57a3a45c-28f3\r\nCall-ID:
3743611...@10.134.16.230\r\ncseq: 30 SUBSCRIBE\r\nContact:
sip:30...@222.111.253.254:52189\r\nMax-Forwards: 68\r\nEvent:
presence\r\nU..., str_val = {
s = 0x702f75
5...@sip.mydomain.net;tag=13b52bc3e9f25b251a1546eb57a3a45c-28f3\r\nCall-ID:
3743611...@10.134.16.230\r\ncseq: 30 SUBSCRIBE\r\nContact:
sip:30...@222.111.253.254:52189\r\nMax-Forwards: 68\r\nEvent:
presence\r\nU..., len = 3}, blob_val = {
s = 0x702f75
5...@sip.mydomain.net;tag=13b52bc3e9f25b251a1546eb57a3a45c-28f3\r\nCall-ID:
3743611...@10.134.16.230\r\ncseq: 30 SUBSCRIBE\r\nContact:
sip:30...@222.111.253.254:52189\r\nMax-Forwards: 68\r\nEvent:
presence\r\nU..., len = 3}, bitmap_val = 7352181}}, {type = DB_STR,
nul = 0, free = 1695544080, val = {int_val = 7352185,
  double_val = 3.6324620303693252e-317, time_val = 7352185,
  string_val = 0x702f79
sip.mydomain.net;tag=13b52bc3e9f25b251a1546eb57a3a45c-28f3\r\nCall-ID:
3743611...@10.134.16.230\r\ncseq: 30 SUBSCRIBE\r\nContact:
sip:30...@222.111.253.254:52189\r\nMax-Forwards: 68\r\nEvent:
presence\r\nUser-..., str_val = {
s = 0x702f79
sip.mydomain.net;tag=13b52bc3e9f25b251a1546eb57a3a45c-28f3\r\nCall-ID:
3743611...@10.134.16.230\r\ncseq: 30 SUBSCRIBE\r\nContact:
sip:30...@222.111.253.254:52189\r\nMax-Forwards: 68\r\nEvent:
presence\r\nUser-..., len = 16}, blob_val = {
s = 0x702f79
sip.mydomain.net;tag=13b52bc3e9f25b251a1546eb57a3a45c-28f3\r\nCall-ID:
3743611...@10.134.16.230\r\ncseq: 30 SUBSCRIBE\r\nContact:
sip:30...@222.111.253.254:52189\r\nMax-Forwards: 68\r\nEvent:
presence\r\nUser-..., len = 16}, bitmap_val = 7352185}}, {type =
DB_STR, nul = 0, free = 1552178514, val = {int_val = 7352132,
  double_val = 3.6324358448900956e-317, time_val = 7352132,
  string_val = 0x702f44
30...@sip.mydomain.net;tag=2341707388\r\nTo:
sip:5...@sip.mydomain.net;tag=13b52bc3e9f25b251a1546eb57a3a45c-28f3\r\nCall-ID:
3743611...@10.134.16.230\r\ncseq: 30 SUBSCRIBE\r\nContact:
sip:30...@222.111.253..., str_val = {


Is it known bug?

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Why opensipsctl fifo dr_relo ad returns 0 even if it fails?

2009-10-19 Thread Iñaki Baz Castillo
El Lunes, 19 de Octubre de 2009, Bogdan-Andrei Iancu escribió:
 Hi Iñaki,
 
 When loading rules and gateways, the DR module is able to skip records
 which are not valid - this is required to prevent a reload to failed
 because of a single bogus rule or GW.

Yes, the only issue I see is that MI commands says nothing so the only way to 
realize of it is by inspecting hte logs. Am I wrong?

 
 Regards,
 Bogdan
 
 Iñaki Baz Castillo wrote:
  Hi, after setting drouting tables with wrong values I run:
 
~# opesipsctl fifo dr_reload
 
  The command return $? = 0 (success). However the log clearly says:
 
  Oct 17 23:27:45 [4422] INFO:drouting:dr_reload_cmd: dr_reload MI
  command received!
  Oct 17 23:27:45 [4422] ERROR:drouting:build_rt_info: invalid GW id 123123
  Oct 17 23:27:45 [4422] ERROR:drouting:dr_load_routing_info: failed to add
  routing info for rule id 204 - skipping
  Oct 17 23:27:45 [4422] ERROR:drouting:build_rt_info: invalid GW id 666
  Oct 17 23:27:45 [4422] ERROR:drouting:dr_load_routing_info: failed to add
  routing info for rule id 206 - skipping
  Oct 17 23:27:45 [4422] ERROR:drouting:build_rt_info: invalid GW id 
  Oct 17 23:27:45 [4422] ERROR:drouting:dr_load_routing_info: failed to add
  routing info for rule id 207 - skipping
 
  Shouldn't the command return != 0 in this case?
 
 ___
 Devel mailing list
 Devel@lists.opensips.org
 http://lists.opensips.org/cgi-bin/mailman/listinfo/devel
 


-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Why opensipsctl fifo dr_reload returns 0 even if it fails?

2009-10-19 Thread Iñaki Baz Castillo
El Lunes, 19 de Octubre de 2009, Bogdan-Andrei Iancu escribió:
  Yes, the only issue I see is that MI commands says nothing so the only
  way to realize of it is by inspecting hte logs. Am I wrong?
 
 yes, right now there is no way to make a difference between a complete
 successful load and a partial load (with skipped rules or gateways).
 
 Unfortunately the success code is only one ( 0 ), so we cannot play with
 multiple codes. But what can be done is to add some extra message in the
 command output to indicate if some data was discarded or not.

Perhaps MI FIFO cannot be very powerful as it relies on Bash return codes.
Using MI XMLRPC the real status code is 200, 500, 404... however it doens't 
provide too much information.

Perhaps a new protocol would be useful? I imagine a reply containing status 
code, warning lines, error lines... in a standar and parseable way.

-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] load_credentials behaves wrongly when setting NULL the column

2009-10-19 Thread Iñaki Baz Castillo
El Lunes, 19 de Octubre de 2009, Bogdan-Andrei Iancu escribió:
 Hi guys,
 
 let me run some tests on this - if nothing, I will send you a patch to
 try to hunt this down.

Thanks, I couldn't reproduce the issue today, but I'm sure it happens.


-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] load_credentials behaves wrongly when setting NULL the column

2009-10-17 Thread Iñaki Baz Castillo
Hi, my susbscriber table ahs a custom column prefix. It is a VARCHAR and 
allows NULL:

  modparam(auth_db, load_credentials, $avp(AVP_USER_PREFIX)=prefix)

I use this AVP to add a prefix to the RURI.

Imagine this real example in which the wrong behaviour is shown:

- I set prefix value to 1234. It works correctly and the AVP gets that 
value.

- Later I set it to NULL. But when the users authenticates the AVP is set to 
1234 !!

- Then I set it to  (empty string but different than NULL). Then AVP has  
value (ok).

- After that I set it back to NULL. Then then the user authenticates the AVP 
gets again 1234 value !!

It doesn't occur always, but very often.


OpenSIPS 1.5 rev 5925.

I should open a bug report, right? could it be any explanation?

PS: Of course, I've checked that the value set in the database is correct.


-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] Why opensipsctl fifo dr_reload returns 0 even if it fails?

2009-10-17 Thread Iñaki Baz Castillo
Hi, after setting drouting tables with wrong values I run:

  ~# opesipsctl fifo dr_reload

The command return $? = 0 (success). However the log clearly says:

Oct 17 23:27:45 [4422] INFO:drouting:dr_reload_cmd: dr_reload MI command 
received!
Oct 17 23:27:45 [4422] ERROR:drouting:build_rt_info: invalid GW id 123123
Oct 17 23:27:45 [4422] ERROR:drouting:dr_load_routing_info: failed to add 
routing info for rule id 204 - skipping
Oct 17 23:27:45 [4422] ERROR:drouting:build_rt_info: invalid GW id 666
Oct 17 23:27:45 [4422] ERROR:drouting:dr_load_routing_info: failed to add 
routing info for rule id 206 - skipping
Oct 17 23:27:45 [4422] ERROR:drouting:build_rt_info: invalid GW id 
Oct 17 23:27:45 [4422] ERROR:drouting:dr_load_routing_info: failed to add 
routing info for rule id 207 - skipping

Shouldn't the command return != 0 in this case?


-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] fix_nated_sdp and force_rtp_proxy

2009-10-03 Thread Iñaki Baz Castillo
El Sábado, 3 de Octubre de 2009, Jan D. escribió:
 If i use fix_nated_sdp(10) and later on in my script force_rtp_proxy(),
  the result is a double ip address in the Connection Information (c).
 
 I expected force_rtp_proxy() to rewrite the ip address.
 
 Is this a bug?

No. You shouldn't call twice a function which modifies the SDP. It's he 
expected behavior.

-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Limitations of dialog module

2009-09-10 Thread Iñaki Baz Castillo
2009/9/10 Bogdan-Andrei Iancu bog...@voice-system.ro:
 Of course, all these are theoretical aspects, as personally I never
 found any implementation taking usage of these.

Yes, the same occurs to me. It seems to be an exotic feature which
just the RFC 3261 takes into account.


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Limitations of dialog module

2009-09-09 Thread Iñaki Baz Castillo
2009/9/9 Dan Pascu d...@ag-projects.com:
 So, if we simply discard the second 200OK, what will happen with UAC2?
 it will think it is in a call... waiting for ACK..

 I agree. The proxy should not discard anything. From UAC2's
 perspective the call is there, it only misses an ACK. It will keep
 retransmitting the 200 OK, until it decides to give up, unless is an
 UAC that was configured to ignore the missing ACK in which case it
 will consider that it has the call anyway and will act accordingly.

Yes, right. I must re-read the draft to know how it handles this case.
And I've read it right now and I was wrong, what this draft states is:

http://tools.ietf.org/html/draft-sparks-sip-invfix-03
--
4.  Summary of Change

   This correction document updates [RFC3261], adding a state and
   changing the transitions in the INVITE client state machine such that
   the INVITE client transaction remains in place to receive multiple
   200 OK responses.  It adds a state to the INVITE server state machine
   to absorb retransmissions of the INVITE after a 200 OK response has
   been sent.  It modifies state transitions in the INVITE server state
   machine to absorb retransmissions of the INVITE request after
   encountering a unrecoverable transport error when sending a response.
   It also forbids forwarding stray responses to INVITE requests (not
   just 200 OK responses), which RFC3261 requires.
--

So, each 200 is forwarded upstream to the UAC, but the INVITE
transaction remains in the proxy (so a retransmittion of the INVITE
from the UAC is not treated as a new request).








-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] Understanding MySQL prepared statements: no SET @variable = XXX query?

2009-09-08 Thread Iñaki Baz Castillo
Hi, when OpenSIPS uses prepared statements it generates queries as follows:


259 Connect s...@localhost on opensips
259 Query   delete from rls_watchers where expires1252395816
259 Prepare [1] delete from active_watchers where expires?
259 Execute [1] delete from active_watchers where expires1252395816



I expected that the above would be in the following way:

-
259 Connect s...@localhost on opensips
259 Query   PREPARE ps_name FROM delete from active_watchers
where expires?
259 Prepare [1] delete from active_watchers where expires?
259 Query   SET @var = 1252395816
259 Query   EXECUTE ps_name USING @var
259 Execute [1] delete from active_watchers where expires1252395816
--


This is, I expected to see a SET query as MySQL documentation about
prepared statements explains:
  http://dev.mysql.com/tech-resources/articles/4.1/prepared-statements.html

Could I know how it works without using SET query? Thanks a lot.

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] some questions about opensips

2009-09-08 Thread Iñaki Baz Castillo
2009/9/8 徐飞 kudof...@gmail.com:
 Hi Professors:

 Recently I have worked with your project opensips, to develop a system. In
 this period, I have encountered some problems...

 1. How does the project configure file (opensips.cfg) call the functions
 which are provided by the project modules. For example, function save() is
 exported in the module “registerar”, and how can the configure file call
 save(location);. How is it implemented?

Each module exports functions to be used in the config scripts. Take a
look to any module (file mod_module_name.c or module_name.c). Look
for export_functions (or similar).


 2. I have found that the configure file also called the functions which are
 not exported in the project modules, such as setflag(),setbflag(),
 isbflag(), so this time how can the configure file call them? I am a
 little confusedand I do need your help

These are core functions, not implemented in modules.


 3. What is the meaning of the data structure branch which is defined in
 the dest.c. What is it used for? Does it have the same meaning of the
 branch in the SIP protocol?

Where is that file? I don't find it...


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] rls_handle_notify() does not recognize dialog

2009-09-07 Thread Iñaki Baz Castillo
2009/9/7 Juha Heinanen j...@tutpro.com:
  on the other hand, it might be a good
 idea to check in rls server that resource list uris are valid.

In fact, more checks should be done when acting as RLS server. Imagine
a list containing an entry pointing to itself (infinite loop). Or
imagine a list containing 30 entries like
sip:blabla...@non-responding-domain.org;transport=tcp which would
consume all the TCP workers...

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [NEW] Stun Module

2009-09-07 Thread Iñaki Baz Castillo
2009/9/7 Razvan Pistolea razvy...@yahoo.com:
 There is a new STUN server(rfc 3489) module integrated in OpenSIPS.

Great!


  STUN requires 2 routable ip addresses; if in shortage create a virtual 
 interface (i don't recommend because it destroys the purpose for some usages).

What do you mean with this last phrase? why a virtual address could
break something?

Regards.



-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [OpenSIPS-Users] OpenSIPS 1.5.3 release is out

2009-08-31 Thread Iñaki Baz Castillo
2009/8/31 Bogdan-Andrei Iancu bog...@voice-system.ro:
 Debian packages are available for download:

       http://opensips.org/pub/opensips/latest/packages/debian/

 or for apt :

       http://www.opensips.org/apt/


 Packages were generated for unstable and etch.

Hi Bogdan, current Debian stable version is Lenny, not Etch ;)
IMHO there should be packages for Etch (old stable), Lenny (current
stable) and unstable.

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] [xcap table] Mapping between doc_type column and XCAP document type?

2009-08-30 Thread Iñaki Baz Castillo
Hi, could I know the exact mapping which identifies a XCAP document type with 
a integer value in the xcap table doc_type column?

Thanks.


-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [xcap table] Mapping between doc_type column and XCAP document type?

2009-08-30 Thread Iñaki Baz Castillo
El Domingo, 30 de Agosto de 2009, Adrian Georgescu escribió:
 app_mapping = {pres-rules   : 1,
 resource-lists   : 2,
 rls-services : 3,
 pidf-manipulation: 4
 }

Thanks Adrian.

-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] rls_handle_subscribe() return code when list is not found

2009-08-28 Thread Iñaki Baz Castillo
2009/8/28 Juha Heinanen j...@tutpro.com:
 from rls tutorial document:

 http://www.opensips.org/Resources/Rls

 i get impression that rls_handle_subscribe() should return
 to_presence_code, if resource list document is not found in xcap server.

 however, when i read the code, it has:

                if(doc== NULL|| service_node==NULL)
                {
                        LM_DBG(list not found - search for uri = 
 %.*s\n,subs.pres_uri.len,
                                subs.pres_uri.s);
                        reply_code = 404;
                        reply_str = pu_404_rpl;
                        goto error;
                }

 is this a bug?  if not, i don't see how a normal handle_subscribe()
 can be tried if rls document doesn't exit.

I haven't inspected the code, but  rls_handle_subscribe() does what
it's supposed to do (return the preconfigured to $rc when no RL doc is
found).


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] [pres-rules] active_watchers has entries with status = 3 (terminated) and reason rejected (it shouldn't)

2009-08-25 Thread Iñaki Baz Castillo
Hi Anca :)

I've blocked a watcher by inserting it in a blocked section of my
pres-rules. Inmedaitelly OpenSIPS sends a NOTIFY
terminated;status=deactivated, right.
The watcher subscribes again and it should receive pending but it
receives terminated;status=rejected. Because it, the watcher doesn't
try to subscribe anymore.
At this time, there are two entries in active_watchers for this
watcher and same presentity, both with status 3 and reason rejected.

Wouldn't be better to remove entries with status 3 from the
active_watcher table and reply pending?


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Idea: Presence composer module

2009-08-24 Thread Iñaki Baz Castillo
2009/8/24 Anca Vamanu a...@opensips.org:
 Hi Inaki,

 The truth is that indeed there is no definition in RFC on how the
 documents should be composed. What the presence module does at the
 moment is to keep the first person node and add all the tuples nodes.
 But this is not good enough in all cases, one being your example. So I
 believe that your module proposition might be useful.
 I understand that what you propose is to have a module that deals with
 aggregation and when aggregation is needed to call function from there.
 Also I suppose that the aggregation itself should be configurable and
 the rules dynamically defined. And also the aggregation functions should
 be per event.

Yes, that's the point. OMA has specifications for this purpose (for
example to mix tuples with same id and so). Let me look for them.


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] Idea: Presence composer module

2009-08-20 Thread Iñaki Baz Castillo
Hi, I'm thinking that perhaps a feature/module called presence composer 
could be useful for SIP environments with rich presence usage.

Example:

- A user publishes a presentity person section using XCAP for static data 
(display name, photo icon...). In this way, if I susbscribe to the presentity 
of this AoR, I could also receive those data (as in MSN network).
- But what about if the device also publishes a presentity person section 
(with also a tuple section) using normal SIP PUBLISH? In that case OpenSIPS 
presence agent would append it to the presentity published via XCAP. Most 
probably, the watcher would discard one of these person sections and loose 
useful info about display name, icon and so on.
- It would be useful if a new presence composer module could mix both 
person sections giving priority to the section published via SIP PUBLISH but 
keeping the data of the XCAP presentity not present in the SIP PUBLISH. This 
is: if the person section in the PUBLISH contains just display-name info 
then this would replace the display name in the XCAP presentity, but the icon 
of the XCAP presentity would be present in the composed person section.

This is just an example, I could imagine more cases in with such feature would 
be useful. Also, the concept of presence watcher exists in presence related 
RFC's (but of course is not defined at all).

What do you think?

Regards.



-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] SF.net SVN: opensips:[5942] trunk/modules/presence_xml/xcap_auth.c

2009-08-10 Thread Iñaki Baz Castillo
2009/8/7 Iñaki Baz Castillo i...@aliax.net:
 After bob dissapears in alice's pres-rules, the entry in
 active_watchers is removed, but a new one is created for the new
 subscription coming from bob (after receiving the NOTIFY
 terminated;reason=deactivated).

 The problem is that the new entry in active_watcher has status 1 while
 it should be 3 (pending).


The following illustrates the issue:


- bob is allowed by alice. An entry with status 1 (active) is
present in active_watchers.

- Now alice removes bob from the pres-rules so OpenSIPS generates this
correct NOFITY:

U 2009/08/11 01:26:01.033525 99.221.79.216:5065 - 99.221.79.216:5060
NOTIFY sip:b...@85.84.170.107:6060 SIP/2.0'
Via: SIP/2.0/UDP 99.221.79.216:5065;branch=z9hG4bK44c2.36fba581.0'
To: sip:b...@example.net;tag=ipwps'
From: sip:al...@example.net;tag=5e49c2c8b7a2795ddc4f373ff7fed527-925a'
CSeq: 3 NOTIFY'
Call-ID: zdaljrilplvt...@barakaldo'
Route: sip:99.221.79.216;lr=on;ftag=ipwps'
Content-Length: 0'
User-Agent: OpenSIPS (1.6.0dev0-notls (x86_64/linux))'
Max-Forwards: 70'
Event: presence'
Contact: sip:prese...@99.221.79.216:5065'
Subscription-State: terminated;reason=deactivated'
'


- Inmediatelly bob subscribes again:

##
U 2009/08/11 01:26:01.210697 99.221.79.216:5060 - 99.221.79.216:5065
SUBSCRIBE sip:al...@example.net SIP/2.0'
Record-Route: sip:99.221.79.216;lr=on;ftag=qoqsj'
Via: SIP/2.0/UDP 99.221.79.216;branch=z9hG4bK2aa.b16f23c.0'
Via: SIP/2.0/UDP
85.84.170.107:6060;received=85.84.170.107;rport=6060;branch=z9hG4bKdittkcfb'
Max-Forwards: 70'
To: sip:al...@example.net'
From: Bob sip:b...@example.net;tag=qoqsj'
Call-ID: gqddceauwnfq...@barakaldo'
CSeq: 111 SUBSCRIBE'
Contact: sip:b...@85.84.170.107:6060'
Accept: application/pidf+xml'
Event: presence'
Expires: 3600'
User-Agent: Twinkle/1.3.2'
Content-Length: 0'
'


- ERROR: OpenSIPS sends a NOTIFY with active status:

##
U 2009/08/11 01:26:01.214601 99.221.79.216:5065 - 99.221.79.216:5060
NOTIFY sip:b...@85.84.170.107:6060 SIP/2.0'
Via: SIP/2.0/UDP 99.221.79.216:5065;branch=z9hG4bK72be.aaa09473.0'
To: sip:b...@example.net;tag=qoqsj'
From: sip:al...@example.net;tag=5e49c2c8b7a2795ddc4f373ff7fed527-3cda'
CSeq: 1 NOTIFY'
Call-ID: gqddceauwnfq...@barakaldo'
Route: sip:99.221.79.216;lr=on;ftag=qoqsj'
Content-Length: 215'
User-Agent: OpenSIPS (1.6.0dev0-notls (x86_64/linux))'
Max-Forwards: 70'
Event: presence'
Contact: sip:prese...@99.221.79.216:5065'
Subscription-State: active;expires=3590'
Content-Type: application/pidf+xml'
'
?xml version=1.0 encoding=UTF-8?
presence xmlns=urn:ietf:params:xml:ns:pidf entity=sip:al...@example.net
  tuple id=njfsvs
status
  basicopen/basic
/status
  /tuple
/presence


- At this point, the previous entry in active_watchers has been
deleted, but the new one (originated by the new SUBSCRIBE) exists with
status 1 (while it should be pending as bob doesn't appear in the
pres-rules document).


Note that it doesn't matter if the new subscription (After
deactivated) is instant or not. The issue occurs in both cases (I've
also tryed with sip_subscribe_presence command line utility (AG) to
repeat the subscription long time ago (2 minutes) after receiving the
deactivated.

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] SF.net SVN: opensips:[5943] trunk/modules/presence_xml/xcap_auth.c

2009-08-08 Thread Iñaki Baz Castillo
2009/8/7 Iñaki Baz Castillo i...@aliax.net:
 It works better now, but now when I block *explicitely* a user in the
 pres-rules document, and OpenXCAP sends the MI command (via
 opensips-mi-command) it receives:

 T 2009/08/07 16:07:05.370217 127.0.0.1:8080 - 127.0.0.1:34777 [AP]
 HTTP/1.1 500 Internal Server Error'
 Date: Fri, 07 Aug 2009 14:07:05 GMT'
 Content-Length: 201'
 Content-Type: text/html'
 Server: Twisted/8.1.0 TwistedWeb/[twisted.web2, version 8.1.0]'
 Connection: close'
 '
 htmlheadtitleInternal Server
 Error/title/headbodyh1Internal Server Error/h1An error
 occurred rendering the requested page. More information is available
 in the server log./body/html

ok, this occurs because opensips crashes. I've 4 coredumps from
yesterday when testing the new XCAP feature.
I'll try to inspect them.


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] SF.net SVN: opensips:[5943] trunk/modules/presence_xml/xcap_auth.c

2009-08-08 Thread Iñaki Baz Castillo
2009/8/8 Iñaki Baz Castillo i...@aliax.net:
 2009/8/7 Iñaki Baz Castillo i...@aliax.net:
 It works better now, but now when I block *explicitely* a user in the
 pres-rules document, and OpenXCAP sends the MI command (via
 opensips-mi-command) it receives:

 T 2009/08/07 16:07:05.370217 127.0.0.1:8080 - 127.0.0.1:34777 [AP]
 HTTP/1.1 500 Internal Server Error'
 Date: Fri, 07 Aug 2009 14:07:05 GMT'
 Content-Length: 201'
 Content-Type: text/html'
 Server: Twisted/8.1.0 TwistedWeb/[twisted.web2, version 8.1.0]'
 Connection: close'
 '
 htmlheadtitleInternal Server
 Error/title/headbodyh1Internal Server Error/h1An error
 occurred rendering the requested page. More information is available
 in the server log./body/html

 ok, this occurs because opensips crashes. I've 4 coredumps from
 yesterday when testing the new XCAP feature.
 I'll try to inspect them.


(gdb) bt
#0  0x2b2b82c96ac9 in db_mysql_val2bind (v=0x7fff289be290,
binds=0x7539e8, i=value optimized out) at val.c:254
#1  0x2b2b82c924c6 in db_mysql_do_prepared_query (conn=0x743010,
query=0x2b2b82ea96d0, v=0x7fff289bde80, n=2, uv=0x7fff289be250, un=4)
at dbase.c:446
#2  0x2b2b82c93a7f in db_mysql_update (_h=0x743010,
_k=0x7fff289be310, _o=0x0, _v=0x7fff289be250, _uk=0x7fff289bdf20,
_uv=0x7fff289bde80, _n=4, _un=2) at dbase.c:921
#3  0x2b2b853cb010 in pres_update_status (subs=
  {pres_uri = {s = 0x74342b
sip:al...@oversip.net\\n\presence\\n\0\\n, len = 21}, to_user =
{s = 0x30 Address 0x30 out of bounds, len = 7682328}, to_domain = {s
= 0x300028 Address 0x300028 out of bounds, len = 681304640},
from_user = {s = 0x7535b8 bob�, len = 3}, from_domain = {s =
0x7535f0 oversip.net, len = 11}, event = 0x2b2b8692a908, event_id =
{s = 0x2b2b82a7b9e0 , len = 9766904}, to_tag = {s = 0x2b2b82a7b9e0
, len = 9704240}, from_tag = {s = 0x2e7 Address 0x2e7 out of
bounds, len = 8}, callid = {s = 0x6e87a8 \b�e\206++, len =
681305056}, sockinfo = 0x2b2b827a2a56, remote_cseq = 0, local_cseq =
0, contact = {s = 0x2b2b82a7b9e0 , len = 7501728}, local_contact =
{s = 0x2e7 Address 0x2e7 out of bounds, len = 8}, record_route = {s
= 0x6e87a8 \b�e\206++, len = 681305056}, expires = 2189044310,
status = 1, reason = {s = 0x0, len = 0}, version = -2055260448,
db_flag = 502, auth_rules_doc = 0x753610, next = 0x1}, reason={s =
0x954a82 ded val (3): len=8; type=254; is_null=0\n, len = 0},
query_cols=0x7fff289be310,
query_vals=0x7fff289be250, n_query_cols=value optimized out,
subs_array=0x7fff289be390) at presence.c:652
#4  0x2b2b853cca2b in update_watchers_status (pres_uri={s =
0x74342b sip:al...@oversip.net\\n\presence\\n\0\\n, len = 21},
ev=0x2b2b8692a908,
rules_doc=value optimized out) at presence.c:884
#5  0x2b2b853cd188 in mi_refreshWatchers (cmd=value optimized
out, param=value optimized out) at presence.c:532
#6  0x2b2b82a84591 in mi_datagram_server (rx_sock=17, tx_sock=18)
at ../../mi/mi.h:104
#7  0x2b2b82a86168 in datagram_process (rank=0) at mi_datagram.c:310
#8  0x00458de9 in start_module_procs () at sr_module.c:585
#9  0x0042343d in main (argc=value optimized out,
argv=0x7fff289be7f8) at main.c:837
(gdb)





(gdb) bt full
#0  0x2b2b82c96ac9 in db_mysql_val2bind (v=0x7fff289be290,
binds=0x7539e8, i=value optimized out) at val.c:254
t = value optimized out
mt = value optimized out
__FUNCTION__ = db_mysql_val2bind
#1  0x2b2b82c924c6 in db_mysql_do_prepared_query (conn=0x743010,
query=0x2b2b82ea96d0, v=0x7fff289bde80, n=2, uv=0x7fff289be250, un=4)
at dbase.c:446
i = 2
code = value optimized out
cols = value optimized out
pq_ptr = (struct prep_stmt *) 0x7539a8
ctx = (struct my_stmt_ctx *) 0x7537c0
mysql_bind = (MYSQL_BIND *) 0x7539e8
__FUNCTION__ = db_mysql_do_prepared_query
#2  0x2b2b82c93a7f in db_mysql_update (_h=0x743010,
_k=0x7fff289be310, _o=0x0, _v=0x7fff289be250, _uk=0x7fff289bdf20,
_uv=0x7fff289bde80, _n=4, _un=2) at dbase.c:921
ret = 0
#3  0x2b2b853cb010 in pres_update_status (subs=
  {pres_uri = {s = 0x74342b
sip:al...@oversip.net\\n\presence\\n\0\\n, len = 21}, to_user =
{s = 0x30 Address 0x30 out of bounds, len = 7682328}, to_domain = {s
= 0x300028 Address 0x300028 out of bounds, len = 681304640},
from_user = {s = 0x7535b8 bob�, len = 3}, from_domain = {s =
0x7535f0 oversip.net, len = 11}, event = 0x2b2b8692a908, event_id =
{s = 0x2b2b82a7b9e0 , len = 9766904}, to_tag = {s = 0x2b2b82a7b9e0
, len = 9704240}, from_tag = {s = 0x2e7 Address 0x2e7 out of
bounds, len = 8}, callid = {s = 0x6e87a8 \b�e\206++, len =
681305056}, sockinfo = 0x2b2b827a2a56, remote_cseq = 0, local_cseq =
0, contact = {s = 0x2b2b82a7b9e0 , len = 7501728}, local_contact =
{s = 0x2e7 Address 0x2e7 out of bounds, len = 8}, record_route = {s
= 0x6e87a8 \b�e\206++, len = 681305056}, expires = 2189044310,
status = 1, reason = {s = 0x0, len = 0}, version = -2055260448,
db_flag = 502, auth_rules_doc = 0x753610, next = 0x1

Re: [OpenSIPS-Devel] SF.net SVN: opensips:[5943] trunk/modules/presence_xml/xcap_auth.c

2009-08-08 Thread Iñaki Baz Castillo
Coredump available here:

  http://oversip.net/public/core.opensips.sig11.25252



-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] SF.net SVN: opensips:[5942] trunk/modules/presence_xml/xcap_auth.c

2009-08-07 Thread Iñaki Baz Castillo
2009/8/7 Anca Vamanu a...@opensips.org:
 Revision: 5942
          http://opensips.svn.sourceforge.net/opensips/?rev=5942view=rev
 Author:   anca_vamanu
 Date:     2009-08-07 11:55:06 + (Fri, 07 Aug 2009)

 Log Message:
 ---
 - changed status to terminated, reason deactivated if previous status was 
 active and no rules were found for the watcher

 Modified Paths:
 --
    trunk/modules/presence_xml/xcap_auth.c


Something is wrong:

- bob is not allowed by alice so receives pending (OK).

- alice allows bob via XCAP pres-rules so bob receives a NOTIFY active (OK).

- alice deletes bob from the pres-rules and OpenSIPS sends a NOTIFY to
bob with terminated;reason=deactivated.

- Immediately bob sends a new initial SUBSCRIBE.

- OpenSIPS replies a NOTIFY active containing the presentity body.
This is, bob is allowed to see the status of alice.


Tested and re-tested.

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] SF.net SVN: opensips:[5942] trunk/modules/presence_xml/xcap_auth.c

2009-08-07 Thread Iñaki Baz Castillo
2009/8/7 Iñaki Baz Castillo i...@aliax.net:
 Something is wrong:

 - bob is not allowed by alice so receives pending (OK).

 - alice allows bob via XCAP pres-rules so bob receives a NOTIFY active (OK).

 - alice deletes bob from the pres-rules and OpenSIPS sends a NOTIFY to
 bob with terminated;reason=deactivated.

 - Immediately bob sends a new initial SUBSCRIBE.

 - OpenSIPS replies a NOTIFY active containing the presentity body.
 This is, bob is allowed to see the status of alice.


 Tested and re-tested.


active_watcher tables shows status = 1 (actived)


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] SF.net SVN: opensips:[5942] trunk/modules/presence_xml/xcap_auth.c

2009-08-07 Thread Iñaki Baz Castillo
2009/8/7 Anca Vamanu a...@opensips.org:
 Something is wrong:

 - bob is not allowed by alice so receives pending (OK).

 - alice allows bob via XCAP pres-rules so bob receives a NOTIFY active
 (OK).

 - alice deletes bob from the pres-rules and OpenSIPS sends a NOTIFY to
 bob with terminated;reason=deactivated.

 - Immediately bob sends a new initial SUBSCRIBE.

 - OpenSIPS replies a NOTIFY active containing the presentity body.
 This is, bob is allowed to see the status of alice.


 Tested and re-tested.



 Can you please check one extra things for me?
 After alice deletes bob from pres-rules, can you do a select * from watchers
 where  presentity_uri=sip:al...@domain.com and watcher_username=bob.
 There should be no entry there.

After bob dissapears in alice's pres-rules, the entry in
active_watchers is removed, but a new one is created for the new
subscription coming from bob (after receiving the NOTIFY
terminated;reason=deactivated).

The problem is that the new entry in active_watcher has status 1 while
it should be 3 (pending).




-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] SF.net SVN: opensips:[5942] trunk/modules/presence_xml/xcap_auth.c

2009-08-07 Thread Iñaki Baz Castillo
2009/8/7 Anca Vamanu a...@opensips.org:
 The XCAP pres-rules document interpretation part was not changed and I don't
 think that there are problems in there. Can you send me the pres rules
 document after deleting bob from alice pres rules?

It's a simple pres-rules document generated by AG xcapclient
application. After deleting bob it looks like:

?xml version='1.0' encoding='UTF-8'?
cp:ruleset xmlns:pr=urn:ietf:params:xml:ns:pres-rules
xmlns:cp=urn:ietf:params:xml:ns:common-policy
  cp:rule id=pres_whitelist
cp:conditions
  cp:identity
cp:one id=sip:al...@example.net/
cp:one id=sip:eyeb...@example.net/
cp:one id=sip:y...@example.net/
  /cp:identity
/cp:conditions
cp:actions
  pr:sub-handlingallow/pr:sub-handling
/cp:actions
cp:transformations
  pr:provide-services
pr:all-services/
  /pr:provide-services
  pr:provide-persons
pr:all-persons/
  /pr:provide-persons
  pr:provide-devices
pr:all-devices/
  /pr:provide-devices
  pr:provide-all-attributes/
/cp:transformations
  /cp:rule
/cp:ruleset





-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] SF.net SVN: opensips:[5942] trunk/modules/presence_xml/xcap_auth.c

2009-08-07 Thread Iñaki Baz Castillo
2009/8/7 Anca Vamanu a...@opensips.org:
 From what I understand, you consoder that also from a TERMINATED status no
 matter the reason, if the watcher is deleted from the pres-rules, the status
 should change to TERMINATED, reason=deactivated and deleted as so that it
 will be reevaluated as pending the next time?I did not include this case,
 but I will include it now.

Yes, I think so. Note that a pres-rules doesn't allow by default
except if there is a explicit rule allowing an user.
If bob is allowed and later it's removed from the document, or changed
to a blocked rule it should be the same and bob should receive a
terminated;reason=deactivated (IMHO).

Regards.


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] SF.net SVN: opensips:[5943] trunk/modules/presence_xml/xcap_auth.c

2009-08-07 Thread Iñaki Baz Castillo
2009/8/7 Iñaki Baz Castillo i...@aliax.net:
 It works better now, but now when I block *explicitely* a user in the
 pres-rules document, and OpenXCAP sends the MI command (via
 opensips-mi-command) it receives:

 T 2009/08/07 16:07:05.370217 127.0.0.1:8080 - 127.0.0.1:34777 [AP]
 HTTP/1.1 500 Internal Server Error'
 Date: Fri, 07 Aug 2009 14:07:05 GMT'
 Content-Length: 201'
 Content-Type: text/html'
 Server: Twisted/8.1.0 TwistedWeb/[twisted.web2, version 8.1.0]'
 Connection: close'
 '
 htmlheadtitleInternal Server
 Error/title/headbodyh1Internal Server Error/h1An error
 occurred rendering the requested page. More information is available
 in the server log./body/html


 I must inspect if it's an error in opensips, opensips-mi-command


Sometimes occurs, sometimes no...
I've detected various wrong behaviours right now but couldn't explain
them in detail.
Please let me some time to do it properly.


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Limitations of dialog module

2009-08-04 Thread Iñaki Baz Castillo
2009/8/4 Dan Pascu d...@ag-projects.com:
 The easiest way to fix them would be for the dialog module to keep around
 virtual dialogs, for as long as it's in a provisional state. Such a virtual
 dialog will keep track of a branch and when a final reply is received, it will
 destroy all of them except for the one on the branch that got the final 200 OK
 reply, which will become the real dialog from that point on. This way each
 branch can live on its own and have the CSeq updated independently of the
 others.

That makes sense but, what would occur in the exotice RFC3261 case in
which  two (or more) 200 OK replies are received at the same time?
AFAIK for now OpenSIPS terminates the INVITE transaction (not 100%
true since it matches the following ACK) when the first 200 arrives,
so the second 200 is bypassed stateless to the UAC. In this moment the
UAC has two active dialogs and should terminate the second one
(sending an ACK followed by a BYE).

However, there is a draft
(http://tools.ietf.org/html/draft-sparks-sip-invfix) updating this
behaviour so the proxy keeps the transaction in memory after receipt
of the first 200 and absorvbs other 200 replies. I added a tm
parameter in Kamailio for this purpose (it basically drops any reply
matching no transaction):
  http://kamailio.org/docs/modules/1.6.x/tm.html#id2530689

But if this behaviour is not implemented, could it affect the design
you suggest for virtual dialogs?

Regards.


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [presence_xml - XCAP] Using a link to resource-list into a pres-rules condition

2009-08-04 Thread Iñaki Baz Castillo
2009/8/4 Anca Vamanu a...@opensips.org:
 Hi Inaki,

 No, presence_xml does not support included resouce-lists documents neither
 in pres-rules nor in rls-services documents.

Is it planned for a future?
Note that some more strict specifications on top of IETF' XCAP (which
specify nothing) require this feature working.

Regards.

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Limitations of dialog module

2009-08-04 Thread Iñaki Baz Castillo
2009/8/4 Dan Pascu d...@ag-projects.com:
 But if this behaviour is not implemented, could it affect the design
 you suggest for virtual dialogs?

 Not if we confirm the dialog with the ACK instead of the 200 OK.

If both 200 OK arrive to the UAC, it will generate two ACK (one for
each branch). Theoricaly the UAC will also send a BYE for the last 200
received.

This is:

- UAS1 replies 200.
- UAS2 replies 200 (at the same time).
- OpenSIPS routes the first 200 stateful to the UAC.
- OpenSIPS routes the second 200 stateless to the UAC.
- UAC generates an ACK for first 200.
- OpenSIPS create a established dialog.
- UAC generates an ACK for the second 200.
* Would OpenSIPS generate a new *established* dialog?
- UAC sends inmediately a BYE for the second dialog (as RFC3261 states).
* Would this BYE terminate the second established diaog in OpenSIPS?
or the first one? or both?

This is the risk I see.

Regards.





-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [presence_xml - XCAP] Using a link to resource-list into a pres-rules condition

2009-08-04 Thread Iñaki Baz Castillo
2009/8/4 Anca Vamanu a...@opensips.org:
 No, presence_xml does not support included resouce-lists documents
 neither
 in pres-rules nor in rls-services documents.


 Is it planned for a future?
 Note that some more strict specifications on top of IETF' XCAP (which
 specify nothing) require this feature working.

 Regards.



 Yes, we plan on implementing it, but only for local documents. So if in
 integrated_xcap_server mode, the search will be done also in the xcap table.

That's would be more than enough :)



-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Limitations of dialog module

2009-08-04 Thread Iñaki Baz Castillo
2009/8/4 Bogdan-Andrei Iancu bog...@voice-system.ro:
 In 1.5 there was a stateless / statefull checking add - if you do not
 statefully relay any requests (based on auto script detection), the core
 will drop all stateless replies also. See
 http://www.opensips.org/Main/Ver150#toc4

ok, that's the same as doing:

onreply_route[0] {
  if ! check_trans()
drop();
}


Right?

Thanks.

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [Fwd: Re: [NEW] Virtual DB module]

2009-07-31 Thread Iñaki Baz Castillo
2009/7/31 Dan Pascu d...@ag-projects.com:
 On Thursday 30 July 2009, Razvan Pistolea wrote:
 2. Synchronization between dbs will be lost.

 3b.        use database managers (that know how to merge databases)
 3c.        use a cluster db

 That sounds good in theory, but in practice fails in so many ways. I've worked
 with this for years and even after so much time bidirectional database
 replication is extremely fragile and fails easily. Just one example:

 You start writing to db1, it performs the operation just fine, but right after
 it finished and is about to return you the success response to your query you
 lose the connection. If never see the answer, assume it failed and go on to
 write the record to db2, which succeeds as well and also returns the answer.
 Now you have the same record in both databases and when they will try to
 replicate from each other they'll fail. The problem gets even worse with
 multiple databases that replicate from each other.

 This is not just a theoretical example. I've seen this on a constant basis
 when performing a simple operation like heartbeat stop on the master to move
 the services to the slave, while somebody writes into the database as the same
 time (like for example opensips writing accounting requests for something as
 modest as 1.5 calls per second). This is so common, that you can consider
 yourself lucky if replication is not broken between the 2 databases when you
 stop one to activate the other, without taking measures to stop the influx of
 write operations to them during the switch.

Very good points. master-master replication or master-slave becoming
inactive-master is really a pain, I've also suffered it a lot.

I wonder if filesystem based replication (i.e. BRBD) is a more
reliable choice even if it could seem fragile (it's a binary
replication, so a single error could entirely corrupt the database).
About it, I've listened every kind of opinions, so... :)



-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [Fwd: Re: [NEW] Virtual DB module]

2009-07-30 Thread Iñaki Baz Castillo
2009/7/30 Razvan Pistolea razvy...@yahoo.com:

 Hi Iñaki,

 1. When in PARALLEL mode and an operation fails the connection to that db url 
 will be closed.

 2. Synchronization between dbs will be lost.

 3. Ways to realize synchronization would be:
 3a.        save all operations and values (whenever a db fails at least for 
 the duration of the failure)
                feasible but not desired or required due to the way curent 
 modules use dbs
 3b.        use database managers (that know how to merge databases)
 3c.        use a cluster db

 4. A response code at this time is given only if all dbs fail.
 Other modules interpret return codes as: (succes =0 or succes 0 (some) ) and 
 (fail 0) not caring about [partial success].
 So a response != 0 for some modules will mean that the operation failed (even 
 though only some db failed).
 A response code could also be given when failover switches to a new db (even 
 though the operation on the new db succceds).

Thanks for clarify it.


 Could you please explain what do you need the response code for? (there might 
 be other ways to achieve extra operation information)

Forget it. It should be handled as DB level :)



-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Interaction with Mobicents XDMS

2009-07-29 Thread Iñaki Baz Castillo
2009/7/29 Andaleeb Roomy andaleeb...@gmail.com:
 Could you do a ngrep/wireshark capture of the HTTP traffic to see what
 is going on at http level?

Some example?



-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Interaction with Mobicents XDMS

2009-07-27 Thread Iñaki Baz Castillo
2009/7/27 Andaleeb Roomy andaleeb...@gmail.com:
 I am trying to retrieve an XML document from a third party XDMS
 (Mobicents). But I am getting some errors:


 Jul 27 11:31:16 [14648] DBG:presence_xml:get_rules_doc: No document
 found in db table for [user]=andaleeb1  [domain]=
 192.168.0.133   [doc_type]= 2
 * About to connect() to 192.168.0.130 port 8080 (#0)
 *   Trying 192.168.0.130... * connected
 * Connected to 192.168.0.130 (192.168.0.130) port 8080 (#0)
 GET 
 /mobicents/org.openmobilealliance.pres-rules/users/sip:andale...@192.168.0.133/pres-rules
  HTTP/1.1

 Host: 192.168.0.130:8080

 Accept: */*

Could you do a ngrep/wireshark capture of the HTTP traffic to see what
is going on at http level?

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] pres_rules: Does presence_xml uses sphere element?

2009-07-15 Thread Iñaki Baz Castillo
2009/7/15 Anca Vamanu a...@opensips.org:
 Hi Inaki,

 Yes there is a sphere implementation in Opensips PA but it is not maybe the
 most correct one. If a sphere condition is encountered, the PA searches in
 the most recent published body for a sphere definition. If one is found,
 then it is evaluated if it matches the one in the condition.

ok

 If no sphere
 definition is found then the condition is evaluated as true.

This is incorrect (IMHO) and explains some strange issues I've detected.
For example, EyeBeam uses a custom pres-rules document which also
includes rules for IM and call (and of course also por presence).
Theorically pres-rules is just for presence.

Fortunatelly, the rules for IM and call authorization sent by
EyeBeam includes a sphere which custom values as im_whitelist,
call_whitelist and so. Since nobody (neither EyeBeam) publishes a
presence document containing sphere value, this means that the rules
for IM and calls will *never* match and the PA should *ignore* them.
In this way, a user allowed for IM but not for presence wouldn't be
matched as allowed by OpenSIPS PA.

I know that EyeBeam makes a custom usage of pres-rules document, but
it *is* RFC compliant: the custom rules (for IM and calls) include a
never matched sphere so PA should never match them.


 I see now that this does not respect the RFC which says that the sphere must
 be searched in all bodies.

Note also that sphere can have multiple values separated by space.



-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] pres_rules: Does presence_xml uses sphere element?

2009-07-14 Thread Iñaki Baz Castillo
Hi, according to RFC 4745 (Common Policy for Private Preferences) an
user can publish a sphere element, i.e:

  spherehome//sphere

These attribute sphere could appear as a condition in the pres-rules
document (rfc4480#section-3.11):

 rule id=f3g44r2
   conditions
 sphere value=work/
 identity
   one id=sip:and...@example.com/
 /identity
   /conditions
   actions/
   transformations/
 /rule

So the presence agent should check if the current sphere value for the
presentity matches the sphere value in the rule conditions.
Of course this is really complex since there could be multiple PUBLISH
at the same time, each one with different sphere value.

For me it's too much exotic, but does OpenSIPS consider it?


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] pres_rules: Does presence_xml uses sphere element?

2009-07-14 Thread Iñaki Baz Castillo
2009/7/14 Iñaki Baz Castillo i...@aliax.net:
 So the presence agent should check if the current sphere value for the
 presentity matches the sphere value in the rule conditions.
 Of course this is really complex since there could be multiple PUBLISH
 at the same time, each one with different sphere value.

 For me it's too much exotic, but does OpenSIPS consider it?


RFC 5025:

-
3.1.2.  Sphere

   The sphere element is defined in [8].  However, each application
   making use of the common policy specification needs to determine how
   the presence server computes the value of the sphere to be used in
   the evaluation of the condition.

   To compute the value of sphere, the presence agent examines all
   published presence documents for the presentity.  If at least one of
   them includes the sphere element [9] as part of the person data
   component [10], and all of those containing the element have the same
   value for it, which is the value used for the sphere in presence
   policy processing.  If, however, the sphere element was not present
   in any of the published documents, or it was present but had
   inconsistent values, its value is considered undefined in terms of
   presence policy processing.

   Care must be taken in using sphere as a condition for determining
   the subscription handling.  Since the value of sphere changes
   dynamically, a state change can cause a subscription to be suddenly
   terminated.  The watcher has no way to know, aside from polling, when
   their subscription would be reinstated as the value of sphere
   changes.  For this reason, sphere is primarily useful for matching
   on rules that define transformations.
--


Could I know what does the last phrase mean?:

  sphere is primarily useful for matching  on rules that define
transformations.





-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] How does presence_xml implement RFC 5025 transformations?

2009-07-14 Thread Iñaki Baz Castillo
Hi, RFC 5025 specifies transformations:
  http://tools.ietf.org/html/rfc5025#section-3.3

This means that a presence document could be filtered before being
sent to the watcher. For example:

  3.3.1.2.  Person Information
   The provide-persons permission allows a watcher to see the person
   information present in the presence document [...]

Does presence_xml implement it?
Could I know in detail how this RFC is implemented?

Thanks a lot.

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] dialog.info event package?

2009-07-13 Thread Iñaki Baz Castillo
El Lunes, 13 de Julio de 2009, Adrian Georgescu escribió:
 It occurs to me that when one wants to properly implement the dialog
 event package in an end-point it also needs:

 a) A way to provision policy
 b) A way to be notified about watchers

 For Event=presence we have pres-rules for a) and presence.winfo for
 b). Dialog-rules and dialog.winfo seem to be a mirrored way to do the
 similar but for dialog event.

 Does anyone have any better idea for how to accomplish the above?

The provision policy (using XCAP?) is not defined by IETF. However, using 
dialog.winfo is the expected way since winfo package is defined for any kind 
of event type.


-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] SF.net SVN: opensips:[5835] trunk/modules/pua_dialoginfo

2009-07-07 Thread Iñaki Baz Castillo
2009/7/7 Klaus Darilion klaus.mailingli...@pernau.at:
 Hi Anca!

 Nice feature, missing since long time :-)

 If I understand the code, this triggers PUBLISH with trying even if
 the dialog is not created (e.g. script error after dialoginfo_set()).

 In this case, it will stay in trying state for default lifetime.

 Wouldn't it be better to send trying also from a callback.

PUBLISH dialog with trying state is in fact a NOOP and it's not
useful at all from the watcher's perspective. I suggest never to
publish it.

Also, the proceeding state means that a 1xx with no To tag (this is,
a 100) has been received. This is also not useful, so I wouldn't
publish it.

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] SF.net SVN: opensips:[5835] trunk/modules/pua_dialoginfo

2009-07-07 Thread Iñaki Baz Castillo
2009/7/7 Klaus Darilion klaus.mailingli...@pernau.at:
 PUBLISH dialog with trying state is in fact a NOOP and it's not
 useful at all from the watcher's perspective. I suggest never to
 publish it.

 Also, the proceeding state means that a 1xx with no To tag (this is,
 a 100) has been received. This is also not useful, so I wouldn't
 publish it.

 IMO it is useful - eg. A calls PSTN and the call setup takes long - e.g. 10
 seconds until ringing. In this time intervall, A is already busy on the
 phone, thus other probably will get notified that A is currently on the
 phone and the will try to reach him later.

Othe example:

- A is subscribed to dialog presence of C.
- B calls C.
- The proxy generates a dialog trying PUBLISH (C is called) and sends it to A.
- A sees in his phone that C is begin called by B.
- However, due to some network error (or C crashed) C doesn't reply to
the INVITE (neither 100 or 1XX).

In this case, why is useful the NOTIFY A has received?
Or perhaps the trying and preceeding NOTIFY would only be received
by A in case C is the caller?



-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Access rules for dialog state?

2009-07-07 Thread Iñaki Baz Castillo
2009/7/7 Adrian Georgescu a...@ag-projects.com:
 For the lack of other pragmatic methods I would implement the following:

 A. Suport in OpenXCAP server a new auid, document name dialog-rules with the
 clear purpose of providing an authorization policy for dialog Event
 B. Setup the OpenSIPS PA module that handles the dialog event to read it in
 order to apply a policy, the same as presence_xml does with pres-rules

 Does anyone see a problem with this approach?

I think that is the expected approach :)
However, I would like to receive replies in sip-implementors.

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Access rules for dialog state?

2009-07-07 Thread Iñaki Baz Castillo
2009/7/7 Adrian Georgescu a...@ag-projects.com:
 I think that is the expected approach :)
 However, I would like to receive replies in sip-implementors.

 I thought we are the SIP implementors ;-)

100% agree :)


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] SF.net SVN: opensips:[5835] trunk/modules/pua_dialoginfo

2009-07-07 Thread Iñaki Baz Castillo
El Martes, 7 de Julio de 2009, Adrian Georgescu escribió:
 Inaki,

 Should the dialog timeout in this case?

Sorry, what do you mean? I couldn't understand.

-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] SF.net SVN: opensips:[5835] trunk/modules/pua_dialoginfo

2009-07-07 Thread Iñaki Baz Castillo
El Martes, 7 de Julio de 2009, Adrian Georgescu escribió:
 When a dialog times out, other actions can be triggered like updating
 the state for event dialog. Same as we can send BYE messages.

Ok, but in case C crashed, why is useful A receiving a NOTIFY trying telling 
that C is receiving a call? (even if the notification would be terminated when 
the dialog or INVITE transactions times out).


-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [sr-dev] Server trying outgoing TCP (TLS) connection, gets blocked

2009-06-22 Thread Iñaki Baz Castillo
El Lunes, 22 de Junio de 2009, Ivan Genov escribió:
 Hi,

Hi Ivan, you have sent this mail to this list (SIP-Ruter devel) and to 
OpenSIPs devel maillists.

They are two different projects. Please don't same the same question to both 
lists.


-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] PIDF complianceH

2009-06-09 Thread Iñaki Baz Castillo
2009/6/7 Iñaki Baz Castillo i...@aliax.net:
 El Domingo, 7 de Junio de 2009, escribió:
 Thanks alot! and how do you think about following RFCs?

 RFC 4661 Event notification filtering
 RFC 5263 Partial notification processing

I've read both RFC's right now. RFC 5263 sends useful but 4661 seems
to much exotic for me, I don't expect some vendor will implement it
(IMHO).

Regards.


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] PIDF complianceH

2009-06-07 Thread Iñaki Baz Castillo
El Domingo, 7 de Junio de 2009, escribió:
 Thanks alot! and how do you think about following RFCs?

 RFC 4661 Event notification filtering
 RFC 5263 Partial notification processing

I don't know them. Maybe they are not supported by OpenSIPS presence module.



-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Opensips study script

2009-05-28 Thread Iñaki Baz Castillo
2009/5/25 Brenno bpassa...@brastel.com.br:
 Hi,

 Sorry for my english, but i need something.

 I'm working in my university project, and i need to do a virtual PBX,
 and the only way i know that i can do it, is using opensips.

 I was studying some scripts, but i have a little dificult to understand
 somethings.

 What i need is, some script that can validate the REGISTER of user in
 some mysql table (like subscriber), log the informations of calls in the
 database (like in acc table, this i'm sure i can do) and it have to work
 in different networks (i guess with RTP Proxy, and this is my greater
 dificult to find some examples, because i dont know if the script change
 with the RTP working). And of course, can make calls between user in the
 some domain like 'us...@google.com' can make calls to
 'us...@google.com', but cannot do to 'u...@linux.com', can you
 understand? this is a dificult too, because i don't know if is possible
 to do.

 Does anyone have a example script for Opensips that has these features?

All your requeriments are really feasible with OpenSIPS, but of
course, it requieres to learn about managing OpenSIPS.

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] [presence] 'expires_offset' also for NOTIFY ('notify_expires_offset')

2009-05-26 Thread Iñaki Baz Castillo
Hi, I've detected an issue related to NOTIFY expires value when
there are retransmissions for the NOTIFY sent by OpenSIPS:

Imagine that a OpenSIPS sends a NOTIFY expires=30 to a client at 12:00:00.
Due to some reasons, the client doesn't reply to it (or perhaps there
are network errors) so the NOTIFY is retransmitted by OpenSIPS.
Finally the NOTIFY arrives to the client at 12:00:01.

If the client is too strict, it will send a refresh SUBSCRIBE at
12:00:31, so the subscription has expired in the server one second
ago.
This will cause a 481.

Unfortunatelly some clients (as Qutecom) work in this way, and the
worst: they don't react well when receiving a 481.

So I suggest a new option notify_expires_offset:

  modparam(presence, notify_expires_offset, 5)

In the above case (with retransmissions) it means that the client
would receive a NOTIFY with expires=25 at 12:00:01, and the client
will send the refresh SUSBCRIBE at 12:00:26 (before 12:00:30, the time
in which the subscription would expire in the server), so it would
mitigate the 481 issue.

Is it feasible to add this option? opinions?

Thanks a lot.

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [presence] 'expires_offset' also for NOTIFY ('notify_expires_offset')

2009-05-26 Thread Iñaki Baz Castillo
2009/5/26 Anca Vamanu a...@opensips.org:
 Hi,

 The expires_offset is somehow supposed to do that - but it lost the initial
 meaning in the mean time :) .
 I will fix that.


Hi Anca, the docs say that it only affects the 200 OK expires
value for an incoming PUBLISH:

1.3.7. expires_offset (int)
 The value that should be subtracted from the expires value when
sending a 200OK
 for a publish. It is used for forcing the client cu send an update
before the old publish
 expires.


Thanks a lot.


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] SF.net SVN: opensips:[5738] trunk/modules/presence

2009-05-26 Thread Iñaki Baz Castillo
2009/5/26 Anca Vamanu a...@opensips.org:
 Revision: 5738
          http://opensips.svn.sourceforge.net/opensips/?rev=5738view=rev
 Author:   anca_vamanu
 Date:     2009-05-26 10:32:28 + (Tue, 26 May 2009)

 Log Message:
 ---
 - made the usage of expires_offset module parameter consistent - intended to 
 force the clients to renew the subscription/publication by informing them of 
 a smaller expires value that the real one (reported by Inaki Baz Castillo 
 i...@aliax.net)

Increible! I've reported this wish just 5 minutes ago!
XD

Thanks a lot.


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [presence] 'expires_offset' also for NOTIFY ('notify_expires_offset')

2009-05-26 Thread Iñaki Baz Castillo
2009/5/26 Anca Vamanu a...@opensips.org:
 Iñaki Baz Castillo wrote:

 2009/5/26 Anca Vamanu a...@opensips.org:


 Yes, it was only for publish.
 I extended it for subscribes and also changed the docs.


 But, will it also affect on the NOTIFY's expires value sent by
 OpenSIPS upon receipt of a new PUBLISH?




 No. It will affect all the Notifies. Each time a Notify is generated (no
 matter the cause) the expires value inserted in the message will be
 decreased with expires_offset.

Great :)
Thanks a lot for the fastest implementation of a wish !


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] next_branch function, NAT and PATH (RFC 3327)

2009-05-14 Thread Iñaki Baz Castillo
2009/5/14 Mauro Davi' mauro.d...@acotel.com:
 Hi All,

Hi Mauro, please send such a question just to users maillist (but no devel).

Thanks.


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [NEW] ALIAS_DB enhancements

2009-05-05 Thread Iñaki Baz Castillo
2009/5/5 Bogdan-Andrei Iancu bog...@voice-system.ro:
 Hi,

 The 1.6 version (trunk) has new enhancements for the alias_db module :

Really great and useful enhancements.
Congratulations.

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] max_expires_subscribe and max_expires_publish not documented in 1.5

2009-04-03 Thread Iñaki Baz Castillo
The parameters max_expires_subscribe and max_expires_publish (replacing 
max_expires) don't appear in the doc of 1.5 version.

-- 
Iñaki Baz Castillo i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] SUBSCRIBE uses RURI as target instead of To URI

2009-03-30 Thread Iñaki Baz Castillo
2009/3/30 Anca Vamanu a...@opensips.org:
 The presence module inspects the R-URI  considering it to hold the
 presentity uri as is ought to be.
 Indeed, the proxy must not change the R-URI.

Ok, thanks for the clarification.
It's ok then, sorry for the invalid warning :)


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] SF.net SVN: opensips:[5548] trunk/modules/pua

2009-03-27 Thread Iñaki Baz Castillo
2009/3/27 Anca Vamanu a...@opensips.org:
 Revision: 5548
    trunk/modules/pua_usrloc/ul_publish.c

  262   if((error = pua_send_publish(publ)) 0)
  263   {
  264   if(publ.flag ==  INSERT_TYPE  error== ERR_PUBLISH_NO_BODY )
  265   {
  266   LM_DBG(Usrloc Publish for update failed - try 
Insert\n);
  267   publ.body= build_pidf(c);
  268   if(publ.body == NULL || publ.body-s == NULL)
  269   {
  270   LM_ERR(failed to generate publish body\n);
  271   goto error;
  272   }
  273   publ.flag= INSERT_TYPE;
  274
  275   if(pua_send_publish(publ) 0)
  276   {
  277  LM_ERR(failed to send publish\n);
  278   }
  279   }
  280   else
  281   LM_ERR(failed to send publish\n);
  282   }



Line 264 should be:
   if(publ.flag ==  UPDATE_TYPE  error== ERR_PUBLISH_NO_BODY )

right?


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] SF.net SVN: opensips:[5535] trunk/packaging

2009-03-25 Thread Iñaki Baz Castillo
2009/3/25 Dan Pascu d...@ag-projects.com:

 - In Sid/Lenny the deb version is already 1.4.4 so there is no problem.

 That is not true. Even if the library is already at the desired version,
 adding the version dependency is necessary because:

 1. It clearly indicates that you cannot work with a lesser version.

If you use Debian Lenny and do make deb in OpenSIPS sources, it will
require libgeoip-dev *DEB* package, and the libgeoip-dev package
available in Debian Lenny is 1.4.4, not less. It's impossible to have
installed an older version of libgeoip-dev in Debian Lenny (if you
have it, then you have not Debian Lenny).


 2. If someone still has an older version of the lib because he hasn't yet
 upgraded, opensips will install just fine but will not work.

Then this user is not using Debian Lenny and shouldn't do make
deb-lenny or make deb.


 With the
 library dependency though, installing opensips will force the upgrade for
 the library.

I agree on the fact that it's just better to add the version
requeriment also for Debian Lenny.


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] Error compiling Compiling mmgeoip.c (trunk version)

2009-03-24 Thread Iñaki Baz Castillo
make[3]: se ingresa al directorio
`/usr/src/opensips-trunk/sources/modules/mmgeoip'
Compiling mmgeoip.c
gcc -fPIC -DPIC -Wall -g -O2 -Wcast-align -DMOD_NAME='mmgeoip'
-DNAME='opensips' -DVERSION='1.6.0dev0-notls' -DARCH='x86_64'
-DOS='linux' -DCOMPILER='gcc 4.1.2' -D__CPU_x86_64 -D__OS_linux
-D__SMP_yes -DCFG_DIR='/etc/opensips/' -DPKG_MALLOC -DSHM_MEM
-DSHM_MMAP -DUSE_IPV6 -DUSE_MCAST -DUSE_TCP -DDISABLE_NAGLE
-DHAVE_RESOLV_RES -DSTATISTICS -DCHANGEABLE_DEBUG_LEVEL -DF_MALLOC
-DSVNREVISION='2:5533'  -DFAST_LOCK -DADAPTIVE_WAIT
-DADAPTIVE_WAIT_LOOPS=1024  -DHAVE_GETHOSTBYNAME2 -DHAVE_UNION_SEMUN
-DHAVE_SCHED_YIELD -DHAVE_MSG_NOSIGNAL -DHAVE_MSGHDR_MSG_CONTROL
-DHAVE_ALLOCA_H -DHAVE_TIMEGM -DHAVE_EPOLL -DHAVE_SIGIO_RT
-DHAVE_SELECT -I/usr/local/include -c mmgeoip.c -o mmgeoip.o
mmgeoip.c: In function ‘mod_init’:
mmgeoip.c:56: error: ‘GEOIP_MMAP_CACHE’ undeclared (first use in this function)
mmgeoip.c:56: error: (Each undeclared identifier is reported only once
mmgeoip.c:56: error: for each function it appears in.)
mmgeoip.c: In function ‘mmg_lookup_cmd’:
mmgeoip.c:202: warning: implicit declaration of function
‘GeoIP_region_name_by_code’
mmgeoip.c:202: warning: format ‘%s’ expects type ‘char *’, but
argument 4 has type ‘int’
mmgeoip.c:202: warning: format ‘%s’ expects type ‘char *’, but
argument 4 has type ‘int’
mmgeoip.c:206: warning: implicit declaration of function
‘GeoIP_time_zone_by_country_and_region’
mmgeoip.c:206: warning: format ‘%s’ expects type ‘char *’, but
argument 4 has type ‘int’
mmgeoip.c:206: warning: format ‘%s’ expects type ‘char *’, but
argument 4 has type ‘int’
make[3]: *** [mmgeoip.o] Error 1

Note: I do make deb-etch

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Error compiling Compiling mmgeoip.c (trunk version)

2009-03-24 Thread Iñaki Baz Castillo
2009/3/24 Iñaki Baz Castillo i...@aliax.net:
 2009/3/24 Sergio Gutierrez sag...@gmail.com:
 Hi Iñaki.

 Looks like you have not installed libgeoip packages;

 If you installed from sources, then you might need to point LOCALBASE to
 library location.

 Sergio, I do have these libraries installed:

 ii  libgeoip-dev                      1.3.17-1.1
        Development files for the GeoIP library
 ii  libgeoip1                         1.3.17-1.1
        A non-DNS IP-to-country resolver library

 Note that I do make deb-etch and the above lib (libgeoip-dev) is a
 required deb package.

Also, I've checked the following libraries:
  /usr/include/GeoIP.h
  /usr/include/GeoIPCity.h

and there is not defined GEOIP_MMAP_CACHE.

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] Error compiling Compiling mmgeoip.c (trunk version)

2009-03-24 Thread Iñaki Baz Castillo
2009/3/24 Iñaki Baz Castillo i...@aliax.net:
 2009/3/24 Iñaki Baz Castillo i...@aliax.net:
 Also, I've checked the following libraries:
  /usr/include/GeoIP.h
  /usr/include/GeoIPCity.h

 and there is not defined GEOIP_MMAP_CACHE.

 But there is GEOIP_MEMORY_CACHE in /usr/include/GeoIP.h

And changin GEOIP_MMAP_CACHE with GEOIP_MEMORY_CACHE in mmgeoip.c it compiles.

I use libgeoip-dev  1.3.17-1.1 (Debian Etch).


Ok, now I've discovered that version 1.4.4 (availabla in Debian Etch
backports) does contain:

typedef enum {
       GEOIP_STANDARD = 0,
       GEOIP_MEMORY_CACHE = 1,
       GEOIP_CHECK_CACHE = 2,
       GEOIP_INDEX_CACHE = 4,
       GEOIP_MMAP_CACHE = 8,
} GeoIPOptions;

This means that, when compiling for Debian Etch (make deb-etch), this
modules requires a lib just available in Etch backports. Perhaps this
version control should be added to the dependencies.

I've commited a patch for this.


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Deb dependencies not listed in opensips-console

2009-03-24 Thread Iñaki Baz Castillo
2009/3/24 Iñaki Baz Castillo i...@aliax.net:
 These packages python-mysqldb, libfrontier-rpc-perl, ibnet-ip-perl,
 libberkeleydb-perl shouldn't appear in the Debian control file, am I
 right?

I'm wrong, since opensips-console dependencies are already listed in
the own opensips-console.deb package:

Package: opensips-console
Architecture: any
Depends: ${shlibs:Depends}, opensips (= ${binary:Version}),
python-mysqldb, libfrontier-rpc-perl, libnet-ip-perl,
libberkeleydb-perl
Suggests: opensips-mysql-module, opensips-postgres-module,
opensips-unixodbc-module, opensips-xmlrpc-module,
opensips-berkeley-module



-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] SF.net SVN: opensips:[5535] trunk/packaging

2009-03-24 Thread Iñaki Baz Castillo
2009/3/24 Bogdan-Andrei Iancu bog...@voice-system.ro:
 Hi Inaki,

 Thanks for the fix - this version check is only for etch or it applies for
 all deb distros?

- In Sid/Lenny the deb version is already 1.4.4 so there is no problem.
- In Etch it requieres to add the Etch backports repositories to get
the 1.4.4 version.
- In Sarge it's not possible to install (not sure if sarge backports
contain the 1.4.4).

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [nat_traversal] nat_keepalive() doesn't work before t_newtran()

2009-03-21 Thread Iñaki Baz Castillo
El Sábado, 21 de Marzo de 2009, Dan Pascu escribió:
 The problem you reported should be fixed in the latest trunk revision. As
 explained back then, it only affected trunk after it added the signaling
 module, 1.4 was not affected.

 Please let me know if it works for you or do you see any more problems.

Thanks, I'll check it.

-- 
Iñaki Baz Castillo

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Crash in OpenSIPS-1-4 (rev 5452) actings as presence server

2009-03-17 Thread Iñaki Baz Castillo
2009/3/17 Anca Vamanu a...@opensips.org:
 Hi Inaki,

 What version exactly are you using? 1.4.0?

Yes, tag 1.4.0 from SVN.



-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Crash in OpenSIPS-1-4 (rev 5452) actings as presence server

2009-03-17 Thread Iñaki Baz Castillo
2009/3/17 Anca Vamanu a...@opensips.org:

 I remember having had a bug reported in 1.4.0 that caused segmentation
 fault. I would recomment 1.4.4 as the most stable version.

Yes, but the fact is that I'm trying to find a OpenSIPS stable version
for running as presence server in production for lots of users.
Unfortunatelly I'm dealing with a eternal bug:
  
https://sourceforge.net/tracker/index.php?func=detailaid=2335003group_id=232389atid=1086410

This is the reason to try olders versions of OpenSIPS, but it also occurs :(

Thanks a lot.



-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Error starting OpenSIPS trunk

2009-03-03 Thread Iñaki Baz Castillo
2009/3/3 Bogdan-Andrei Iancu bog...@voice-system.ro:
 Hi Inaki,

 The log you post does not contain any error ?!

Sorry, there was an error (I didn't paste it) due to a module which is
not compiled by default (regex) but I use it.

Sorry, my fault.

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Error compiling trunk version make deb-etch

2009-03-03 Thread Iñaki Baz Castillo
El Martes, 3 de Marzo de 2009, Bogdan-Andrei Iancu escribió:
 try to first remove the temp directories (1) debian in the trunk/ dir
 and (2) packaging/debian-/patched

Yes, I did it and it works.

Thanks.


-- 
Iñaki Baz Castillo

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] Error compiling trunk version make deb-etch

2009-03-02 Thread Iñaki Baz Castillo
:1193: referencia a
`tls_server_domains' sin definir
/usr/src/opensips-trunk/sources/cfg.y:1200: referencia a
`tls_server_domains' sin definir
/usr/src/opensips-trunk/sources/cfg.y:1207: referencia a
`tls_server_domains' sin definir
/usr/src/opensips-trunk/sources/cfg.y:1215: referencia a
`tls_server_domains' sin definir
cfg.tab.o:/usr/src/opensips-trunk/sources/cfg.y:1224: más referencias
a `tls_server_domains' sin definir a continuación
cfg.tab.o: In function `yyparse':
/usr/src/opensips-trunk/sources/cfg.y:1145: referencia a
`tls_new_server_domain' sin definir
/usr/src/opensips-trunk/sources/cfg.y:1156: referencia a
`tls_new_client_domain' sin definir
/usr/src/opensips-trunk/sources/cfg.y:1167: referencia a
`tls_new_client_domain_name' sin definir
collect2: ld returned 1 exit status
make[2]: *** [opensips] Error 1
make[2]: se sale del directorio `/usr/src/opensips-trunk/sources'
make[1]: *** [build-stamp] Error 2
make[1]: se sale del directorio `/usr/src/opensips-trunk/sources'
make: *** [deb-etch] Error 2
---



-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] When make deb-etch regex module is not compiled

2009-02-19 Thread Iñaki Baz Castillo
2009/2/19 Bogdan-Andrei Iancu bog...@voice-system.ro:
 Thanks, but just a question:
 What about other modules compiled by default via make deb* as:
 - mi_xmlrpc: depends on libxml, libxmlrpc-c3 and libxmlrpc-c3-dev


 there is the separate opensips-xmlrpc package

 - uri_radius: depends on radiusclient-ng


 opensips-radius package

 - xcap_client: depends on libxml-dev, libcurl-dev
 and so on?


 in opensips-presence package


:)

Thanks, I was wrong.


-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] Is it possible to commit new regex module before 1.5?

2009-02-18 Thread Iñaki Baz Castillo
2009/2/18 Dan Pascu d...@ag-projects.com:
 On Tuesday 17 February 2009, Bogdan-Andrei Iancu wrote:
 Hi Iñaki,

 Personally I think we can make an exception, given the circumstances.
 If the new code is tested and does not affect the overall stability of
 the code (which is the most important think here), we can be a bit
 flexible and go for it.

 I'm also interested in hearing other people opinion on this.

 I see no harm in adding it. It's a standalone module so it can't affect
 the rest of the code. Besides it was an issue of timing to push it into
 svn and a 1 day delay it's not that big of an issue.

Thanks to all, I will submit it today.

Best regards.

-- 
Iñaki Baz Castillo
i...@aliax.net

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] When make deb-etch regex module is not compiled

2009-02-18 Thread Iñaki Baz Castillo
El Miércoles, 18 de Febrero de 2009, Sergio Gutierrez escribió:
 Hi Iñaki.

 I think it is because regex is not compiled by default because of its
 dependency on pcre library.

Hi Sergio, please chech ALL_MODULES value in debian/rules. All the modules 
appear there, also those requiring external libraries.

The make deb-* and normal make are very different since make deb-* tries 
to compile most of the modules.


-- 
Iñaki Baz Castillo

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


  1   2   >