patch for RFC 2518 (WEBDAV) methods

From: Duane Wessels <[email protected]>
Date: Thu, 17 Jun 1999 22:20:12 -0600

If anyone is really desperate, here's a quick patch that adds the
RFC 2518 (WEBDAV) request methods. Its not very well tested.

Duane W.

Index: enums.h
===================================================================
RCS file: /surf1/CVS/squid/src/enums.h,v
retrieving revision 1.156
diff -u -r1.156 enums.h
--- enums.h 1999/06/17 22:20:38 1.156
+++ enums.h 1999/06/18 04:16:26
@@ -364,6 +364,15 @@
     METHOD_CONNECT, /* 101 */
     METHOD_TRACE, /* 110 */
     METHOD_PURGE, /* 111 */
+#ifndef RFC_2518
+ METHOD_PROPFIND,
+ METHOD_PROPPATCH,
+ METHOD_MKCOL,
+ METHOD_COPY,
+ METHOD_MOVE,
+ METHOD_LOCK,
+ METHOD_UNLOCK,
+#endif
     METHOD_ENUM_END
 };
 typedef unsigned int method_t;
Index: pump.c
===================================================================
RCS file: /surf1/CVS/squid/src/pump.c,v
retrieving revision 1.74
diff -u -r1.74 pump.c
--- pump.c 1999/05/04 21:58:32 1.74
+++ pump.c 1999/06/18 04:16:27
@@ -417,6 +417,15 @@
     switch (method) {
     case METHOD_POST:
     case METHOD_PUT:
+#ifndef RFC_2518
+ case METHOD_PROPFIND:
+ case METHOD_PROPPATCH:
+ case METHOD_MKCOL:
+ case METHOD_COPY:
+ case METHOD_MOVE:
+ case METHOD_LOCK:
+ case METHOD_UNLOCK:
+#endif
         return 1;
         break;
     default:
Index: url.c
===================================================================
RCS file: /surf1/CVS/squid/src/url.c,v
retrieving revision 1.116
diff -u -r1.116 url.c
--- url.c 1999/05/04 21:58:46 1.116
+++ url.c 1999/06/18 04:16:27
@@ -44,7 +44,17 @@
     "HEAD",
     "CONNECT",
     "TRACE",
- "PURGE"
+ "PURGE",
+#ifndef RFC_2518
+ "PROPFIND",
+ "PROPPATCH",
+ "MKCOL",
+ "COPY",
+ "MOVE",
+ "LOCK",
+ "UNLOCK",
+#endif
+ "ERROR"
 };
 
 const char *ProtocolStr[] =
@@ -131,6 +141,22 @@
         return METHOD_TRACE;
     } else if (strcasecmp(s, "PURGE") == 0) {
         return METHOD_PURGE;
+#ifndef RFC_2518
+ } else if (strcasecmp(s, "PROPFIND") == 0) {
+ return METHOD_PROPFIND;
+ } else if (strcasecmp(s, "PROPPATCH") == 0) {
+ return METHOD_PROPPATCH;
+ } else if (strcasecmp(s, "MKCOL") == 0) {
+ return METHOD_MKCOL;
+ } else if (strcasecmp(s, "COPY") == 0) {
+ return METHOD_COPY;
+ } else if (strcasecmp(s, "MOVE") == 0) {
+ return METHOD_MOVE;
+ } else if (strcasecmp(s, "LOCK") == 0) {
+ return METHOD_LOCK;
+ } else if (strcasecmp(s, "UNLOCK") == 0) {
+ return METHOD_UNLOCK;
+#endif
     }
     return METHOD_NONE;
 }
Received on Thu Jun 17 1999 - 22:06:44 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:46:55 MST