From 3382e8708886e97dbe448d0fc433262510bdc03c Mon Sep 17 00:00:00 2001 From: Andrew McNab Date: Thu, 15 Feb 2007 16:07:09 +0000 Subject: [PATCH] Prepare for 1.4.x --- org.gridsite.core/CHANGES | 2 ++ org.gridsite.core/doc/mod_gridsite.8 | 5 ++++- org.gridsite.core/src/Makefile | 2 +- org.gridsite.core/src/gridsite-copy.c | 9 ++++++--- org.gridsite.core/src/grst_admin_file.c | 4 ++-- org.gridsite.core/src/grst_x509.c | 9 +++++---- 6 files changed, 20 insertions(+), 11 deletions(-) diff --git a/org.gridsite.core/CHANGES b/org.gridsite.core/CHANGES index 1ec4a0b..82eeb2f 100644 --- a/org.gridsite.core/CHANGES +++ b/org.gridsite.core/CHANGES @@ -1,3 +1,5 @@ +* Thu Feb 15 2007 Andrew McNab +- Final preparations for 1.4.x * Fri Sep 22 2006 Andrew McNab - Transfer htproxyinfo utility functions into grst_x509.c (GRSTx509ChainLoadCheck etc) diff --git a/org.gridsite.core/doc/mod_gridsite.8 b/org.gridsite.core/doc/mod_gridsite.8 index 4299e34..fc8c3bb 100644 --- a/org.gridsite.core/doc/mod_gridsite.8 +++ b/org.gridsite.core/doc/mod_gridsite.8 @@ -142,7 +142,10 @@ must be left in its default state of on. .IP "GridSiteEditable [ext1 [ext2 [ext3] ...]]]" A space-separated list of file extensions which can safely be edited by the GridSite Text/HTML editor. The extensions are given without the -initial dot. +initial dot. This directive must apply to the gridsite-admin.cgi +executable, rather than just to the files it manages. This is most +easily achieved by placing GridSiteEditable in the main section of +the virtual host, outside any Directory or Location containers. (Default: GridSiteEditable txt shtml html htm css js php jsp) .IP "GridSiteHelpURI uri" diff --git a/org.gridsite.core/src/Makefile b/org.gridsite.core/src/Makefile index 2d0e8bf..3c5de82 100644 --- a/org.gridsite.core/src/Makefile +++ b/org.gridsite.core/src/Makefile @@ -193,7 +193,7 @@ gridsite-copy.cgi: gridsite-copy.c libgridsite.so.$(VERSION) -o gridsite-copy.cgi gridsite-copy.c -L. \ -I/usr/kerberos/include \ `curl-config --cflags` `curl-config --libs` \ - -lgridsite + $(MYFCGILIBS) -lgridsite mod_gridsite.so: mod_gridsite.c mod_ssl-private.h libgridsite.so.$(VERSION) gcc -g $(MYCFLAGS) -shared -Wl,-soname=gridsite_module \ diff --git a/org.gridsite.core/src/gridsite-copy.c b/org.gridsite.core/src/gridsite-copy.c index b9d2e1a..7eb4578 100644 --- a/org.gridsite.core/src/gridsite-copy.c +++ b/org.gridsite.core/src/gridsite-copy.c @@ -38,7 +38,9 @@ // script COPY /cgi-bin/gridsite-copy.cgi // /////////////////////////////////////////////////////////////////// +#ifdef GRST_USE_FASTCGI #include +#endif #include #include #include @@ -157,9 +159,10 @@ int gridsite_copy() int main( void ) { - - while(FCGI_Accept() >= 0){ +#ifdef GRST_USE_FASTCGI + while(FCGI_Accept() >= 0) +#endif + { gridsite_copy(); } } - diff --git a/org.gridsite.core/src/grst_admin_file.c b/org.gridsite.core/src/grst_admin_file.c index cf85f5d..d6619a6 100644 --- a/org.gridsite.core/src/grst_admin_file.c +++ b/org.gridsite.core/src/grst_admin_file.c @@ -101,8 +101,8 @@ char *storeuploadfile(char *boundary, int *bufferused) void uploadfile(char *dn, GRSTgaclPerm perm, char *help_uri, char *dir_path, char *dir_uri, char *admin_file) { - char *boundary, *p, oneline[200], *filename = NULL, - tmpfilename[256], *filebuffer = NULL, *filepath, + char *boundary, *p, oneline[1086], *filename = NULL, + tmpfilename[1025], *filebuffer = NULL, *filepath, *vfile, *dir_path_vfile; int mimestate, bufferused = 0, itworked = 0; FILE *fp; diff --git a/org.gridsite.core/src/grst_x509.c b/org.gridsite.core/src/grst_x509.c index 3251813..99741d3 100644 --- a/org.gridsite.core/src/grst_x509.c +++ b/org.gridsite.core/src/grst_x509.c @@ -65,9 +65,10 @@ #include "gridsite.h" -#define GRST_KEYSIZE 512 -#define GRST_PROXYCACHE "/../proxycache/" -#define GRST_MAX_CHAIN_LEN 9 +#define GRST_KEYSIZE 512 +#define GRST_PROXYCACHE "/../proxycache/" +#define GRST_MAX_CHAIN_LEN 9 +#define GRST_BACKDATE_SECONDS 300 /// Compare X509 Distinguished Name strings int GRSTx509NameCmp(char *a, char *b) @@ -1439,7 +1440,7 @@ int GRSTx509MakeProxyCert(char **proxychain, FILE *debugfp, } /* set duration for the certificate */ - if (!(X509_gmtime_adj (X509_get_notBefore(certs[0]), 0))) + if (!(X509_gmtime_adj (X509_get_notBefore(certs[0]), -GRST_BACKDATE_SECONDS))) { mpcerror(debugfp, "GRSTx509MakeProxyCert(): error setting beginning time of the certificate\n"); -- 1.8.2.3