mirror of
https://git.FreeBSD.org/ports.git
synced 2024-11-23 00:43:28 +00:00
- Update to 2010-11-07 release.
- Add a patch to improve diff generation in Unicode case [1] which is used in the FreeBSD China wiki installation for a while. Submitted by: MQ [1]
This commit is contained in:
parent
a29b495a14
commit
e00d804d93
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=264266
@ -7,7 +7,6 @@
|
||||
|
||||
PORTNAME= dokuwiki
|
||||
PORTVERSION= ${DIST_VER:S/${PORTNAME}//:S/-//g}
|
||||
PORTREVISION= 2
|
||||
CATEGORIES= www
|
||||
MASTER_SITES= http://www.splitbrain.org/_media/projects/dokuwiki/ \
|
||||
LOCAL/chinsan/${PORTNAME}
|
||||
@ -17,7 +16,7 @@ EXTRACT_SUFX= .tgz
|
||||
MAINTAINER= delphij@FreeBSD.org
|
||||
COMMENT= A simple and easy to use wiki, no database required
|
||||
|
||||
DIST_VER= ${PORTNAME}-2009-12-25
|
||||
DIST_VER= ${PORTNAME}-2010-11-07
|
||||
USE_PHP= gd mbstring pcre session xml zlib
|
||||
NO_BUILD= YES
|
||||
WANT_PHP_WEB= YES
|
||||
@ -40,10 +39,8 @@ x-generate-plist:
|
||||
&& ${ECHO_CMD} "@dirrmtry %%DOKUWIKI_DIR%%" >> ${TEMP_PLIST}
|
||||
|
||||
post-patch:
|
||||
@${REINPLACE_CMD} -e 's|9|10|' ${WRKSRC}/conf/msg
|
||||
@${FIND} ${WRKSRC} -name '*.orig' -delete
|
||||
@${REINPLACE_CMD} -e 's|/usr/bin|${LOCALBASE}/bin|' ${WRKSRC}/bin/*.php
|
||||
@${FIND} ${WRKSRC}/bin -name '*.orig' -delete
|
||||
@${FIND} ${WRKSRC} -name '*.orig' -delete
|
||||
|
||||
do-install:
|
||||
# Data files
|
||||
|
@ -1,3 +1,2 @@
|
||||
MD5 (dokuwiki-2009-12-25.tgz) = 1428c896de83bd2a754efd18919d0594
|
||||
SHA256 (dokuwiki-2009-12-25.tgz) = 317f978e1055469f0405b32f69ecde6afab67fc8a46cf86e6e0b758191d9612a
|
||||
SIZE (dokuwiki-2009-12-25.tgz) = 2545036
|
||||
SHA256 (dokuwiki-2010-11-07.tgz) = 2ed3fe0f10d8ece6bee42a51d9fbce4b597f6f4391597d63957d14ef88d4404d
|
||||
SIZE (dokuwiki-2010-11-07.tgz) = 2756995
|
||||
|
@ -1,116 +0,0 @@
|
||||
diff -ur VERSION VERSION
|
||||
--- VERSION 2009-12-25 02:14:45.000000000 -0800
|
||||
+++ VERSION 2010-01-17 02:36:47.000000000 -0800
|
||||
@@ -1 +1 @@
|
||||
-2009-12-25 "Lemming"
|
||||
+2009-12-25c "Lemming"
|
||||
diff -ur conf/msg conf/msg
|
||||
--- conf/msg 2009-12-25 02:14:41.000000000 -0800
|
||||
+++ conf/msg 2010-01-17 02:35:46.000000000 -0800
|
||||
@@ -1,4 +1,4 @@
|
||||
-23
|
||||
+25
|
||||
The first line of this file contains a number, indicating
|
||||
which notification messages should not be displayed. This
|
||||
is the only information sent to dokuwiki.org when the
|
||||
diff -ur lib/plugins/acl/admin.php lib/plugins/acl/admin.php
|
||||
--- lib/plugins/acl/admin.php 2009-12-25 02:14:41.000000000 -0800
|
||||
+++ lib/plugins/acl/admin.php 2010-01-17 02:35:46.000000000 -0800
|
||||
@@ -31,7 +31,7 @@
|
||||
return array(
|
||||
'author' => 'Andreas Gohr',
|
||||
'email' => 'andi@splitbrain.org',
|
||||
- 'date' => '2009-08-07',
|
||||
+ 'date' => '2010-01-17',
|
||||
'name' => 'ACL Manager',
|
||||
'desc' => 'Manage Page Access Control Lists',
|
||||
'url' => 'http://dokuwiki.org/plugin:acl',
|
||||
@@ -67,6 +67,7 @@
|
||||
// fresh 1:1 copy without replacements
|
||||
$AUTH_ACL = file(DOKU_CONF.'acl.auth.php');
|
||||
|
||||
+
|
||||
// namespace given?
|
||||
if($_REQUEST['ns'] == '*'){
|
||||
$this->ns = '*';
|
||||
@@ -89,7 +90,8 @@
|
||||
}
|
||||
|
||||
// handle modifications
|
||||
- if(isset($_REQUEST['cmd'])){
|
||||
+ if(isset($_REQUEST['cmd']) && checkSecurityToken()){
|
||||
+
|
||||
// scope for modifications
|
||||
if($this->ns){
|
||||
if($this->ns == '*'){
|
||||
@@ -310,6 +312,7 @@
|
||||
echo '<input type="hidden" name="id" value="'.hsc($ID).'" />'.NL;
|
||||
echo '<input type="hidden" name="do" value="admin" />'.NL;
|
||||
echo '<input type="hidden" name="page" value="acl" />'.NL;
|
||||
+ echo '<input type="hidden" name="sectok" value="'.getSecurityToken().'" />'.NL;
|
||||
echo '</div></form>'.NL;
|
||||
}
|
||||
|
||||
@@ -480,11 +483,11 @@
|
||||
$alt = '+';
|
||||
}
|
||||
$ret .= '<img src="'.$img.'" alt="'.$alt.'" />';
|
||||
- $ret .= '<a href="'.wl('',$this->_get_opts(array('ns'=>$item['id']))).'" class="idx_dir'.$cl.'">';
|
||||
+ $ret .= '<a href="'.wl('',$this->_get_opts(array('ns'=>$item['id'],'sectok'=>getSecurityToken()))).'" class="idx_dir'.$cl.'">';
|
||||
$ret .= $base;
|
||||
$ret .= '</a>';
|
||||
}else{
|
||||
- $ret .= '<a href="'.wl('',$this->_get_opts(array('id'=>$item['id'],'ns'=>''))).'" class="wikilink1'.$cl.'">';
|
||||
+ $ret .= '<a href="'.wl('',$this->_get_opts(array('id'=>$item['id'],'ns'=>'','sectok'=>getSecurityToken()))).'" class="wikilink1'.$cl.'">';
|
||||
$ret .= noNS($item['id']);
|
||||
$ret .= '</a>';
|
||||
}
|
||||
@@ -562,6 +565,7 @@
|
||||
echo '<input type="hidden" name="acl_w" value="'.hsc($this->who).'" />'.NL;
|
||||
echo '<input type="hidden" name="do" value="admin" />'.NL;
|
||||
echo '<input type="hidden" name="page" value="acl" />'.NL;
|
||||
+ echo '<input type="hidden" name="sectok" value="'.getSecurityToken().'" />'.NL;
|
||||
echo '<table class="inline">';
|
||||
echo '<tr>';
|
||||
echo '<th>'.$this->getLang('where').'</th>';
|
||||
diff -ur lib/plugins/acl/ajax.php lib/plugins/acl/ajax.php
|
||||
--- lib/plugins/acl/ajax.php 2009-12-25 02:14:41.000000000 -0800
|
||||
+++ lib/plugins/acl/ajax.php 2010-01-17 02:35:46.000000000 -0800
|
||||
@@ -16,12 +16,14 @@
|
||||
require_once(DOKU_INC.'inc/common.php');
|
||||
require_once(DOKU_INC.'inc/pageutils.php');
|
||||
require_once(DOKU_INC.'inc/auth.php');
|
||||
-//close sesseion
|
||||
+//close session
|
||||
session_write_close();
|
||||
|
||||
+if(!auth_isadmin()) die('for admins only');
|
||||
+if(!checkSecurityToken()) die('CRSF Attack');
|
||||
+
|
||||
$ID = getID();
|
||||
|
||||
-if(!auth_isadmin) die('for admins only');
|
||||
require_once(DOKU_INC.'inc/pluginutils.php');
|
||||
require_once(DOKU_INC.'inc/html.php');
|
||||
$acl = plugin_load('admin','acl');
|
||||
@@ -42,6 +44,7 @@
|
||||
if($ns == '*'){
|
||||
$ns ='';
|
||||
}
|
||||
+ $ns = cleanID($ns);
|
||||
$lvl = count(explode(':',$ns));
|
||||
$ns = utf8_encodeFN(str_replace(':','/',$ns));
|
||||
|
||||
diff -ur lib/plugins/acl/script.js lib/plugins/acl/script.js
|
||||
--- lib/plugins/acl/script.js 2009-12-25 02:14:41.000000000 -0800
|
||||
+++ lib/plugins/acl/script.js 2010-01-17 02:35:46.000000000 -0800
|
||||
@@ -48,7 +48,8 @@
|
||||
data[1] = ajax.encVar('id',frm.elements['id'].value);
|
||||
data[2] = ajax.encVar('acl_t',frm.elements['acl_t'].value);
|
||||
data[3] = ajax.encVar('acl_w',frm.elements['acl_w'].value);
|
||||
- data[4] = ajax.encVar('ajax','info');
|
||||
+ data[4] = ajax.encVar('sectok',frm.elements['sectok'].value);
|
||||
+ data[5] = ajax.encVar('ajax','info');
|
||||
|
||||
ajax.elementObj = $('acl__info');
|
||||
|
11
www/dokuwiki/files/patch-inc__DifferenceEngine.php
Normal file
11
www/dokuwiki/files/patch-inc__DifferenceEngine.php
Normal file
@ -0,0 +1,11 @@
|
||||
--- ./inc/DifferenceEngine.php.orig 2010-11-08 00:43:03.000000000 +0800
|
||||
+++ ./inc/DifferenceEngine.php 2010-11-09 02:54:41.000000000 +0800
|
||||
@@ -896,7 +896,7 @@
|
||||
}
|
||||
|
||||
function _split($lines) {
|
||||
- if (!preg_match_all('/ ( [^\S\n]+ | [0-9_A-Za-z\x80-\xff]+ | . ) (?: (?!< \n) [^\S\n])? /xs',
|
||||
+ if (!preg_match_all('/ ( [^\S\n]+ | [0-9_A-Za-z\x80-\xff]+ | . ) (?: (?!< \n) [^\S\n])? /xsu',
|
||||
implode("\n", $lines),
|
||||
$m)) {
|
||||
return array(array(''), array(''));
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user