Skip to content

Commit ac933ed

Browse files
author
vogelor
committed
The server-side of the webdav - support
1 parent 4994815 commit ac933ed

File tree

8 files changed

+512
-266
lines changed

8 files changed

+512
-266
lines changed

docs/INSTALL_DEBIAN_5.0_courier_mydns.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -127,6 +127,10 @@ apt-get -y install apache2 apache2.2-common apache2-doc apache2-mpm-prefork apac
127127

128128
a2enmod suexec rewrite ssl actions include
129129

130+
# If you want to use webdav then run the following to enable the Apache webdav modules:
131+
132+
a2enmod dav_fs a2enmod dav auth_digest
133+
130134
# restart apache before continuing
131135

132136
/etc/init.d/apache2 restart

docs/INSTALL_DEBIAN_5.0_dovecot_bind.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,10 @@ apt-get -y install apache2 apache2.2-common apache2-doc apache2-mpm-prefork apac
9595

9696
a2enmod suexec rewrite ssl actions include
9797

98+
# If you want webdav then run the following to enable the Apache webdav modules:
99+
100+
a2enmod dav_fs a2enmod dav auth_digest
101+
98102
# restart apache before continuing
99103

100104
/etc/init.d/apache2 restart

docs/INSTALL_DEBIAN_5.0_multiserver.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,11 @@ apt-get install apache2 apache2.2-common apache2-doc apache2-mpm-prefork apache2
1010

1111
a2enmod suexec rewrite ssl actions include
1212

13+
# If you want webdav then run the following to enable the Apache webdav modules:
14+
15+
a2enmod dav_fs a2enmod dav auth_digest
16+
17+
1318
apt-get install pure-ftpd-common pure-ftpd-mysql quota quotatool
1419

1520
vi /etc/default/pure-ftpd-common

docs/INSTALL_DEBIAN_6.0_courier_mydns.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,10 @@ apt-get install apache2 apache2.2-common apache2-doc apache2-mpm-prefork apache2
122122

123123
a2enmod suexec rewrite ssl actions include
124124

125+
# If you want webdav then run the following to enable the Apache webdav modules:
126+
127+
a2enmod dav_fs a2enmod dav auth_digest
128+
125129
# restart apache before continuing
126130

127131
/etc/init.d/apache2 restart

interface/web/sites/form/webdav_user.tform.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,8 +96,7 @@
9696
),
9797
'password' => array (
9898
'datatype' => 'VARCHAR',
99-
'formtype' => 'PASSWORD',
100-
'encryption' => 'CRYPT',
99+
'formtype' => 'TEXT',
101100
'default' => '',
102101
'value' => '',
103102
'width' => '30',

server/conf/vhost.conf.master

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -162,6 +162,13 @@
162162
AssignUserId <tmpl_var name='system_user'> <tmpl_var name='system_group'>
163163
</IfModule>
164164

165+
<IfModule dav>
166+
# DO NOT REMOVE THE COMMENTS!
167+
# IF YOU REMOVE THEM, WEBDAV WILL NOT WORK ANYMORE!
168+
# WEBDAV BEGIN
169+
# WEBDAV END
170+
</IfModule>
171+
165172
<tmpl_var name='apache_directives'>
166173
</VirtualHost>
167174

@@ -339,6 +346,13 @@
339346
AssignUserId <tmpl_var name='system_user'> <tmpl_var name='system_group'>
340347
</IfModule>
341348

349+
<IfModule dav>
350+
# DO NOT REMOVE THE COMMENTS!
351+
# IF YOU REMOVE THEM, WEBDAV WILL NOT WORK ANYMORE!
352+
# WEBDAV BEGIN
353+
# WEBDAV END
354+
</IfModule>
355+
342356
<tmpl_var name='apache_directives'>
343357
</VirtualHost>
344358
</IfModule>

server/mods-available/web_module.inc.php

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,10 @@ class web_module {
4040
'ftp_user_delete',
4141
'shell_user_insert',
4242
'shell_user_update',
43-
'shell_user_delete');
43+
'shell_user_delete',
44+
'webdav_user_insert',
45+
'webdav_user_update',
46+
'webdav_user_delete');
4447

4548
//* This function is called during ispconfig installation to determine
4649
// if a symlink shall be created for this plugin.
@@ -82,6 +85,7 @@ class that contains the function functionname.
8285
$app->modules->registerTableHook('web_domain','web_module','process');
8386
$app->modules->registerTableHook('ftp_user','web_module','process');
8487
$app->modules->registerTableHook('shell_user','web_module','process');
88+
$app->modules->registerTableHook('webdav_user','web_module','process');
8589

8690
// Register service
8791
$app->services->registerService('httpd','web_module','restartHttpd');
@@ -112,6 +116,11 @@ function process($tablename,$action,$data) {
112116
if($action == 'u') $app->plugins->raiseEvent('shell_user_update',$data);
113117
if($action == 'd') $app->plugins->raiseEvent('shell_user_delete',$data);
114118
break;
119+
case 'webdav_user':
120+
if($action == 'i') $app->plugins->raiseEvent('webdav_user_insert',$data);
121+
if($action == 'u') $app->plugins->raiseEvent('webdav_user_update',$data);
122+
if($action == 'd') $app->plugins->raiseEvent('webdav_user_delete',$data);
123+
break;
115124
} // end switch
116125
} // end function
117126

0 commit comments

Comments
 (0)