Skip to Content.
Sympa Menu

sm-commit - [SM-Commit] GIT changes to master grimoire by Vlad Glagolev (3fd1ae6c80773d08255560b5cc43359c96fe608a)

sm-commit AT lists.ibiblio.org

Subject: Source Mage code commit list

List archive

Chronological Thread  
  • From: Vlad Glagolev <scm AT sourcemage.org>
  • To: sm-commit AT lists.ibiblio.org
  • Subject: [SM-Commit] GIT changes to master grimoire by Vlad Glagolev (3fd1ae6c80773d08255560b5cc43359c96fe608a)
  • Date: Wed, 3 Sep 2008 01:25:06 -0500

GIT changes to master grimoire by Vlad Glagolev <stealth AT sourcemage.org>:

http/lighttpd/DETAILS | 2 -
http/lighttpd/HISTORY | 5 +++
http/lighttpd/PRE_BUILD | 5 +++
http/lighttpd/mod_fastcgi.patch | 56
++++++++++++++++++++++++++++++++++++++++
http/lighttpd/mod_scgi.patch | 53 +++++++++++++++++++++++++++++++++++++
5 files changed, 120 insertions(+), 1 deletion(-)

New commits:
commit 3fd1ae6c80773d08255560b5cc43359c96fe608a
Author: Vlad Glagolev <stealth AT sourcemage.org>
Commit: Vlad Glagolev <stealth AT sourcemage.org>

lighttpd: fixed [s,fast]cgi modules for working with multiple scripts in
the same path

diff --git a/http/lighttpd/DETAILS b/http/lighttpd/DETAILS
index d237b39..59a69ac 100755
--- a/http/lighttpd/DETAILS
+++ b/http/lighttpd/DETAILS
@@ -8,7 +8,7 @@ SOURCE_DIRECTORY=$BUILD_DIRECTORY/$SPELL-$VERSION
LICENSE[0]=BSD
ENTERED=20050722
SECURITY_PATCH=4
- PATCHLEVEL=1
+ PATCHLEVEL=2
KEYWORDS="http"
SHORT="light httpd"
cat << EOF
diff --git a/http/lighttpd/HISTORY b/http/lighttpd/HISTORY
index 662a2b5..32a6b90 100644
--- a/http/lighttpd/HISTORY
+++ b/http/lighttpd/HISTORY
@@ -1,3 +1,8 @@
+2008-09-02 Vlad Glagolev <stealth AT sourcemage.org>
+ * DETAILS: PATCHLEVEL+=1
+ * PRE_BUILD: apply the patch for mod_{s,fast}cgi
+ * mod_{s,fast}cgi.patch: added, official patches for multipath
detection
+
2008-06-21 Vlad Glagolev <stealth AT sourcemage.org>
* DETAILS: PATCHLEVEL++, fixed SOURCE_DIRECTORY
* BUILD: use correct path for the modules
diff --git a/http/lighttpd/PRE_BUILD b/http/lighttpd/PRE_BUILD
new file mode 100755
index 0000000..ddefc2e
--- /dev/null
+++ b/http/lighttpd/PRE_BUILD
@@ -0,0 +1,5 @@
+default_pre_build &&
+cd "$SOURCE_DIRECTORY" &&
+
+patch -p0 < "$SPELL_DIRECTORY/mod_scgi.patch" &&
+patch -p0 < "$SPELL_DIRECTORY/mod_fastcgi.patch"
diff --git a/http/lighttpd/mod_fastcgi.patch b/http/lighttpd/mod_fastcgi.patch
new file mode 100644
index 0000000..9fa2bd2
--- /dev/null
+++ b/http/lighttpd/mod_fastcgi.patch
@@ -0,0 +1,56 @@
+--- src/mod_fastcgi.c.orig
++++ src/mod_fastcgi.c
+@@ -235,4 +235,14 @@
+
+ unsigned short break_scriptfilename_for_php;
++
++ /*
++ * workaround for program when prefix="/"
++ *
++ * rule to build PATH_INFO is hardcoded for when check_local is
disabled
++ * enable this option to use the workaround
++ *
++ */
++
++ unsigned short fix_root_path_name;
+
+ /*
+@@ -1196,4 +1206,5 @@
+ { "strip-request-uri", NULL,
T_CONFIG_STRING, T_CONFIG_SCOPE_CONNECTION }, /* 16 */
+ { "kill-signal", NULL,
T_CONFIG_SHORT, T_CONFIG_SCOPE_CONNECTION }, /* 17 */
++ { "fix-root-scriptname",
NULL, T_CONFIG_BOOLEAN, T_CONFIG_SCOPE_CONNECTION }, /* 18 */
+
+ { NULL, NULL,
T_CONFIG_UNSET, T_CONFIG_SCOPE_UNSET }
+@@ -1223,4 +1234,5 @@
+ host->allow_xsendfile = 0; /* handle
X-LIGHTTPD-send-file */
+ host->kill_signal = SIGTERM;
++ host->fix_root_path_name = 0;
+
+ fcv[0].destination = host->host;
+@@ -1244,4 +1256,5 @@
+ fcv[16].destination =
host->strip_request_uri;
+ fcv[17].destination =
&(host->kill_signal);
++ fcv[18].destination =
&(host->fix_root_path_name);
+
+ if (0 !=
config_insert_values_internal(srv, da_host->value, fcv)) {
+@@ -3586,4 +3599,11 @@
+ * PATH_INFO = /bar
+ *
++ * if prefix = /, and fix-root-path-name is enable
++ *
++ * /fcgi-bin/foo/bar
++ *
++ * SCRIPT_NAME = /fcgi-bin/foo
++ * PATH_INFO = /bar
++ *
+ */
+
+@@ -3597,4 +3617,8 @@
+
+ con->uri.path->used -=
con->request.pathinfo->used - 1;
++ con->uri.path->ptr[con->uri.path->used - 1] =
'\0';
++ } else if (host->fix_root_path_name &&
extension->key->ptr[0] == '/' && extension->key->ptr[1] == '\0') {
++ buffer_copy_string(con->request.pathinfo,
con->uri.path->ptr);
++ con->uri.path->used = 1;
+ con->uri.path->ptr[con->uri.path->used - 1] =
'\0';
+ }
diff --git a/http/lighttpd/mod_scgi.patch b/http/lighttpd/mod_scgi.patch
new file mode 100644
index 0000000..a6bb929
--- /dev/null
+++ b/http/lighttpd/mod_scgi.patch
@@ -0,0 +1,53 @@
+--- src/mod_scgi.c.orig 2008-02-29 01:19:03.000000000 +0300
++++ src/mod_scgi.c 2008-09-03 09:02:52.221731772 +0400
+@@ -202,6 +202,15 @@
+ *
+ */
+
++ /*
++ * workaround for program when prefix="/"
++ *
++ * rule to build PATH_INFO is hardcoded for when check_local is
disabled
++ * enable this option to use the workaround
++ *
++ */
++
++ unsigned short fix_root_path_name;
+ ssize_t load; /* replace by host->load */
+
+ size_t max_id; /* corresponds most of the time to
+@@ -968,6 +977,7 @@
+
+ { "bin-environment", NULL,
T_CONFIG_ARRAY, T_CONFIG_SCOPE_CONNECTION }, /* 11 */
+ { "bin-copy-environment",
NULL, T_CONFIG_ARRAY, T_CONFIG_SCOPE_CONNECTION }, /* 12 */
++ { "fix-root-scriptname",
NULL, T_CONFIG_BOOLEAN, T_CONFIG_SCOPE_CONNECTION }, /* 13 */
+
+
+ { NULL, NULL,
T_CONFIG_UNSET, T_CONFIG_SCOPE_UNSET }
+@@ -990,6 +1000,7 @@
+ df->max_load_per_proc = 1;
+ df->idle_timeout = 60;
+ df->disable_time = 60;
++ df->fix_root_path_name = 0;
+
+ fcv[0].destination = df->host;
+ fcv[1].destination = df->docroot;
+@@ -1006,6 +1017,7 @@
+
+ fcv[11].destination = df->bin_env;
+ fcv[12].destination =
df->bin_env_copy;
++ fcv[13].destination =
&(df->fix_root_path_name);
+
+
+ if (0 !=
config_insert_values_internal(srv, da_host->value, fcv)) {
+@@ -2790,6 +2802,10 @@
+
+ con->uri.path->used -=
con->request.pathinfo->used - 1;
+
con->uri.path->ptr[con->uri.path->used - 1] = '\0';
++ } else if (host->fix_root_path_name &&
extension->key->ptr[0] == '/' && extension->key->ptr[1] == '\0') {
++
buffer_copy_string(con->request.pathinfo, con->uri.path->ptr);
++ con->uri.path->used = 1;
++
con->uri.path->ptr[con->uri.path->used - 1] = '\0';
+ }
+ }
+ return HANDLER_GO_ON;



  • [SM-Commit] GIT changes to master grimoire by Vlad Glagolev (3fd1ae6c80773d08255560b5cc43359c96fe608a), Vlad Glagolev, 09/03/2008

Archive powered by MHonArc 2.6.24.

Top of Page