1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
|
--- VERSION.orig 2014-09-29 18:20:01 UTC
+++ VERSION
@@ -1 +1 @@
-2014-09-29 "Hrun"
+2014-09-29a "Hrun"
--- doku.php.orig 2014-09-29 18:20:01 UTC
+++ doku.php
@@ -9,7 +9,7 @@
*/
// update message version
-$updateVersion = 46;
+$updateVersion = 46.1;
// xdebug_start_profiling();
--- inc/auth.php.orig 2014-09-29 18:20:01 UTC
+++ inc/auth.php
@@ -335,7 +335,6 @@
$ip = clientIP(true);
$uid = '';
$uid .= $INPUT->server->str('HTTP_USER_AGENT');
- $uid .= $INPUT->server->str('HTTP_ACCEPT_ENCODING');
$uid .= $INPUT->server->str('HTTP_ACCEPT_CHARSET');
$uid .= substr($ip, 0, strpos($ip, '.'));
$uid = strtolower($uid);
--- inc/lang/no/lang.php.orig 2014-09-29 18:20:01 UTC
+++ inc/lang/no/lang.php
@@ -116,7 +116,7 @@
$lang['txt_upload'] = 'Velg fil som skal lastes opp:';
$lang['txt_filename'] = 'Skriv inn wikinavn (alternativt):';
$lang['txt_overwrt'] = 'Overskriv eksisterende fil';
-$lang['maxuploadsize'] = 'Opplast maks % per fil.';
+$lang['maxuploadsize'] = 'Opplast maks %s per fil.';
$lang['lockedby'] = 'Låst av:';
$lang['lockexpire'] = 'Låsingen utløper:';
$lang['js']['willexpire'] = 'Din redigeringslås for dette dokumentet kommer snart til å utløpe.\nFor å unngå versjonskonflikter bør du forhåndsvise dokumentet ditt for å forlenge redigeringslåsen.';
--- lib/plugins/authplain/auth.php.orig 2014-09-29 18:20:01 UTC
+++ lib/plugins/authplain/auth.php
@@ -17,6 +17,9 @@
/** @var array filter pattern */
protected $_pattern = array();
+ /** @var bool safe version of preg_split */
+ protected $_pregsplit_safe = false;
+
/**
* Constructor
*
@@ -44,6 +47,8 @@
$this->cando['getUsers'] = true;
$this->cando['getUserCount'] = true;
}
+
+ $this->_pregsplit_safe = version_compare(PCRE_VERSION,'6.7','>=');
}
/**
@@ -329,7 +334,7 @@
if(empty($line)) continue;
/* NB: preg_split can be deprecated/replaced with str_getcsv once dokuwiki is min php 5.3 */
- $row = preg_split('/(?<![^\\\\]\\\\)\:/', $line, 5); // allow for : escaped as \:
+ $row = $this->_splitUserData($line);
$row = str_replace('\\:', ':', $row);
$row = str_replace('\\\\', '\\', $row);
@@ -342,6 +347,33 @@
}
}
+ protected function _splitUserData($line){
+ // due to a bug in PCRE 6.6, preg_split will fail with the regex we use here
+ // refer github issues 877 & 885
+ if ($this->_pregsplit_safe){
+ return preg_split('/(?<![^\\\\]\\\\)\:/', $line, 5); // allow for : escaped as \:
+ }
+
+ $row = array();
+ $piece = '';
+ $len = strlen($line);
+ for($i=0; $i<$len; $i++){
+ if ($line[$i]=='\\'){
+ $piece .= $line[$i];
+ $i++;
+ if ($i>=$len) break;
+ } else if ($line[$i]==':'){
+ $row[] = $piece;
+ $piece = '';
+ continue;
+ }
+ $piece .= $line[$i];
+ }
+ $row[] = $piece;
+
+ return $row;
+ }
+
/**
* return true if $user + $info match $filter criteria, false otherwise
*
|