diff options
author | mmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-12-10 16:24:56 +0000 |
---|---|---|
committer | mmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-12-10 16:24:56 +0000 |
commit | 742a9b5bee8ca579a4f670116f789335114f7492 (patch) | |
tree | cfd636da3e91585a671b97a05004efb3aa22eaee | |
parent | 84b9affa00c76923dac42cb1c6bd60e78a99eabe (diff) |
Revert fix for issue 13570. It has caused more problems than
it helped to fix.
(closes issue #13783)
Reported by: navkumar
(closes issue #14025)
Reported by: ffs
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@162663 f38db490-d61c-443f-a65b-d21fe96a405b
-rw-r--r-- | channels/chan_sip.c | 21 |
1 files changed, 0 insertions, 21 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c index cc4339b9b..ca912d5e9 100644 --- a/channels/chan_sip.c +++ b/channels/chan_sip.c @@ -167,8 +167,6 @@ ASTERISK_FILE_VERSION(__FILE__, "$Revision$") #define IPTOS_MINCOST 0x02 #endif -#define SIP_RESERVED ";/?:@&=+$,# " - /* #define VOCAL_DATA_HACK */ #define DEFAULT_DEFAULT_EXPIRY 120 @@ -4733,11 +4731,9 @@ static int sip_register(char *value, int lineno) struct sip_registry *reg; int portnum = 0; char username[256] = ""; - char *user; char *hostname=NULL, *secret=NULL, *authuser=NULL; char *porta=NULL; char *contact=NULL; - char *reserved = NULL; if (!value) return -1; @@ -4758,16 +4754,6 @@ static int sip_register(char *value, int lineno) if (authuser) *authuser++ = '\0'; } - user = username; - if ((reserved = strpbrk(user, SIP_RESERVED))) { - goto invalid_char; - } - if (!ast_strlen_zero(secret) && (reserved = strpbrk(secret, SIP_RESERVED))) { - goto invalid_char; - } - if (!ast_strlen_zero(authuser) && (reserved = strpbrk(authuser, SIP_RESERVED))) { - goto invalid_char; - } /* split host[:port][/contact] */ contact = strchr(hostname, '/'); if (contact) @@ -4783,9 +4769,6 @@ static int sip_register(char *value, int lineno) return -1; } } - if ((reserved = strpbrk(hostname, SIP_RESERVED))) { - goto invalid_char; - } if (!(reg = ast_calloc(1, sizeof(*reg)))) { ast_log(LOG_ERROR, "Out of memory. Can't allocate SIP registry entry\n"); return -1; @@ -4817,10 +4800,6 @@ static int sip_register(char *value, int lineno) ASTOBJ_CONTAINER_LINK(®l, reg); /* Add the new registry entry to the list */ ASTOBJ_UNREF(reg,sip_registry_destroy); return 0; - -invalid_char: - ast_log(LOG_ERROR, "A reserved character ('%c') was used in a \"register\" line. This registration will not occur\n", *reserved); - return -1; } /*! \brief Parse multiline SIP headers into one header |