diff --git a/sblim-sfcb-1.3.16-http-header-cmd-check.patch b/sblim-sfcb-1.3.16-http-header-cmd-check.patch new file mode 100644 index 0000000..1254d7b --- /dev/null +++ b/sblim-sfcb-1.3.16-http-header-cmd-check.patch @@ -0,0 +1,14 @@ +diff -up sblim-sfcb-1.3.16/httpAdapter.c.bak sblim-sfcb-1.3.16/httpAdapter.c +--- sblim-sfcb-1.3.16/httpAdapter.c.bak 2012-10-06 03:19:15.000000000 +0200 ++++ sblim-sfcb-1.3.16/httpAdapter.c 2013-05-29 19:57:16.906813502 +0200 +@@ -728,8 +728,8 @@ static int getHdrs(CommHndl conn_fd, Buf + total+=r; + + /* on first run through, ensure that this is a POST req. */ +- if (r && first) { +- if (strncasecmp(buf,cmd,strlen(cmd)) != 0) { ++ if (first && total >= strlen(cmd)) { ++ if (strncasecmp(b->data,cmd,strlen(cmd)) != 0) { + /* not what we expected - still continue to read to + not confuse the client */ + state = 1; diff --git a/sblim-sfcb.spec b/sblim-sfcb.spec index ff59a03..7ab685b 100644 --- a/sblim-sfcb.spec +++ b/sblim-sfcb.spec @@ -8,7 +8,7 @@ Name: sblim-sfcb Summary: Small Footprint CIM Broker URL: http://sblim.wiki.sourceforge.net/ Version: 1.3.16 -Release: 6%{?dist} +Release: 7%{?dist} Group: Applications/System License: EPL Source0: http://downloads.sourceforge.net/sblim/%{name}-%{version}.tar.bz2 @@ -38,6 +38,8 @@ Patch8: sblim-sfcb-1.3.16-escape.patch Patch9: sblim-sfcb-1.3.16-embedded-instance.patch # Patch10: increase default value of maxMsgLen in sfcb.cfg Patch10: sblim-sfcb-1.3.16-maxMsgLen.patch +# Patch11: fix CIM clients are sometimes getting HTTP/1.1 501 Not Implemented +Patch11: sblim-sfcb-1.3.16-http-header-cmd-check.patch Provides: cim-server Requires: cim-schema BuildRequires: libcurl-devel @@ -72,6 +74,7 @@ Programming Interface (CMPI). %patch8 -p1 -b .escape %patch9 -p1 -b .embedded-instance %patch10 -p1 -b .maxMsgLen +%patch11 -p1 -b .http-header-cmd-check %build %configure --enable-debug --enable-uds --enable-ssl --enable-pam --enable-ipv6 CFLAGS="$CFLAGS -D_GNU_SOURCE -fPIE -DPIE" LDFLAGS="$LDFLAGS -Wl,-z,now -pie" @@ -129,6 +132,11 @@ fi; %files -f _pkg_list %changelog +* Tue Jul 23 2013 Vitezslav Crhonek - 1.3.16-7 +- Fix CIM clients are sometimes getting HTTP/1.1 501 Not Implemented + (patch by Tomas Bzatek) + Resolves: #968397 + * Wed Jul 17 2013 Petr Pisar - 1.3.16-6 - Perl 5.18 rebuild