Re: [Nagios-devel] [Nagios-users] action_url issues
Posted: Thu Jun 19, 2008 11:54 am
This is a multi-part message in MIME format.
--------------020002070108000909080705
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 8bit
Wrong list
======
Hi,
Mathieu Gagné wrote:
>
> A bugfix has been applied in Nagios 3.0.2. In fact, the behavior in
> Nagios 3.0.1 was the wrong one I guess.
>
This bugfix was introduced here:
http://thread.gmane.org/gmane.network.n ... focus=5225
Some characters don't get encoded and the list is defined in
./common/macros.c on lin 2486
Those characters should not get encoded too: ":", "/", "?", "=" and "&".
Attached is a patch that fixes this urlencode issue.
--
Mathieu
--------------020002070108000909080705
Content-Type: text/plain;
name="fix-macro-urlencode.patch"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
filename="fix-macro-urlencode.patch"
--- nagios-3.0.2-original/common/macros.c 2008-05-19 14:01:58.000000000 -0400
+++ nagios-3.0.2/common/macros.c 2008-06-19 15:41:56.000000000 -0400
@@ -2484,7 +2484,7 @@
for(x=0,y=0;input[x]!=(char)'\x0';x++){
/* alpha-numeric characters and a few other characters don't get encoded */
- if(((char)input[x]>='0' && (char)input[x]='A' && (char)input[x]=(char)'a' && (char)input[x]='0' && (char)input[x]='A' && (char)input[x]=(char)'a' && (char)input[x]<=(char)'z') || (char)input[x]==(char)'.' || (char)input[x]==(char)'-' || (char)input[x]==(char)'_' || (char)input[x]==(char)':' || (char)input[x]==(char)'/' || (char)input[x]==(char)'?' || (char)input[x]==(char)'=' || (char)input[x]==(char)'&'){
encoded_url_string[y]=input[x];
y++;
}
--------------020002070108000909080705--
This post was automatically imported from historical nagios-devel mailing list archives
Original poster: [email protected]
--------------020002070108000909080705
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 8bit
Wrong list
======
Hi,
Mathieu Gagné wrote:
>
> A bugfix has been applied in Nagios 3.0.2. In fact, the behavior in
> Nagios 3.0.1 was the wrong one I guess.
>
This bugfix was introduced here:
http://thread.gmane.org/gmane.network.n ... focus=5225
Some characters don't get encoded and the list is defined in
./common/macros.c on lin 2486
Those characters should not get encoded too: ":", "/", "?", "=" and "&".
Attached is a patch that fixes this urlencode issue.
--
Mathieu
--------------020002070108000909080705
Content-Type: text/plain;
name="fix-macro-urlencode.patch"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
filename="fix-macro-urlencode.patch"
--- nagios-3.0.2-original/common/macros.c 2008-05-19 14:01:58.000000000 -0400
+++ nagios-3.0.2/common/macros.c 2008-06-19 15:41:56.000000000 -0400
@@ -2484,7 +2484,7 @@
for(x=0,y=0;input[x]!=(char)'\x0';x++){
/* alpha-numeric characters and a few other characters don't get encoded */
- if(((char)input[x]>='0' && (char)input[x]='A' && (char)input[x]=(char)'a' && (char)input[x]='0' && (char)input[x]='A' && (char)input[x]=(char)'a' && (char)input[x]<=(char)'z') || (char)input[x]==(char)'.' || (char)input[x]==(char)'-' || (char)input[x]==(char)'_' || (char)input[x]==(char)':' || (char)input[x]==(char)'/' || (char)input[x]==(char)'?' || (char)input[x]==(char)'=' || (char)input[x]==(char)'&'){
encoded_url_string[y]=input[x];
y++;
}
--------------020002070108000909080705--
This post was automatically imported from historical nagios-devel mailing list archives
Original poster: [email protected]