From 5bc5221a19053616b141e6e76a1f4093777014a3 Mon Sep 17 00:00:00 2001 From: Thomas Ries Date: Thu, 26 Aug 2004 17:32:30 +0000 Subject: [PATCH] - more DEBUG output --- ChangeLog | 1 + RELNOTES | 2 ++ config.h.in | 3 --- src/accessctl.c | 1 + src/proxy.c | 6 ++++++ src/siproxd.c | 10 ++++++++-- 6 files changed, 18 insertions(+), 5 deletions(-) diff --git a/ChangeLog b/ChangeLog index e6e85c3..599baec 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,6 @@ 0.5.8 ===== + 26-Aug-2004: - more DEBUG output 22-Aug-2004: - fix: secure_enviroment - set proper EGID (by Daniel Mueller) 19-Aug-2004: - fix: don't crash on missing Contact header during registration 18-Aug-2004: - reworked configure.in for FLI4L building diff --git a/RELNOTES b/RELNOTES index e0a0420..1f2b83e 100644 --- a/RELNOTES +++ b/RELNOTES @@ -56,11 +56,13 @@ Reported interoperability with softphones: - Kphone (local and remote UA) (http://www.wirlab.net/kphone/) - MSN messenger 4.6 (remote and local UA) - X-Lite (Win XP Professional) + - SJPhone softphone Reported interoperability with SIP service providers: - Sipphone (http://www.sipphone.com) - FWD (http://www.fwd.pulver.com) - Sipgate (http://www.sipgate.de) + - Stanaphone (SIP Gateway to PSTN) If you have siproxd successfully running with another SIP phone and/or service provider, please drop me a short note so I can update diff --git a/config.h.in b/config.h.in index 6326bc4..b544963 100644 --- a/config.h.in +++ b/config.h.in @@ -36,9 +36,6 @@ /* Define to 1 if you have the `gethostbyname' function. */ #undef HAVE_GETHOSTBYNAME -/* Define to 1 if you have the `gethostbyname_r' function. */ -#undef HAVE_GETHOSTBYNAME_R - /* Define to 1 if you have the header file. */ #undef HAVE_GETOPT_H diff --git a/src/accessctl.c b/src/accessctl.c index 31abff4..3ccb1ef 100644 --- a/src/accessctl.c +++ b/src/accessctl.c @@ -99,6 +99,7 @@ int accesslist_check (struct sockaddr_in from) { access |= ACCESSCTL_REG; } + DEBUGC(DBCLASS_ACCESS,"access check =%i", access); return access; } diff --git a/src/proxy.c b/src/proxy.c index 24e0079..ce12afe 100644 --- a/src/proxy.c +++ b/src/proxy.c @@ -582,6 +582,8 @@ We should use the first Route header to send the packet to } else { port = SIP_PORT; } + DEBUGC(DBCLASS_PROXY, "proxy_request: have outbound proxy %s:%i", + configuration.outbound_proxy_host, port); } else if ((type == REQTYP_OUTGOING) && (request->routes && !osip_list_eol(request->routes, 0))) { /* get the destination from the Route Header */ @@ -605,6 +607,8 @@ We should use the first Route header to send the packet to } else { port=SIP_PORT; } + DEBUGC(DBCLASS_PROXY, "proxy_request: have Route header to %s:%i", + route->url->host, port); } else { /* get the destination from the SIP URI */ sts = get_ip_by_host(url->host, &sendto_addr); @@ -619,6 +623,8 @@ We should use the first Route header to send the packet to } else { port=SIP_PORT; } + DEBUGC(DBCLASS_PROXY, "proxy_request: have SIP URI to %s:%i", + url->host, port); } /* diff --git a/src/siproxd.c b/src/siproxd.c index 32e1f1a..b0dae63 100644 --- a/src/siproxd.c +++ b/src/siproxd.c @@ -284,11 +284,17 @@ int main (int argc, char *argv[]) /* evaluate the access lists (IP based filter)*/ access=accesslist_check(ticket.from); - if (access == 0) continue; /* there are no resources to free */ + if (access == 0) { + DEBUGC(DBCLASS_ACCESS,"access for this packet was denied"); + continue; /* there are no resources to free */ + } /* integrity checks */ sts=security_check_raw(buff, i); - if (sts != STS_SUCCESS) continue; /* there are no resources to free */ + if (sts != STS_SUCCESS) { + DEBUGC(DBCLASS_SIP,"security check (raw) failed"); + continue; /* there are no resources to free */ + } /* init sip_msg */ sts=osip_message_init(&ticket.sipmsg);