Merge lp:~julian-ladisch/ubuntu/wily/phpmyadmin/4.4.15.1-1 into lp:ubuntu/wily/phpmyadmin

Proposed by Julian Ladisch
Status: Needs review
Proposed branch: lp:~julian-ladisch/ubuntu/wily/phpmyadmin/4.4.15.1-1
Merge into: lp:ubuntu/wily/phpmyadmin
Diff against target: 8583 lines (+2921/-2024)
71 files modified
.pc/setup-message.patch/setup/frames/index.inc.php (+1/-0)
ChangeLog (+32/-0)
README (+1/-1)
RELEASE-DATE-4.4.13.1 (+0/-1)
RELEASE-DATE-4.4.15.1 (+1/-0)
debian/changelog (+15/-0)
debian/patches/setup-message.patch (+5/-3)
doc/conf.py (+1/-1)
doc/html/.buildinfo (+1/-1)
doc/html/_sources/require.txt (+1/-1)
doc/html/config.html (+5/-5)
doc/html/copyright.html (+5/-5)
doc/html/credits.html (+5/-5)
doc/html/developers.html (+5/-5)
doc/html/faq.html (+5/-5)
doc/html/genindex.html (+5/-5)
doc/html/glossary.html (+5/-5)
doc/html/import_export.html (+5/-5)
doc/html/index.html (+5/-5)
doc/html/intro.html (+5/-5)
doc/html/other.html (+5/-5)
doc/html/privileges.html (+5/-5)
doc/html/require.html (+6/-6)
doc/html/search.html (+5/-5)
doc/html/setup.html (+5/-5)
doc/html/transformations.html (+5/-5)
doc/html/user.html (+5/-5)
doc/html/vendors.html (+5/-5)
doc/require.rst (+1/-1)
import.php (+1/-1)
js/functions.js (+2/-1)
js/line_counts.php (+10/-10)
js/pmd/move.js (+6/-5)
js/tbl_operations.js (+4/-1)
libraries/Config.class.php (+1/-1)
libraries/DatabaseInterface.class.php (+34/-32)
libraries/DisplayResults.class.php (+3/-1)
libraries/Scripts.class.php (+10/-5)
libraries/Util.class.php (+4/-153)
libraries/VersionInformation.php (+270/-0)
libraries/config/messages.inc.php (+1/-0)
libraries/dbi/DBIDummy.class.php (+6/-2)
libraries/language_stats.inc.php (+9/-9)
libraries/phpseclib/Crypt/AES.php (+74/-130)
libraries/phpseclib/Crypt/Base.php (+913/-400)
libraries/phpseclib/Crypt/Random.php (+60/-81)
libraries/phpseclib/Crypt/Rijndael.php (+347/-680)
libraries/phpseclib/LICENSE (+21/-0)
libraries/plugins/auth/AuthenticationCookie.class.php (+18/-41)
libraries/plugins/auth/recaptcha/ReCaptcha/ReCaptcha.php (+97/-0)
libraries/plugins/auth/recaptcha/ReCaptcha/RequestMethod.php (+42/-0)
libraries/plugins/auth/recaptcha/ReCaptcha/RequestMethod/Post.php (+70/-0)
libraries/plugins/auth/recaptcha/ReCaptcha/RequestMethod/Socket.php (+104/-0)
libraries/plugins/auth/recaptcha/ReCaptcha/RequestMethod/SocketPost.php (+120/-0)
libraries/plugins/auth/recaptcha/ReCaptcha/RequestParameters.php (+103/-0)
libraries/plugins/auth/recaptcha/ReCaptcha/Response.php (+102/-0)
libraries/plugins/auth/recaptcha/autoload.php (+38/-0)
libraries/plugins/auth/recaptcha/recaptchalib.php (+0/-140)
libraries/plugins/import/ImportSql.class.php (+1/-1)
libraries/rte/rte_routines.lib.php (+5/-0)
libraries/server_privileges.lib.php (+1/-1)
libraries/structure.lib.php (+6/-3)
libraries/tbl_relation.lib.php (+8/-6)
setup/frames/index.inc.php (+1/-0)
setup/lib/index.lib.php (+12/-5)
tbl_replace.php (+1/-1)
tbl_row_action.php (+10/-0)
themes/original/sprites.lib.php (+114/-99)
themes/pmahomme/sprites.lib.php (+125/-110)
url.php (+2/-1)
version_check.php (+15/-4)
To merge this branch: bzr merge lp:~julian-ladisch/ubuntu/wily/phpmyadmin/4.4.15.1-1
Reviewer Review Type Date Requested Status
Marc Deslauriers Needs Fixing
Review via email: mp+275897@code.launchpad.net

Commit message

New upstream release 4.4.15.1 fixing CVE-2015-6830 and CVE-2015-7873

Description of the change

* New upstream release.
* Security Update: Vulnerability that allows bypassing the reCaptcha test
  - CVE-2015-6830
  - https://www.phpmyadmin.net/security/PMASA-2015-4/
  - LP: #1510525
* Security Update: Content spoofing vulnerability when
  redirecting user to an external site
  - CVE-2015-7873
  - https://www.phpmyadmin.net/security/PMASA-2015-5/
  - LP: #1510521

To post a comment you must log in.
Revision history for this message
Marc Deslauriers (mdeslaur) wrote :

Thank you for taking the time to report this bug and helping to make Ubuntu better. Since the package referred to in this bug is in universe or multiverse, it is community maintained. I see that you have attached patches to update the Ubuntu packages to the new upstream version. While this work is appreciated, we cannot publish your patches because this does not follow Ubuntu's policy of backporting security patches. If you are able, perhaps you could prepare debdiffs to fix this by following https://wiki.ubuntu.com/SecurityUpdateProcedures.

review: Needs Fixing

Unmerged revisions

127. By Julian Ladisch

new upstream version; CVE-2015-6830; CVE-2015-7873

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file '.pc/setup-message.patch/setup/frames/index.inc.php'
2--- .pc/setup-message.patch/setup/frames/index.inc.php 2015-07-07 10:25:56 +0000
3+++ .pc/setup-message.patch/setup/frames/index.inc.php 2015-10-27 17:36:50 +0000
4@@ -16,6 +16,7 @@
5 require_once './libraries/display_select_lang.lib.php';
6 require_once './libraries/config/FormDisplay.class.php';
7 require_once './libraries/config/ServerConfigChecks.class.php';
8+require_once './libraries/VersionInformation.php';
9 require_once './setup/lib/index.lib.php';
10
11 // prepare unfiltered language list
12
13=== modified file 'ChangeLog'
14--- ChangeLog 2015-08-10 10:02:56 +0000
15+++ ChangeLog 2015-10-27 17:36:50 +0000
16@@ -1,6 +1,38 @@
17 phpMyAdmin - ChangeLog
18 ======================
19
20+4.4.15.1 (2015-10-23)
21+- issue #11464 phpMyAdmin suggests upgrading to newer version not usable on that system
22+- issue [security] Content spoofing on url.php
23+
24+4.4.15.0 (2015-09-20)
25+- issue #11411 Undefined "replace" function on numeric scalar
26+- issue #11421 Stored-proc / routine - broken parameter parsing
27+- issue Missing name for configuration read_as_multibytes
28+- issue #11431 Incorrect "No row selected" message
29+- issue #11447 MySQL 5.5 and the language system variable
30+- issue #11452 Semantics of export and import icons are mixed up
31+- issue #11451 Designer-Bug in move.js on multiple server configuration
32+- issue #11458 Invalid UTF-8 sequence in argument
33+- issue #11457 Request URI too large
34+- issue Invalid argument supplied for foreach()
35+- issue #11461 Foreign key constraints for InnoDB tables with upper-case letters disabled
36+- issue #11487 Warning when entering Query page
37+
38+4.4.14.1 (2015-09-08)
39+- issue [security] reCaptcha bypass
40+
41+4.4.14.0 (2015-08-20)
42+- issue #11367 Export after search, missing WHERE clause
43+- issue #11380 Incomplete message after import
44+- issue Incorrect scalar type declaration (reported under PHP 7)
45+- issue #11389 ReCaptcha produces deprecated messages under PHP 7
46+- issue #11387 phpseclib < 2.0 produces deprecated messages on PHP 7
47+- issue #11404 "Switch to copied table" doesn't work
48+- issue #11406 Missing quotes after calling "distinct values"
49+- issue #11386 Cannot import database with long data in one column
50+- issue #11410 SPATIAL index option is not clickable
51+
52 4.4.13.1 (2015-08-08)
53 - issue #11368 SQL error when importing phpMyAdmin dump file
54
55
56=== modified file 'README'
57--- README 2015-08-10 10:02:56 +0000
58+++ README 2015-10-27 17:36:50 +0000
59@@ -1,7 +1,7 @@
60 phpMyAdmin - Readme
61 ===================
62
63-Version 4.4.13.1
64+Version 4.4.15.1
65
66 A set of PHP-scripts to manage MySQL over the web.
67
68
69=== removed file 'RELEASE-DATE-4.4.13.1'
70--- RELEASE-DATE-4.4.13.1 2015-08-10 10:02:56 +0000
71+++ RELEASE-DATE-4.4.13.1 1970-01-01 00:00:00 +0000
72@@ -1,1 +0,0 @@
73-Sat Aug 8 16:22:16 UTC 2015
74
75=== added file 'RELEASE-DATE-4.4.15.1'
76--- RELEASE-DATE-4.4.15.1 1970-01-01 00:00:00 +0000
77+++ RELEASE-DATE-4.4.15.1 2015-10-27 17:36:50 +0000
78@@ -0,0 +1,1 @@
79+Fri Oct 23 11:29:01 UTC 2015
80
81=== modified file 'debian/changelog'
82--- debian/changelog 2015-08-10 10:02:56 +0000
83+++ debian/changelog 2015-10-27 17:36:50 +0000
84@@ -1,3 +1,18 @@
85+phpmyadmin (4:4.4.15.1-1) unstable; urgency=medium
86+
87+ * New upstream release.
88+ * Security Update: Vulnerability that allows bypassing the reCaptcha test
89+ - CVE-2015-6830
90+ - https://www.phpmyadmin.net/security/PMASA-2015-4/
91+ - LP: #1510525
92+ * Security Update: Content spoofing vulnerability when
93+ redirecting user to an external site
94+ - CVE-2015-7873
95+ - https://www.phpmyadmin.net/security/PMASA-2015-5/
96+ - LP: #1510521
97+
98+ -- Julian Ladisch <launchpad.net-hpe@ladisch.de> Tue, 27 Oct 2015 18:14:40 +0100
99+
100 phpmyadmin (4:4.4.13.1-1) unstable; urgency=medium
101
102 * New upstream release.
103
104=== modified file 'debian/patches/setup-message.patch'
105--- debian/patches/setup-message.patch 2015-05-05 13:48:55 +0000
106+++ debian/patches/setup-message.patch 2015-10-27 17:36:50 +0000
107@@ -2,9 +2,11 @@
108 From: Michal Čihař <nijel@debian.org>
109 Forwarded: not-needed
110
111---- a/setup/frames/index.inc.php
112-+++ b/setup/frames/index.inc.php
113-@@ -119,9 +119,7 @@
114+Index: phpmyadmin/setup/frames/index.inc.php
115+===================================================================
116+--- phpmyadmin.orig/setup/frames/index.inc.php 2015-10-27 18:16:26.694967720 +0100
117++++ phpmyadmin/setup/frames/index.inc.php 2015-10-27 18:16:26.694967720 +0100
118+@@ -120,9 +120,7 @@
119 'notice', uniqid('config_saved'), __('Configuration saved.'),
120 PMA_sanitize(
121 __(
122
123=== modified file 'doc/conf.py'
124--- doc/conf.py 2015-08-10 10:02:56 +0000
125+++ doc/conf.py 2015-10-27 17:36:50 +0000
126@@ -51,7 +51,7 @@
127 # built documents.
128 #
129 # The short X.Y version.
130-version = '4.4.13.1'
131+version = '4.4.15.1'
132 # The full version, including alpha/beta/rc tags.
133 release = version
134
135
136=== modified file 'doc/doctrees/config.doctree'
137Binary files doc/doctrees/config.doctree 2015-08-10 10:02:56 +0000 and doc/doctrees/config.doctree 2015-10-27 17:36:50 +0000 differ
138=== modified file 'doc/doctrees/copyright.doctree'
139Binary files doc/doctrees/copyright.doctree 2015-08-10 10:02:56 +0000 and doc/doctrees/copyright.doctree 2015-10-27 17:36:50 +0000 differ
140=== modified file 'doc/doctrees/credits.doctree'
141Binary files doc/doctrees/credits.doctree 2015-08-10 10:02:56 +0000 and doc/doctrees/credits.doctree 2015-10-27 17:36:50 +0000 differ
142=== modified file 'doc/doctrees/developers.doctree'
143Binary files doc/doctrees/developers.doctree 2015-08-10 10:02:56 +0000 and doc/doctrees/developers.doctree 2015-10-27 17:36:50 +0000 differ
144=== modified file 'doc/doctrees/environment.pickle'
145Binary files doc/doctrees/environment.pickle 2015-08-10 10:02:56 +0000 and doc/doctrees/environment.pickle 2015-10-27 17:36:50 +0000 differ
146=== modified file 'doc/doctrees/faq.doctree'
147Binary files doc/doctrees/faq.doctree 2015-08-10 10:02:56 +0000 and doc/doctrees/faq.doctree 2015-10-27 17:36:50 +0000 differ
148=== modified file 'doc/doctrees/glossary.doctree'
149Binary files doc/doctrees/glossary.doctree 2015-08-10 10:02:56 +0000 and doc/doctrees/glossary.doctree 2015-10-27 17:36:50 +0000 differ
150=== modified file 'doc/doctrees/import_export.doctree'
151Binary files doc/doctrees/import_export.doctree 2015-08-10 10:02:56 +0000 and doc/doctrees/import_export.doctree 2015-10-27 17:36:50 +0000 differ
152=== modified file 'doc/doctrees/index.doctree'
153Binary files doc/doctrees/index.doctree 2015-08-10 10:02:56 +0000 and doc/doctrees/index.doctree 2015-10-27 17:36:50 +0000 differ
154=== modified file 'doc/doctrees/intro.doctree'
155Binary files doc/doctrees/intro.doctree 2015-08-10 10:02:56 +0000 and doc/doctrees/intro.doctree 2015-10-27 17:36:50 +0000 differ
156=== modified file 'doc/doctrees/other.doctree'
157Binary files doc/doctrees/other.doctree 2015-08-10 10:02:56 +0000 and doc/doctrees/other.doctree 2015-10-27 17:36:50 +0000 differ
158=== modified file 'doc/doctrees/privileges.doctree'
159Binary files doc/doctrees/privileges.doctree 2015-08-10 10:02:56 +0000 and doc/doctrees/privileges.doctree 2015-10-27 17:36:50 +0000 differ
160=== modified file 'doc/doctrees/require.doctree'
161Binary files doc/doctrees/require.doctree 2015-08-10 10:02:56 +0000 and doc/doctrees/require.doctree 2015-10-27 17:36:50 +0000 differ
162=== modified file 'doc/doctrees/setup.doctree'
163Binary files doc/doctrees/setup.doctree 2015-08-10 10:02:56 +0000 and doc/doctrees/setup.doctree 2015-10-27 17:36:50 +0000 differ
164=== modified file 'doc/doctrees/transformations.doctree'
165Binary files doc/doctrees/transformations.doctree 2015-08-10 10:02:56 +0000 and doc/doctrees/transformations.doctree 2015-10-27 17:36:50 +0000 differ
166=== modified file 'doc/doctrees/user.doctree'
167Binary files doc/doctrees/user.doctree 2015-08-10 10:02:56 +0000 and doc/doctrees/user.doctree 2015-10-27 17:36:50 +0000 differ
168=== modified file 'doc/doctrees/vendors.doctree'
169Binary files doc/doctrees/vendors.doctree 2015-08-10 10:02:56 +0000 and doc/doctrees/vendors.doctree 2015-10-27 17:36:50 +0000 differ
170=== modified file 'doc/html/.buildinfo'
171--- doc/html/.buildinfo 2015-08-10 10:02:56 +0000
172+++ doc/html/.buildinfo 2015-10-27 17:36:50 +0000
173@@ -1,4 +1,4 @@
174 # Sphinx build info version 1
175 # This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
176-config: cca84bdc9e3e4dabe9e534d2ceab6a20
177+config: 48132e5c8669af439ab5d63e8a0e08cb
178 tags: 645f666f9bcd5a90fca523b33c5a78b7
179
180=== modified file 'doc/html/_sources/require.txt'
181--- doc/html/_sources/require.txt 2015-05-28 15:02:54 +0000
182+++ doc/html/_sources/require.txt 2015-10-27 17:36:50 +0000
183@@ -12,7 +12,7 @@
184 PHP
185 ---
186
187-* You need PHP 5.3.0 or newer, with ``session`` support, the Standard PHP Library
188+* You need PHP 5.3.7 or newer, with ``session`` support, the Standard PHP Library
189 (SPL) extension, JSON support, and the ``mbstring`` extension.
190
191 * To support uploading of ZIP files, you need the PHP ``zip`` extension.
192
193=== modified file 'doc/html/config.html'
194--- doc/html/config.html 2015-08-10 10:02:56 +0000
195+++ doc/html/config.html 2015-10-27 17:36:50 +0000
196@@ -6,7 +6,7 @@
197 <head>
198 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
199
200- <title>Configuration &mdash; phpMyAdmin 4.4.13.1 documentation</title>
201+ <title>Configuration &mdash; phpMyAdmin 4.4.15.1 documentation</title>
202
203 <link rel="stylesheet" href="_static/default.css" type="text/css" />
204 <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
205@@ -14,7 +14,7 @@
206 <script type="text/javascript">
207 var DOCUMENTATION_OPTIONS = {
208 URL_ROOT: './',
209- VERSION: '4.4.13.1',
210+ VERSION: '4.4.15.1',
211 COLLAPSE_INDEX: false,
212 FILE_SUFFIX: '.html',
213 HAS_SOURCE: true
214@@ -24,7 +24,7 @@
215 <script type="text/javascript" src="_static/underscore.js"></script>
216 <script type="text/javascript" src="_static/doctools.js"></script>
217 <link rel="copyright" title="Copyright" href="copyright.html" />
218- <link rel="top" title="phpMyAdmin 4.4.13.1 documentation" href="index.html" />
219+ <link rel="top" title="phpMyAdmin 4.4.15.1 documentation" href="index.html" />
220 <link rel="next" title="User Guide" href="user.html" />
221 <link rel="prev" title="Installation" href="setup.html" />
222 </head>
223@@ -41,7 +41,7 @@
224 <li class="right" >
225 <a href="setup.html" title="Installation"
226 accesskey="P">previous</a> |</li>
227- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
228+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
229 </ul>
230 </div>
231
232@@ -4992,7 +4992,7 @@
233 <li class="right" >
234 <a href="setup.html" title="Installation"
235 >previous</a> |</li>
236- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
237+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
238 </ul>
239 </div>
240 <div class="footer">
241
242=== modified file 'doc/html/copyright.html'
243--- doc/html/copyright.html 2015-08-10 10:02:56 +0000
244+++ doc/html/copyright.html 2015-10-27 17:36:50 +0000
245@@ -6,7 +6,7 @@
246 <head>
247 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
248
249- <title>Copyright &mdash; phpMyAdmin 4.4.13.1 documentation</title>
250+ <title>Copyright &mdash; phpMyAdmin 4.4.15.1 documentation</title>
251
252 <link rel="stylesheet" href="_static/default.css" type="text/css" />
253 <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
254@@ -14,7 +14,7 @@
255 <script type="text/javascript">
256 var DOCUMENTATION_OPTIONS = {
257 URL_ROOT: './',
258- VERSION: '4.4.13.1',
259+ VERSION: '4.4.15.1',
260 COLLAPSE_INDEX: false,
261 FILE_SUFFIX: '.html',
262 HAS_SOURCE: true
263@@ -24,7 +24,7 @@
264 <script type="text/javascript" src="_static/underscore.js"></script>
265 <script type="text/javascript" src="_static/doctools.js"></script>
266 <link rel="copyright" title="Copyright" href="#" />
267- <link rel="top" title="phpMyAdmin 4.4.13.1 documentation" href="index.html" />
268+ <link rel="top" title="phpMyAdmin 4.4.15.1 documentation" href="index.html" />
269 <link rel="next" title="Credits" href="credits.html" />
270 <link rel="prev" title="Distributing and packaging phpMyAdmin" href="vendors.html" />
271 </head>
272@@ -41,7 +41,7 @@
273 <li class="right" >
274 <a href="vendors.html" title="Distributing and packaging phpMyAdmin"
275 accesskey="P">previous</a> |</li>
276- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
277+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
278 </ul>
279 </div>
280
281@@ -144,7 +144,7 @@
282 <li class="right" >
283 <a href="vendors.html" title="Distributing and packaging phpMyAdmin"
284 >previous</a> |</li>
285- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
286+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
287 </ul>
288 </div>
289 <div class="footer">
290
291=== modified file 'doc/html/credits.html'
292--- doc/html/credits.html 2015-08-10 10:02:56 +0000
293+++ doc/html/credits.html 2015-10-27 17:36:50 +0000
294@@ -6,7 +6,7 @@
295 <head>
296 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
297
298- <title>Credits &mdash; phpMyAdmin 4.4.13.1 documentation</title>
299+ <title>Credits &mdash; phpMyAdmin 4.4.15.1 documentation</title>
300
301 <link rel="stylesheet" href="_static/default.css" type="text/css" />
302 <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
303@@ -14,7 +14,7 @@
304 <script type="text/javascript">
305 var DOCUMENTATION_OPTIONS = {
306 URL_ROOT: './',
307- VERSION: '4.4.13.1',
308+ VERSION: '4.4.15.1',
309 COLLAPSE_INDEX: false,
310 FILE_SUFFIX: '.html',
311 HAS_SOURCE: true
312@@ -24,7 +24,7 @@
313 <script type="text/javascript" src="_static/underscore.js"></script>
314 <script type="text/javascript" src="_static/doctools.js"></script>
315 <link rel="copyright" title="Copyright" href="copyright.html" />
316- <link rel="top" title="phpMyAdmin 4.4.13.1 documentation" href="index.html" />
317+ <link rel="top" title="phpMyAdmin 4.4.15.1 documentation" href="index.html" />
318 <link rel="next" title="Glossary" href="glossary.html" />
319 <link rel="prev" title="Copyright" href="copyright.html" />
320 </head>
321@@ -41,7 +41,7 @@
322 <li class="right" >
323 <a href="copyright.html" title="Copyright"
324 accesskey="P">previous</a> |</li>
325- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
326+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
327 </ul>
328 </div>
329
330@@ -701,7 +701,7 @@
331 <li class="right" >
332 <a href="copyright.html" title="Copyright"
333 >previous</a> |</li>
334- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
335+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
336 </ul>
337 </div>
338 <div class="footer">
339
340=== modified file 'doc/html/developers.html'
341--- doc/html/developers.html 2015-08-10 10:02:56 +0000
342+++ doc/html/developers.html 2015-10-27 17:36:50 +0000
343@@ -6,7 +6,7 @@
344 <head>
345 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
346
347- <title>Developers Information &mdash; phpMyAdmin 4.4.13.1 documentation</title>
348+ <title>Developers Information &mdash; phpMyAdmin 4.4.15.1 documentation</title>
349
350 <link rel="stylesheet" href="_static/default.css" type="text/css" />
351 <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
352@@ -14,7 +14,7 @@
353 <script type="text/javascript">
354 var DOCUMENTATION_OPTIONS = {
355 URL_ROOT: './',
356- VERSION: '4.4.13.1',
357+ VERSION: '4.4.15.1',
358 COLLAPSE_INDEX: false,
359 FILE_SUFFIX: '.html',
360 HAS_SOURCE: true
361@@ -24,7 +24,7 @@
362 <script type="text/javascript" src="_static/underscore.js"></script>
363 <script type="text/javascript" src="_static/doctools.js"></script>
364 <link rel="copyright" title="Copyright" href="copyright.html" />
365- <link rel="top" title="phpMyAdmin 4.4.13.1 documentation" href="index.html" />
366+ <link rel="top" title="phpMyAdmin 4.4.15.1 documentation" href="index.html" />
367 <link rel="next" title="Distributing and packaging phpMyAdmin" href="vendors.html" />
368 <link rel="prev" title="FAQ - Frequently Asked Questions" href="faq.html" />
369 </head>
370@@ -41,7 +41,7 @@
371 <li class="right" >
372 <a href="faq.html" title="FAQ - Frequently Asked Questions"
373 accesskey="P">previous</a> |</li>
374- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
375+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
376 </ul>
377 </div>
378
379@@ -105,7 +105,7 @@
380 <li class="right" >
381 <a href="faq.html" title="FAQ - Frequently Asked Questions"
382 >previous</a> |</li>
383- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
384+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
385 </ul>
386 </div>
387 <div class="footer">
388
389=== modified file 'doc/html/faq.html'
390--- doc/html/faq.html 2015-08-10 10:02:56 +0000
391+++ doc/html/faq.html 2015-10-27 17:36:50 +0000
392@@ -6,7 +6,7 @@
393 <head>
394 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
395
396- <title>FAQ - Frequently Asked Questions &mdash; phpMyAdmin 4.4.13.1 documentation</title>
397+ <title>FAQ - Frequently Asked Questions &mdash; phpMyAdmin 4.4.15.1 documentation</title>
398
399 <link rel="stylesheet" href="_static/default.css" type="text/css" />
400 <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
401@@ -14,7 +14,7 @@
402 <script type="text/javascript">
403 var DOCUMENTATION_OPTIONS = {
404 URL_ROOT: './',
405- VERSION: '4.4.13.1',
406+ VERSION: '4.4.15.1',
407 COLLAPSE_INDEX: false,
408 FILE_SUFFIX: '.html',
409 HAS_SOURCE: true
410@@ -24,7 +24,7 @@
411 <script type="text/javascript" src="_static/underscore.js"></script>
412 <script type="text/javascript" src="_static/doctools.js"></script>
413 <link rel="copyright" title="Copyright" href="copyright.html" />
414- <link rel="top" title="phpMyAdmin 4.4.13.1 documentation" href="index.html" />
415+ <link rel="top" title="phpMyAdmin 4.4.15.1 documentation" href="index.html" />
416 <link rel="next" title="Developers Information" href="developers.html" />
417 <link rel="prev" title="Import and export" href="import_export.html" />
418 </head>
419@@ -41,7 +41,7 @@
420 <li class="right" >
421 <a href="import_export.html" title="Import and export"
422 accesskey="P">previous</a> |</li>
423- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
424+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
425 </ul>
426 </div>
427
428@@ -1850,7 +1850,7 @@
429 <li class="right" >
430 <a href="import_export.html" title="Import and export"
431 >previous</a> |</li>
432- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
433+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
434 </ul>
435 </div>
436 <div class="footer">
437
438=== modified file 'doc/html/genindex.html'
439--- doc/html/genindex.html 2015-08-10 10:02:56 +0000
440+++ doc/html/genindex.html 2015-10-27 17:36:50 +0000
441@@ -7,7 +7,7 @@
442 <head>
443 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
444
445- <title>Index &mdash; phpMyAdmin 4.4.13.1 documentation</title>
446+ <title>Index &mdash; phpMyAdmin 4.4.15.1 documentation</title>
447
448 <link rel="stylesheet" href="_static/default.css" type="text/css" />
449 <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
450@@ -15,7 +15,7 @@
451 <script type="text/javascript">
452 var DOCUMENTATION_OPTIONS = {
453 URL_ROOT: './',
454- VERSION: '4.4.13.1',
455+ VERSION: '4.4.15.1',
456 COLLAPSE_INDEX: false,
457 FILE_SUFFIX: '.html',
458 HAS_SOURCE: true
459@@ -25,7 +25,7 @@
460 <script type="text/javascript" src="_static/underscore.js"></script>
461 <script type="text/javascript" src="_static/doctools.js"></script>
462 <link rel="copyright" title="Copyright" href="copyright.html" />
463- <link rel="top" title="phpMyAdmin 4.4.13.1 documentation" href="index.html" />
464+ <link rel="top" title="phpMyAdmin 4.4.15.1 documentation" href="index.html" />
465 </head>
466 <body>
467 <div class="related">
468@@ -34,7 +34,7 @@
469 <li class="right" style="margin-right: 10px">
470 <a href="#" title="General Index"
471 accesskey="I">index</a></li>
472- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
473+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
474 </ul>
475 </div>
476
477@@ -3793,7 +3793,7 @@
478 <li class="right" style="margin-right: 10px">
479 <a href="#" title="General Index"
480 >index</a></li>
481- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
482+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
483 </ul>
484 </div>
485 <div class="footer">
486
487=== modified file 'doc/html/glossary.html'
488--- doc/html/glossary.html 2015-08-10 10:02:56 +0000
489+++ doc/html/glossary.html 2015-10-27 17:36:50 +0000
490@@ -6,7 +6,7 @@
491 <head>
492 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
493
494- <title>Glossary &mdash; phpMyAdmin 4.4.13.1 documentation</title>
495+ <title>Glossary &mdash; phpMyAdmin 4.4.15.1 documentation</title>
496
497 <link rel="stylesheet" href="_static/default.css" type="text/css" />
498 <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
499@@ -14,7 +14,7 @@
500 <script type="text/javascript">
501 var DOCUMENTATION_OPTIONS = {
502 URL_ROOT: './',
503- VERSION: '4.4.13.1',
504+ VERSION: '4.4.15.1',
505 COLLAPSE_INDEX: false,
506 FILE_SUFFIX: '.html',
507 HAS_SOURCE: true
508@@ -24,7 +24,7 @@
509 <script type="text/javascript" src="_static/underscore.js"></script>
510 <script type="text/javascript" src="_static/doctools.js"></script>
511 <link rel="copyright" title="Copyright" href="copyright.html" />
512- <link rel="top" title="phpMyAdmin 4.4.13.1 documentation" href="index.html" />
513+ <link rel="top" title="phpMyAdmin 4.4.15.1 documentation" href="index.html" />
514 <link rel="prev" title="Credits" href="credits.html" />
515 </head>
516 <body>
517@@ -37,7 +37,7 @@
518 <li class="right" >
519 <a href="credits.html" title="Credits"
520 accesskey="P">previous</a> |</li>
521- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
522+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
523 </ul>
524 </div>
525
526@@ -605,7 +605,7 @@
527 <li class="right" >
528 <a href="credits.html" title="Credits"
529 >previous</a> |</li>
530- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
531+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
532 </ul>
533 </div>
534 <div class="footer">
535
536=== modified file 'doc/html/import_export.html'
537--- doc/html/import_export.html 2015-08-10 10:02:56 +0000
538+++ doc/html/import_export.html 2015-10-27 17:36:50 +0000
539@@ -6,7 +6,7 @@
540 <head>
541 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
542
543- <title>Import and export &mdash; phpMyAdmin 4.4.13.1 documentation</title>
544+ <title>Import and export &mdash; phpMyAdmin 4.4.15.1 documentation</title>
545
546 <link rel="stylesheet" href="_static/default.css" type="text/css" />
547 <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
548@@ -14,7 +14,7 @@
549 <script type="text/javascript">
550 var DOCUMENTATION_OPTIONS = {
551 URL_ROOT: './',
552- VERSION: '4.4.13.1',
553+ VERSION: '4.4.15.1',
554 COLLAPSE_INDEX: false,
555 FILE_SUFFIX: '.html',
556 HAS_SOURCE: true
557@@ -24,7 +24,7 @@
558 <script type="text/javascript" src="_static/underscore.js"></script>
559 <script type="text/javascript" src="_static/doctools.js"></script>
560 <link rel="copyright" title="Copyright" href="copyright.html" />
561- <link rel="top" title="phpMyAdmin 4.4.13.1 documentation" href="index.html" />
562+ <link rel="top" title="phpMyAdmin 4.4.15.1 documentation" href="index.html" />
563 <link rel="up" title="User Guide" href="user.html" />
564 <link rel="next" title="FAQ - Frequently Asked Questions" href="faq.html" />
565 <link rel="prev" title="Other sources of information" href="other.html" />
566@@ -42,7 +42,7 @@
567 <li class="right" >
568 <a href="other.html" title="Other sources of information"
569 accesskey="P">previous</a> |</li>
570- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
571+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
572 <li><a href="user.html" accesskey="U">User Guide</a> &raquo;</li>
573 </ul>
574 </div>
575@@ -134,7 +134,7 @@
576 <li class="right" >
577 <a href="other.html" title="Other sources of information"
578 >previous</a> |</li>
579- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
580+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
581 <li><a href="user.html" >User Guide</a> &raquo;</li>
582 </ul>
583 </div>
584
585=== modified file 'doc/html/index.html'
586--- doc/html/index.html 2015-08-10 10:02:56 +0000
587+++ doc/html/index.html 2015-10-27 17:36:50 +0000
588@@ -6,7 +6,7 @@
589 <head>
590 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
591
592- <title>Welcome to phpMyAdmin’s documentation! &mdash; phpMyAdmin 4.4.13.1 documentation</title>
593+ <title>Welcome to phpMyAdmin’s documentation! &mdash; phpMyAdmin 4.4.15.1 documentation</title>
594
595 <link rel="stylesheet" href="_static/default.css" type="text/css" />
596 <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
597@@ -14,7 +14,7 @@
598 <script type="text/javascript">
599 var DOCUMENTATION_OPTIONS = {
600 URL_ROOT: './',
601- VERSION: '4.4.13.1',
602+ VERSION: '4.4.15.1',
603 COLLAPSE_INDEX: false,
604 FILE_SUFFIX: '.html',
605 HAS_SOURCE: true
606@@ -24,7 +24,7 @@
607 <script type="text/javascript" src="_static/underscore.js"></script>
608 <script type="text/javascript" src="_static/doctools.js"></script>
609 <link rel="copyright" title="Copyright" href="copyright.html" />
610- <link rel="top" title="phpMyAdmin 4.4.13.1 documentation" href="#" />
611+ <link rel="top" title="phpMyAdmin 4.4.15.1 documentation" href="#" />
612 <link rel="next" title="Introduction" href="intro.html" />
613 </head>
614 <body>
615@@ -37,7 +37,7 @@
616 <li class="right" >
617 <a href="intro.html" title="Introduction"
618 accesskey="N">next</a> |</li>
619- <li><a href="#">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
620+ <li><a href="#">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
621 </ul>
622 </div>
623
624@@ -195,7 +195,7 @@
625 <li class="right" >
626 <a href="intro.html" title="Introduction"
627 >next</a> |</li>
628- <li><a href="#">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
629+ <li><a href="#">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
630 </ul>
631 </div>
632 <div class="footer">
633
634=== modified file 'doc/html/intro.html'
635--- doc/html/intro.html 2015-08-10 10:02:56 +0000
636+++ doc/html/intro.html 2015-10-27 17:36:50 +0000
637@@ -6,7 +6,7 @@
638 <head>
639 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
640
641- <title>Introduction &mdash; phpMyAdmin 4.4.13.1 documentation</title>
642+ <title>Introduction &mdash; phpMyAdmin 4.4.15.1 documentation</title>
643
644 <link rel="stylesheet" href="_static/default.css" type="text/css" />
645 <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
646@@ -14,7 +14,7 @@
647 <script type="text/javascript">
648 var DOCUMENTATION_OPTIONS = {
649 URL_ROOT: './',
650- VERSION: '4.4.13.1',
651+ VERSION: '4.4.15.1',
652 COLLAPSE_INDEX: false,
653 FILE_SUFFIX: '.html',
654 HAS_SOURCE: true
655@@ -24,7 +24,7 @@
656 <script type="text/javascript" src="_static/underscore.js"></script>
657 <script type="text/javascript" src="_static/doctools.js"></script>
658 <link rel="copyright" title="Copyright" href="copyright.html" />
659- <link rel="top" title="phpMyAdmin 4.4.13.1 documentation" href="index.html" />
660+ <link rel="top" title="phpMyAdmin 4.4.15.1 documentation" href="index.html" />
661 <link rel="next" title="Requirements" href="require.html" />
662 <link rel="prev" title="Welcome to phpMyAdmin’s documentation!" href="index.html" />
663 </head>
664@@ -41,7 +41,7 @@
665 <li class="right" >
666 <a href="index.html" title="Welcome to phpMyAdmin’s documentation!"
667 accesskey="P">previous</a> |</li>
668- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
669+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
670 </ul>
671 </div>
672
673@@ -169,7 +169,7 @@
674 <li class="right" >
675 <a href="index.html" title="Welcome to phpMyAdmin’s documentation!"
676 >previous</a> |</li>
677- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
678+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
679 </ul>
680 </div>
681 <div class="footer">
682
683=== modified file 'doc/html/objects.inv'
684Binary files doc/html/objects.inv 2015-08-10 10:02:56 +0000 and doc/html/objects.inv 2015-10-27 17:36:50 +0000 differ
685=== modified file 'doc/html/other.html'
686--- doc/html/other.html 2015-08-10 10:02:56 +0000
687+++ doc/html/other.html 2015-10-27 17:36:50 +0000
688@@ -6,7 +6,7 @@
689 <head>
690 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
691
692- <title>Other sources of information &mdash; phpMyAdmin 4.4.13.1 documentation</title>
693+ <title>Other sources of information &mdash; phpMyAdmin 4.4.15.1 documentation</title>
694
695 <link rel="stylesheet" href="_static/default.css" type="text/css" />
696 <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
697@@ -14,7 +14,7 @@
698 <script type="text/javascript">
699 var DOCUMENTATION_OPTIONS = {
700 URL_ROOT: './',
701- VERSION: '4.4.13.1',
702+ VERSION: '4.4.15.1',
703 COLLAPSE_INDEX: false,
704 FILE_SUFFIX: '.html',
705 HAS_SOURCE: true
706@@ -24,7 +24,7 @@
707 <script type="text/javascript" src="_static/underscore.js"></script>
708 <script type="text/javascript" src="_static/doctools.js"></script>
709 <link rel="copyright" title="Copyright" href="copyright.html" />
710- <link rel="top" title="phpMyAdmin 4.4.13.1 documentation" href="index.html" />
711+ <link rel="top" title="phpMyAdmin 4.4.15.1 documentation" href="index.html" />
712 <link rel="up" title="User Guide" href="user.html" />
713 <link rel="next" title="Import and export" href="import_export.html" />
714 <link rel="prev" title="User management" href="privileges.html" />
715@@ -42,7 +42,7 @@
716 <li class="right" >
717 <a href="privileges.html" title="User management"
718 accesskey="P">previous</a> |</li>
719- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
720+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
721 <li><a href="user.html" accesskey="U">User Guide</a> &raquo;</li>
722 </ul>
723 </div>
724@@ -121,7 +121,7 @@
725 <li class="right" >
726 <a href="privileges.html" title="User management"
727 >previous</a> |</li>
728- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
729+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
730 <li><a href="user.html" >User Guide</a> &raquo;</li>
731 </ul>
732 </div>
733
734=== modified file 'doc/html/privileges.html'
735--- doc/html/privileges.html 2015-08-10 10:02:56 +0000
736+++ doc/html/privileges.html 2015-10-27 17:36:50 +0000
737@@ -6,7 +6,7 @@
738 <head>
739 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
740
741- <title>User management &mdash; phpMyAdmin 4.4.13.1 documentation</title>
742+ <title>User management &mdash; phpMyAdmin 4.4.15.1 documentation</title>
743
744 <link rel="stylesheet" href="_static/default.css" type="text/css" />
745 <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
746@@ -14,7 +14,7 @@
747 <script type="text/javascript">
748 var DOCUMENTATION_OPTIONS = {
749 URL_ROOT: './',
750- VERSION: '4.4.13.1',
751+ VERSION: '4.4.15.1',
752 COLLAPSE_INDEX: false,
753 FILE_SUFFIX: '.html',
754 HAS_SOURCE: true
755@@ -24,7 +24,7 @@
756 <script type="text/javascript" src="_static/underscore.js"></script>
757 <script type="text/javascript" src="_static/doctools.js"></script>
758 <link rel="copyright" title="Copyright" href="copyright.html" />
759- <link rel="top" title="phpMyAdmin 4.4.13.1 documentation" href="index.html" />
760+ <link rel="top" title="phpMyAdmin 4.4.15.1 documentation" href="index.html" />
761 <link rel="up" title="User Guide" href="user.html" />
762 <link rel="next" title="Other sources of information" href="other.html" />
763 <link rel="prev" title="Transformations" href="transformations.html" />
764@@ -42,7 +42,7 @@
765 <li class="right" >
766 <a href="transformations.html" title="Transformations"
767 accesskey="P">previous</a> |</li>
768- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
769+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
770 <li><a href="user.html" accesskey="U">User Guide</a> &raquo;</li>
771 </ul>
772 </div>
773@@ -155,7 +155,7 @@
774 <li class="right" >
775 <a href="transformations.html" title="Transformations"
776 >previous</a> |</li>
777- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
778+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
779 <li><a href="user.html" >User Guide</a> &raquo;</li>
780 </ul>
781 </div>
782
783=== modified file 'doc/html/require.html'
784--- doc/html/require.html 2015-08-10 10:02:56 +0000
785+++ doc/html/require.html 2015-10-27 17:36:50 +0000
786@@ -6,7 +6,7 @@
787 <head>
788 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
789
790- <title>Requirements &mdash; phpMyAdmin 4.4.13.1 documentation</title>
791+ <title>Requirements &mdash; phpMyAdmin 4.4.15.1 documentation</title>
792
793 <link rel="stylesheet" href="_static/default.css" type="text/css" />
794 <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
795@@ -14,7 +14,7 @@
796 <script type="text/javascript">
797 var DOCUMENTATION_OPTIONS = {
798 URL_ROOT: './',
799- VERSION: '4.4.13.1',
800+ VERSION: '4.4.15.1',
801 COLLAPSE_INDEX: false,
802 FILE_SUFFIX: '.html',
803 HAS_SOURCE: true
804@@ -24,7 +24,7 @@
805 <script type="text/javascript" src="_static/underscore.js"></script>
806 <script type="text/javascript" src="_static/doctools.js"></script>
807 <link rel="copyright" title="Copyright" href="copyright.html" />
808- <link rel="top" title="phpMyAdmin 4.4.13.1 documentation" href="index.html" />
809+ <link rel="top" title="phpMyAdmin 4.4.15.1 documentation" href="index.html" />
810 <link rel="next" title="Installation" href="setup.html" />
811 <link rel="prev" title="Introduction" href="intro.html" />
812 </head>
813@@ -41,7 +41,7 @@
814 <li class="right" >
815 <a href="intro.html" title="Introduction"
816 accesskey="P">previous</a> |</li>
817- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
818+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
819 </ul>
820 </div>
821
822@@ -60,7 +60,7 @@
823 <div class="section" id="php">
824 <h2>PHP<a class="headerlink" href="#php" title="Permalink to this headline">¶</a></h2>
825 <ul class="simple">
826-<li>You need PHP 5.3.0 or newer, with <tt class="docutils literal"><span class="pre">session</span></tt> support, the Standard PHP Library
827+<li>You need PHP 5.3.7 or newer, with <tt class="docutils literal"><span class="pre">session</span></tt> support, the Standard PHP Library
828 (SPL) extension, JSON support, and the <tt class="docutils literal"><span class="pre">mbstring</span></tt> extension.</li>
829 <li>To support uploading of ZIP files, you need the PHP <tt class="docutils literal"><span class="pre">zip</span></tt> extension.</li>
830 <li>You need GD2 support in PHP to display inline thumbnails of JPEGs
831@@ -155,7 +155,7 @@
832 <li class="right" >
833 <a href="intro.html" title="Introduction"
834 >previous</a> |</li>
835- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
836+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
837 </ul>
838 </div>
839 <div class="footer">
840
841=== modified file 'doc/html/search.html'
842--- doc/html/search.html 2015-08-10 10:02:56 +0000
843+++ doc/html/search.html 2015-10-27 17:36:50 +0000
844@@ -6,7 +6,7 @@
845 <head>
846 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
847
848- <title>Search &mdash; phpMyAdmin 4.4.13.1 documentation</title>
849+ <title>Search &mdash; phpMyAdmin 4.4.15.1 documentation</title>
850
851 <link rel="stylesheet" href="_static/default.css" type="text/css" />
852 <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
853@@ -14,7 +14,7 @@
854 <script type="text/javascript">
855 var DOCUMENTATION_OPTIONS = {
856 URL_ROOT: './',
857- VERSION: '4.4.13.1',
858+ VERSION: '4.4.15.1',
859 COLLAPSE_INDEX: false,
860 FILE_SUFFIX: '.html',
861 HAS_SOURCE: true
862@@ -25,7 +25,7 @@
863 <script type="text/javascript" src="_static/doctools.js"></script>
864 <script type="text/javascript" src="_static/searchtools.js"></script>
865 <link rel="copyright" title="Copyright" href="copyright.html" />
866- <link rel="top" title="phpMyAdmin 4.4.13.1 documentation" href="index.html" />
867+ <link rel="top" title="phpMyAdmin 4.4.15.1 documentation" href="index.html" />
868 <script type="text/javascript">
869 jQuery(function() { Search.loadIndex("searchindex.js"); });
870 </script>
871@@ -41,7 +41,7 @@
872 <li class="right" style="margin-right: 10px">
873 <a href="genindex.html" title="General Index"
874 accesskey="I">index</a></li>
875- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
876+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
877 </ul>
878 </div>
879
880@@ -89,7 +89,7 @@
881 <li class="right" style="margin-right: 10px">
882 <a href="genindex.html" title="General Index"
883 >index</a></li>
884- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
885+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
886 </ul>
887 </div>
888 <div class="footer">
889
890=== modified file 'doc/html/setup.html'
891--- doc/html/setup.html 2015-08-10 10:02:56 +0000
892+++ doc/html/setup.html 2015-10-27 17:36:50 +0000
893@@ -6,7 +6,7 @@
894 <head>
895 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
896
897- <title>Installation &mdash; phpMyAdmin 4.4.13.1 documentation</title>
898+ <title>Installation &mdash; phpMyAdmin 4.4.15.1 documentation</title>
899
900 <link rel="stylesheet" href="_static/default.css" type="text/css" />
901 <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
902@@ -14,7 +14,7 @@
903 <script type="text/javascript">
904 var DOCUMENTATION_OPTIONS = {
905 URL_ROOT: './',
906- VERSION: '4.4.13.1',
907+ VERSION: '4.4.15.1',
908 COLLAPSE_INDEX: false,
909 FILE_SUFFIX: '.html',
910 HAS_SOURCE: true
911@@ -24,7 +24,7 @@
912 <script type="text/javascript" src="_static/underscore.js"></script>
913 <script type="text/javascript" src="_static/doctools.js"></script>
914 <link rel="copyright" title="Copyright" href="copyright.html" />
915- <link rel="top" title="phpMyAdmin 4.4.13.1 documentation" href="index.html" />
916+ <link rel="top" title="phpMyAdmin 4.4.15.1 documentation" href="index.html" />
917 <link rel="next" title="Configuration" href="config.html" />
918 <link rel="prev" title="Requirements" href="require.html" />
919 </head>
920@@ -41,7 +41,7 @@
921 <li class="right" >
922 <a href="require.html" title="Requirements"
923 accesskey="P">previous</a> |</li>
924- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
925+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
926 </ul>
927 </div>
928
929@@ -896,7 +896,7 @@
930 <li class="right" >
931 <a href="require.html" title="Requirements"
932 >previous</a> |</li>
933- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
934+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
935 </ul>
936 </div>
937 <div class="footer">
938
939=== modified file 'doc/html/transformations.html'
940--- doc/html/transformations.html 2015-08-10 10:02:56 +0000
941+++ doc/html/transformations.html 2015-10-27 17:36:50 +0000
942@@ -6,7 +6,7 @@
943 <head>
944 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
945
946- <title>Transformations &mdash; phpMyAdmin 4.4.13.1 documentation</title>
947+ <title>Transformations &mdash; phpMyAdmin 4.4.15.1 documentation</title>
948
949 <link rel="stylesheet" href="_static/default.css" type="text/css" />
950 <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
951@@ -14,7 +14,7 @@
952 <script type="text/javascript">
953 var DOCUMENTATION_OPTIONS = {
954 URL_ROOT: './',
955- VERSION: '4.4.13.1',
956+ VERSION: '4.4.15.1',
957 COLLAPSE_INDEX: false,
958 FILE_SUFFIX: '.html',
959 HAS_SOURCE: true
960@@ -24,7 +24,7 @@
961 <script type="text/javascript" src="_static/underscore.js"></script>
962 <script type="text/javascript" src="_static/doctools.js"></script>
963 <link rel="copyright" title="Copyright" href="copyright.html" />
964- <link rel="top" title="phpMyAdmin 4.4.13.1 documentation" href="index.html" />
965+ <link rel="top" title="phpMyAdmin 4.4.15.1 documentation" href="index.html" />
966 <link rel="up" title="User Guide" href="user.html" />
967 <link rel="next" title="User management" href="privileges.html" />
968 <link rel="prev" title="User Guide" href="user.html" />
969@@ -42,7 +42,7 @@
970 <li class="right" >
971 <a href="user.html" title="User Guide"
972 accesskey="P">previous</a> |</li>
973- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
974+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
975 <li><a href="user.html" accesskey="U">User Guide</a> &raquo;</li>
976 </ul>
977 </div>
978@@ -226,7 +226,7 @@
979 <li class="right" >
980 <a href="user.html" title="User Guide"
981 >previous</a> |</li>
982- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
983+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
984 <li><a href="user.html" >User Guide</a> &raquo;</li>
985 </ul>
986 </div>
987
988=== modified file 'doc/html/user.html'
989--- doc/html/user.html 2015-08-10 10:02:56 +0000
990+++ doc/html/user.html 2015-10-27 17:36:50 +0000
991@@ -6,7 +6,7 @@
992 <head>
993 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
994
995- <title>User Guide &mdash; phpMyAdmin 4.4.13.1 documentation</title>
996+ <title>User Guide &mdash; phpMyAdmin 4.4.15.1 documentation</title>
997
998 <link rel="stylesheet" href="_static/default.css" type="text/css" />
999 <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
1000@@ -14,7 +14,7 @@
1001 <script type="text/javascript">
1002 var DOCUMENTATION_OPTIONS = {
1003 URL_ROOT: './',
1004- VERSION: '4.4.13.1',
1005+ VERSION: '4.4.15.1',
1006 COLLAPSE_INDEX: false,
1007 FILE_SUFFIX: '.html',
1008 HAS_SOURCE: true
1009@@ -24,7 +24,7 @@
1010 <script type="text/javascript" src="_static/underscore.js"></script>
1011 <script type="text/javascript" src="_static/doctools.js"></script>
1012 <link rel="copyright" title="Copyright" href="copyright.html" />
1013- <link rel="top" title="phpMyAdmin 4.4.13.1 documentation" href="index.html" />
1014+ <link rel="top" title="phpMyAdmin 4.4.15.1 documentation" href="index.html" />
1015 <link rel="next" title="Transformations" href="transformations.html" />
1016 <link rel="prev" title="Configuration" href="config.html" />
1017 </head>
1018@@ -41,7 +41,7 @@
1019 <li class="right" >
1020 <a href="config.html" title="Configuration"
1021 accesskey="P">previous</a> |</li>
1022- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
1023+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
1024 </ul>
1025 </div>
1026
1027@@ -126,7 +126,7 @@
1028 <li class="right" >
1029 <a href="config.html" title="Configuration"
1030 >previous</a> |</li>
1031- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
1032+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
1033 </ul>
1034 </div>
1035 <div class="footer">
1036
1037=== modified file 'doc/html/vendors.html'
1038--- doc/html/vendors.html 2015-08-10 10:02:56 +0000
1039+++ doc/html/vendors.html 2015-10-27 17:36:50 +0000
1040@@ -6,7 +6,7 @@
1041 <head>
1042 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
1043
1044- <title>Distributing and packaging phpMyAdmin &mdash; phpMyAdmin 4.4.13.1 documentation</title>
1045+ <title>Distributing and packaging phpMyAdmin &mdash; phpMyAdmin 4.4.15.1 documentation</title>
1046
1047 <link rel="stylesheet" href="_static/default.css" type="text/css" />
1048 <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
1049@@ -14,7 +14,7 @@
1050 <script type="text/javascript">
1051 var DOCUMENTATION_OPTIONS = {
1052 URL_ROOT: './',
1053- VERSION: '4.4.13.1',
1054+ VERSION: '4.4.15.1',
1055 COLLAPSE_INDEX: false,
1056 FILE_SUFFIX: '.html',
1057 HAS_SOURCE: true
1058@@ -24,7 +24,7 @@
1059 <script type="text/javascript" src="_static/underscore.js"></script>
1060 <script type="text/javascript" src="_static/doctools.js"></script>
1061 <link rel="copyright" title="Copyright" href="copyright.html" />
1062- <link rel="top" title="phpMyAdmin 4.4.13.1 documentation" href="index.html" />
1063+ <link rel="top" title="phpMyAdmin 4.4.15.1 documentation" href="index.html" />
1064 <link rel="next" title="Copyright" href="copyright.html" />
1065 <link rel="prev" title="Developers Information" href="developers.html" />
1066 </head>
1067@@ -41,7 +41,7 @@
1068 <li class="right" >
1069 <a href="developers.html" title="Developers Information"
1070 accesskey="P">previous</a> |</li>
1071- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
1072+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
1073 </ul>
1074 </div>
1075
1076@@ -136,7 +136,7 @@
1077 <li class="right" >
1078 <a href="developers.html" title="Developers Information"
1079 >previous</a> |</li>
1080- <li><a href="index.html">phpMyAdmin 4.4.13.1 documentation</a> &raquo;</li>
1081+ <li><a href="index.html">phpMyAdmin 4.4.15.1 documentation</a> &raquo;</li>
1082 </ul>
1083 </div>
1084 <div class="footer">
1085
1086=== modified file 'doc/require.rst'
1087--- doc/require.rst 2015-05-28 15:02:54 +0000
1088+++ doc/require.rst 2015-10-27 17:36:50 +0000
1089@@ -12,7 +12,7 @@
1090 PHP
1091 ---
1092
1093-* You need PHP 5.3.0 or newer, with ``session`` support, the Standard PHP Library
1094+* You need PHP 5.3.7 or newer, with ``session`` support, the Standard PHP Library
1095 (SPL) extension, JSON support, and the ``mbstring`` extension.
1096
1097 * To support uploading of ZIP files, you need the PHP ``zip`` extension.
1098
1099=== modified file 'import.php'
1100--- import.php 2015-04-28 10:31:57 +0000
1101+++ import.php 2015-10-27 17:36:50 +0000
1102@@ -644,7 +644,7 @@
1103 if ($import_notice) {
1104 $message->addString($import_notice);
1105 }
1106- if (isset($local_import_file)) {
1107+ if (! empty($local_import_file)) {
1108 $message->addString('(' . htmlspecialchars($local_import_file) . ')');
1109 } else {
1110 $message->addString(
1111
1112=== modified file 'js/functions.js'
1113--- js/functions.js 2015-08-10 10:02:56 +0000
1114+++ js/functions.js 2015-10-27 17:36:50 +0000
1115@@ -144,6 +144,7 @@
1116 function escapeHtml(unsafe) {
1117 if (typeof(unsafe) != 'undefined') {
1118 return unsafe
1119+ .toString()
1120 .replace(/&/g, "&amp;")
1121 .replace(/</g, "&lt;")
1122 .replace(/>/g, "&gt;")
1123@@ -3811,7 +3812,7 @@
1124 * Load version information asynchronously.
1125 */
1126 if ($('li.jsversioncheck').length > 0) {
1127- $.getJSON('version_check.php', {}, PMA_current_version);
1128+ $.getJSON('version_check.php', {'server' : PMA_commonParams.get('server')}, PMA_current_version);
1129 }
1130
1131 if ($('#is_git_revision').length > 0) {
1132
1133=== modified file 'js/line_counts.php'
1134--- js/line_counts.php 2015-08-10 10:02:56 +0000
1135+++ js/line_counts.php 2015-10-27 17:36:50 +0000
1136@@ -27,10 +27,7 @@
1137 $LINE_COUNT["cross_framing_protection.js"] = 10;
1138 $LINE_COUNT["db_operations.js"] = 157;
1139 $LINE_COUNT["db_search.js"] = 239;
1140-$LINE_COUNT["db_tracking.js"] = 84;
1141 $LINE_COUNT["doclinks.js"] = 365;
1142-$LINE_COUNT["gis_data_editor.js"] = 396;
1143-$LINE_COUNT["import.js"] = 167;
1144 $LINE_COUNT["jqplot/excanvas.js"] = 1438;
1145 $LINE_COUNT["jqplot/jquery.jqplot.js"] = 11411;
1146 $LINE_COUNT["jqplot/plugins/jqplot.barRenderer.js"] = 800;
1147@@ -473,13 +470,9 @@
1148 $LINE_COUNT["pmd/history.js"] = 813;
1149 $LINE_COUNT["pmd/iecanvas.js"] = 147;
1150 $LINE_COUNT["pmd/init.js"] = 40;
1151-$LINE_COUNT["pmd/move.js"] = 2003;
1152-$LINE_COUNT["server_status_advisor.js"] = 93;
1153-$LINE_COUNT["server_status_processes.js"] = 189;
1154+$LINE_COUNT["pmd/move.js"] = 2004;
1155 $LINE_COUNT["server_status_queries.js"] = 34;
1156-$LINE_COUNT["server_status_variables.js"] = 103;
1157 $LINE_COUNT["server_user_groups.js"] = 42;
1158-$LINE_COUNT["server_variables.js"] = 147;
1159 $LINE_COUNT["sprintf.js"] = 211;
1160 $LINE_COUNT["tbl_find_replace.js"] = 47;
1161 $LINE_COUNT["tracekit/tracekit.js"] = 1114;
1162@@ -496,9 +489,12 @@
1163 $LINE_COUNT["db_central_columns.js"] = 201;
1164 $LINE_COUNT["db_qbe.js"] = 64;
1165 $LINE_COUNT["db_structure.js"] = 391;
1166+$LINE_COUNT["db_tracking.js"] = 84;
1167 $LINE_COUNT["error_report.js"] = 340;
1168 $LINE_COUNT["export.js"] = 401;
1169-$LINE_COUNT["functions.js"] = 4571;
1170+$LINE_COUNT["functions.js"] = 4572;
1171+$LINE_COUNT["gis_data_editor.js"] = 396;
1172+$LINE_COUNT["import.js"] = 167;
1173 $LINE_COUNT["indexes.js"] = 697;
1174 $LINE_COUNT["makegrid.js"] = 1962;
1175 $LINE_COUNT["menu-resizer.js"] = 182;
1176@@ -509,13 +505,17 @@
1177 $LINE_COUNT["server_databases.js"] = 137;
1178 $LINE_COUNT["server_plugins.js"] = 30;
1179 $LINE_COUNT["server_privileges.js"] = 451;
1180+$LINE_COUNT["server_status_advisor.js"] = 93;
1181 $LINE_COUNT["server_status_monitor.js"] = 2172;
1182+$LINE_COUNT["server_status_processes.js"] = 189;
1183 $LINE_COUNT["server_status_sorter.js"] = 89;
1184+$LINE_COUNT["server_status_variables.js"] = 103;
1185+$LINE_COUNT["server_variables.js"] = 147;
1186 $LINE_COUNT["sql.js"] = 843;
1187 $LINE_COUNT["tbl_change.js"] = 754;
1188 $LINE_COUNT["tbl_chart.js"] = 429;
1189 $LINE_COUNT["tbl_gis_visualization.js"] = 353;
1190-$LINE_COUNT["tbl_operations.js"] = 240;
1191+$LINE_COUNT["tbl_operations.js"] = 243;
1192 $LINE_COUNT["tbl_relation.js"] = 234;
1193 $LINE_COUNT["tbl_select.js"] = 395;
1194 $LINE_COUNT["tbl_structure.js"] = 397;
1195
1196=== modified file 'js/pmd/move.js'
1197--- js/pmd/move.js 2015-07-02 09:19:22 +0000
1198+++ js/pmd/move.js 2015-10-27 17:36:50 +0000
1199@@ -676,6 +676,7 @@
1200 };
1201
1202 var $form = $('<form action="db_designer.php" method="post" name="save_page" id="save_page" class="ajax"></form>')
1203+ .append('<input type="hidden" name="server" value="' + server + '" />')
1204 .append('<input type="hidden" name="db" value="' + db + '" />')
1205 .append('<input type="hidden" name="token" value="' + token + '" />')
1206 .append('<input type="hidden" name="operation" value="savePage" />')
1207@@ -718,7 +719,7 @@
1208 };
1209
1210 var $msgbox = PMA_ajaxShowMessage();
1211- var params = 'ajax_request=true&dialog=edit&token=' + token + '&db=' + db;
1212+ var params = 'ajax_request=true&dialog=edit&server=' + server + '&token=' + token + '&db=' + db;
1213 $.get("db_designer.php", params, function (data) {
1214 if (data.success === false) {
1215 PMA_ajaxShowMessage(data.error, false);
1216@@ -798,7 +799,7 @@
1217 };
1218
1219 var $msgbox = PMA_ajaxShowMessage();
1220- var params = 'ajax_request=true&dialog=delete&token=' + token + '&db=' + db;
1221+ var params = 'ajax_request=true&dialog=delete&server=' + server + '&token=' + token + '&db=' + db;
1222 $.get("db_designer.php", params, function (data) {
1223 if (data.success === false) {
1224 PMA_ajaxShowMessage(data.error, false);
1225@@ -897,7 +898,7 @@
1226 };
1227
1228 var $msgbox = PMA_ajaxShowMessage();
1229- var params = 'ajax_request=true&dialog=save_as&token=' + token + '&db=' + db;
1230+ var params = 'ajax_request=true&dialog=save_as&server=' + server + '&token=' + token + '&db=' + db;
1231 $.get("db_designer.php", params, function (data) {
1232 if (data.success === false) {
1233 PMA_ajaxShowMessage(data.error, false);
1234@@ -974,7 +975,7 @@
1235 $(this).dialog('close');
1236 };
1237 var $msgbox = PMA_ajaxShowMessage();
1238- var params = 'ajax_request=true&dialog=export&token=' + token + '&db=' + db + '&selected_page=' + selected_page;
1239+ var params = 'ajax_request=true&dialog=export&server=' + server + '&token=' + token + '&db=' + db + '&selected_page=' + selected_page;
1240 $.get("db_designer.php", params, function (data) {
1241 if (data.success === false) {
1242 PMA_ajaxShowMessage(data.error, false);
1243@@ -1015,7 +1016,7 @@
1244 if (page !== null) {
1245 param_page = '&page=' + page;
1246 }
1247- $('<a href="db_designer.php?db=' + db + '&token=' + token + param_page + '"></a>')
1248+ $('<a href="db_designer.php?server=' + server + '&db=' + db + '&token=' + token + param_page + '"></a>')
1249 .appendTo($('#page_content'))
1250 .click();
1251 } else {
1252
1253=== modified file 'js/tbl_operations.js'
1254--- js/tbl_operations.js 2015-04-28 10:31:57 +0000
1255+++ js/tbl_operations.js 2015-10-27 17:36:50 +0000
1256@@ -26,7 +26,10 @@
1257 $.post($form.attr('action'), $form.serialize() + "&submit_copy=Go", function (data) {
1258 if (typeof data !== 'undefined' && data.success === true) {
1259 if ($form.find("input[name='switch_to_new']").prop('checked')) {
1260- PMA_commonParams.set('db', data.db);
1261+ PMA_commonParams.set(
1262+ 'db',
1263+ $form.find("select[name='target_db']").val()
1264+ );
1265 PMA_commonParams.set(
1266 'table',
1267 $form.find("input[name='new_name']").val()
1268
1269=== modified file 'libraries/Config.class.php'
1270--- libraries/Config.class.php 2015-08-10 10:02:56 +0000
1271+++ libraries/Config.class.php 2015-10-27 17:36:50 +0000
1272@@ -114,7 +114,7 @@
1273 */
1274 function checkSystem()
1275 {
1276- $this->set('PMA_VERSION', '4.4.13.1');
1277+ $this->set('PMA_VERSION', '4.4.15.1');
1278 /**
1279 * @deprecated
1280 */
1281
1282=== modified file 'libraries/DatabaseInterface.class.php'
1283--- libraries/DatabaseInterface.class.php 2015-04-28 10:31:57 +0000
1284+++ libraries/DatabaseInterface.class.php 2015-10-27 17:36:50 +0000
1285@@ -228,42 +228,43 @@
1286 public function convertMessage($message)
1287 {
1288 // latin always last!
1289+ // @todo some values are missing,
1290+ // see https://mariadb.com/kb/en/mariadb/server-locale/
1291+
1292 $encodings = array(
1293- 'japanese' => 'EUC-JP', //'ujis',
1294- 'japanese-sjis' => 'Shift-JIS', //'sjis',
1295- 'korean' => 'EUC-KR', //'euckr',
1296- 'russian' => 'KOI8-R', //'koi8r',
1297- 'ukrainian' => 'KOI8-U', //'koi8u',
1298- 'greek' => 'ISO-8859-7', //'greek',
1299- 'serbian' => 'CP1250', //'cp1250',
1300- 'estonian' => 'ISO-8859-13', //'latin7',
1301- 'slovak' => 'ISO-8859-2', //'latin2',
1302- 'czech' => 'ISO-8859-2', //'latin2',
1303- 'hungarian' => 'ISO-8859-2', //'latin2',
1304- 'polish' => 'ISO-8859-2', //'latin2',
1305- 'romanian' => 'ISO-8859-2', //'latin2',
1306- 'spanish' => 'CP1252', //'latin1',
1307- 'swedish' => 'CP1252', //'latin1',
1308- 'italian' => 'CP1252', //'latin1',
1309- 'norwegian-ny' => 'CP1252', //'latin1',
1310- 'norwegian' => 'CP1252', //'latin1',
1311- 'portuguese' => 'CP1252', //'latin1',
1312- 'danish' => 'CP1252', //'latin1',
1313- 'dutch' => 'CP1252', //'latin1',
1314- 'english' => 'CP1252', //'latin1',
1315- 'french' => 'CP1252', //'latin1',
1316- 'german' => 'CP1252', //'latin1',
1317+ 'ja' => 'EUC-JP', //'ujis',
1318+ 'ko' => 'EUC-KR', //'euckr',
1319+ 'ru' => 'KOI8-R', //'koi8r',
1320+ 'uk' => 'KOI8-U', //'koi8u',
1321+ 'sr' => 'CP1250', //'cp1250',
1322+ 'et' => 'ISO-8859-13', //'latin7',
1323+ 'sk' => 'ISO-8859-2', //'latin2',
1324+ 'cz' => 'ISO-8859-2', //'latin2',
1325+ 'hu' => 'ISO-8859-2', //'latin2',
1326+ 'pl' => 'ISO-8859-2', //'latin2',
1327+ 'ro' => 'ISO-8859-2', //'latin2',
1328+ 'es' => 'CP1252', //'latin1',
1329+ 'sv' => 'CP1252', //'latin1',
1330+ 'it' => 'CP1252', //'latin1',
1331+ 'no' => 'CP1252', //'latin1',
1332+ 'pt' => 'CP1252', //'latin1',
1333+ 'da' => 'CP1252', //'latin1',
1334+ 'nl' => 'CP1252', //'latin1',
1335+ 'en' => 'CP1252', //'latin1',
1336+ 'fr' => 'CP1252', //'latin1',
1337+ 'de' => 'CP1252', //'latin1',
1338 );
1339
1340 $server_language = $this->fetchValue(
1341- 'SHOW VARIABLES LIKE \'language\';',
1342+ 'SELECT @@lc_messages;',
1343 0,
1344- 1
1345+ 0
1346 );
1347+
1348 if ($server_language) {
1349 $found = array();
1350 $match = preg_match(
1351- '&(?:\\\|\\/)([^\\\\\/]*)(?:\\\|\\/)$&i',
1352+ '&([a-z][a-z])_&i',
1353 $server_language,
1354 $found
1355 );
1356@@ -321,7 +322,8 @@
1357 )
1358 . '%\'';
1359 } else {
1360- $sql_where_table = 'AND t.`TABLE_NAME` = \''
1361+ $sql_where_table = 'AND t.`TABLE_NAME` '
1362+ . PMA_Util::getCollateForIS() . ' = \''
1363 . PMA_Util::sqlAddSlashes($table) . '\'';
1364 }
1365 } else {
1366@@ -423,7 +425,7 @@
1367 `CREATE_OPTIONS` AS `Create_options`,
1368 `TABLE_COMMENT` AS `Comment`
1369 FROM `information_schema`.`TABLES` t
1370- WHERE ' . (PMA_IS_WINDOWS ? '' : 'BINARY') . ' `TABLE_SCHEMA`
1371+ WHERE `TABLE_SCHEMA` ' . PMA_Util::getCollateForIS() . '
1372 IN (\'' . implode("', '", $this_databases) . '\')
1373 ' . $sql_where_table;
1374 }
1375@@ -1410,8 +1412,8 @@
1376 * @param boolean $full whether to return full info or only column names
1377 * @param mixed $link mysql link resource
1378 *
1379- * @return false|array array indexed by column names or,
1380- * if $column is given, flat array description
1381+ * @return array array indexed by column names or,
1382+ * if $column is given, flat array description
1383 */
1384 public function getColumns($database, $table, $column = null, $full = false,
1385 $link = null
1386@@ -1419,7 +1421,7 @@
1387 $sql = $this->getColumnsSql($database, $table, $column, $full);
1388 $fields = $this->fetchResult($sql, 'Field', null, $link);
1389 if (! is_array($fields) || count($fields) == 0) {
1390- return null;
1391+ return array();
1392 }
1393 // Check if column is a part of multiple-column index and set its 'Key'.
1394 $indexes = PMA_Index::getFromTable($table, $database);
1395
1396=== modified file 'libraries/DisplayResults.class.php'
1397--- libraries/DisplayResults.class.php 2015-07-23 07:54:31 +0000
1398+++ libraries/DisplayResults.class.php 2015-10-27 17:36:50 +0000
1399@@ -3025,7 +3025,9 @@
1400
1401 $vertical_display = $this->__get('vertical_display');
1402
1403- if ($meta->numeric == 1) {
1404+ // in some situations (issue 11406), numeric returns 1
1405+ // even for a string type
1406+ if ($meta->numeric == 1 && $meta->type != 'string') {
1407 // n u m e r i c
1408
1409 $vertical_display['data'][$row_no][$i]
1410
1411=== modified file 'libraries/Scripts.class.php'
1412--- libraries/Scripts.class.php 2015-04-28 10:31:57 +0000
1413+++ libraries/Scripts.class.php 2015-10-27 17:36:50 +0000
1414@@ -82,12 +82,17 @@
1415 }
1416 }
1417 $separator = PMA_URL_getArgSeparator();
1418- $url = 'js/get_scripts.js.php?' . implode($separator, $scripts);
1419+ $static_scripts = '';
1420+ // Using chunks of 20 files to avoid too long URLs
1421+ $script_chunks = array_chunk($scripts, 20);
1422+ foreach ($script_chunks as $script_chunk) {
1423+ $url = 'js/get_scripts.js.php?' . implode($separator, $script_chunk);
1424
1425- $static_scripts = sprintf(
1426- '<script data-cfasync="false" type="text/javascript" src="%s"></script>',
1427- htmlspecialchars($url)
1428- );
1429+ $static_scripts .= sprintf(
1430+ '<script data-cfasync="false" type="text/javascript" src="%s"></script>',
1431+ htmlspecialchars($url)
1432+ );
1433+ }
1434 return $first_dynamic_scripts . $static_scripts . $dynamic_scripts;
1435 }
1436
1437
1438=== modified file 'libraries/Util.class.php'
1439--- libraries/Util.class.php 2015-07-07 10:25:56 +0000
1440+++ libraries/Util.class.php 2015-10-27 17:36:50 +0000
1441@@ -4234,7 +4234,7 @@
1442 *
1443 * @return resource curl_handle with updated options
1444 */
1445- public static function configureCurl(resource $curl_handle)
1446+ public static function configureCurl($curl_handle)
1447 {
1448 if (/*overload*/mb_strlen($GLOBALS['cfg']['ProxyUrl'])) {
1449 curl_setopt($curl_handle, CURLOPT_PROXY, $GLOBALS['cfg']['ProxyUrl']);
1450@@ -4249,157 +4249,6 @@
1451 curl_setopt($curl_handle, CURLOPT_USERAGENT, 'phpMyAdmin/' . PMA_VERSION);
1452 return $curl_handle;
1453 }
1454- /**
1455- * Returns information with latest version from phpmyadmin.net
1456- *
1457- * @return object JSON decoded object with the data
1458- */
1459- public static function getLatestVersion()
1460- {
1461- // wait 3s at most for server response, it's enough to get information
1462- // from a working server
1463- $connection_timeout = 3;
1464-
1465- $response = '{}';
1466- // Get response text from phpmyadmin.net or from the session
1467- // Update cache every 6 hours
1468- if (isset($_SESSION['cache']['version_check'])
1469- && time() < $_SESSION['cache']['version_check']['timestamp'] + 3600 * 6
1470- ) {
1471- $save = false;
1472- $response = $_SESSION['cache']['version_check']['response'];
1473- } else {
1474- $save = true;
1475- $file = 'https://www.phpmyadmin.net/home_page/version.json';
1476- if (ini_get('allow_url_fopen')) {
1477- $context = array(
1478- 'http' => array(
1479- 'request_fulluri' => true,
1480- 'timeout' => $connection_timeout,
1481- )
1482- );
1483- $context = PMA_Util::handleContext($context);
1484- if (! defined('TESTSUITE')) {
1485- session_write_close();
1486- }
1487- $response = file_get_contents(
1488- $file,
1489- false,
1490- stream_context_create($context)
1491- );
1492- } else if (function_exists('curl_init')) {
1493- $curl_handle = curl_init($file);
1494- if ($curl_handle === false) {
1495- return null;
1496- }
1497- $curl_handle = PMA_Util::configureCurl($curl_handle);
1498- curl_setopt(
1499- $curl_handle,
1500- CURLOPT_HEADER,
1501- false
1502- );
1503- curl_setopt(
1504- $curl_handle,
1505- CURLOPT_RETURNTRANSFER,
1506- true
1507- );
1508- curl_setopt(
1509- $curl_handle,
1510- CURLOPT_TIMEOUT,
1511- $connection_timeout
1512- );
1513- if (! defined('TESTSUITE')) {
1514- session_write_close();
1515- }
1516- $response = curl_exec($curl_handle);
1517- }
1518- }
1519-
1520- $data = json_decode($response);
1521- if (is_object($data)
1522- && ! empty($data->version)
1523- && ! empty($data->date)
1524- && $save
1525- ) {
1526- if (! isset($_SESSION) && ! defined('TESTSUITE')) {
1527- ini_set('session.use_only_cookies', 'false');
1528- ini_set('session.use_cookies', 'false');
1529- ini_set('session.use_trans_sid', 'false');
1530- ini_set('session.cache_limiter', 'nocache');
1531- session_start();
1532- }
1533- $_SESSION['cache']['version_check'] = array(
1534- 'response' => $response,
1535- 'timestamp' => time()
1536- );
1537- }
1538- return $data;
1539- }
1540-
1541- /**
1542- * Calculates numerical equivalent of phpMyAdmin version string
1543- *
1544- * @param string $version version
1545- *
1546- * @return mixed false on failure, integer on success
1547- */
1548- public static function versionToInt($version)
1549- {
1550- $parts = explode('-', $version);
1551- if (count($parts) > 1) {
1552- $suffix = $parts[1];
1553- } else {
1554- $suffix = '';
1555- }
1556- $parts = explode('.', $parts[0]);
1557-
1558- $result = 0;
1559-
1560- if (count($parts) >= 1 && is_numeric($parts[0])) {
1561- $result += 1000000 * $parts[0];
1562- }
1563-
1564- if (count($parts) >= 2 && is_numeric($parts[1])) {
1565- $result += 10000 * $parts[1];
1566- }
1567-
1568- if (count($parts) >= 3 && is_numeric($parts[2])) {
1569- $result += 100 * $parts[2];
1570- }
1571-
1572- if (count($parts) >= 4 && is_numeric($parts[3])) {
1573- $result += 1 * $parts[3];
1574- }
1575-
1576- if (!empty($suffix)) {
1577- $matches = array();
1578- if (preg_match('/^(\D+)(\d+)$/', $suffix, $matches)) {
1579- $suffix = $matches[1];
1580- $result += intval($matches[2]);
1581- }
1582- switch ($suffix) {
1583- case 'pl':
1584- $result += 60;
1585- break;
1586- case 'rc':
1587- $result += 30;
1588- break;
1589- case 'beta':
1590- $result += 20;
1591- break;
1592- case 'alpha':
1593- $result += 10;
1594- break;
1595- case 'dev':
1596- $result += 0;
1597- break;
1598- }
1599- } else {
1600- $result += 50; // for final
1601- }
1602-
1603- return $result;
1604- }
1605
1606 /**
1607 * Add fractional seconds to time, datetime and timestamp strings.
1608@@ -4517,7 +4366,9 @@
1609 "SHOW VARIABLES LIKE 'lower_case_table_names'", 0, 1
1610 );
1611
1612- if ($lowerCaseTableNames === '0') {
1613+ if ($lowerCaseTableNames === '0' // issue #10961
1614+ || $lowerCaseTableNames === '2' // issue #11461
1615+ ) {
1616 return "COLLATE utf8_bin";
1617 }
1618 return "";
1619
1620=== added file 'libraries/VersionInformation.php'
1621--- libraries/VersionInformation.php 1970-01-01 00:00:00 +0000
1622+++ libraries/VersionInformation.php 2015-10-27 17:36:50 +0000
1623@@ -0,0 +1,270 @@
1624+<?php
1625+/* vim: set expandtab sw=4 ts=4 sts=4: */
1626+/**
1627+ * Responsile for retrieving version information and notifiying about latest version
1628+ *
1629+ * @package PhpMyAdmin
1630+ */
1631+if (! defined('PHPMYADMIN')) {
1632+ exit;
1633+}
1634+
1635+/**
1636+ * Responsile for retrieving version information and notifiying about latest version
1637+ *
1638+ * @package PhpMyAdmin
1639+ *
1640+ */
1641+class VersionInformation
1642+{
1643+ /**
1644+ * Returns information with latest version from phpmyadmin.net
1645+ *
1646+ * @return object JSON decoded object with the data
1647+ */
1648+ public function getLatestVersion()
1649+ {
1650+ if (!$GLOBALS['cfg']['VersionCheck']) {
1651+ return new stdClass();
1652+ }
1653+
1654+ // wait 3s at most for server response, it's enough to get information
1655+ // from a working server
1656+ $connection_timeout = 3;
1657+
1658+ $response = '{}';
1659+ // Get response text from phpmyadmin.net or from the session
1660+ // Update cache every 6 hours
1661+ if (isset($_SESSION['cache']['version_check'])
1662+ && time() < $_SESSION['cache']['version_check']['timestamp'] + 3600 * 6
1663+ ) {
1664+ $save = false;
1665+ $response = $_SESSION['cache']['version_check']['response'];
1666+ } else {
1667+ $save = true;
1668+ $file = 'https://www.phpmyadmin.net/home_page/version.json';
1669+ if (ini_get('allow_url_fopen')) {
1670+ $context = array(
1671+ 'http' => array(
1672+ 'request_fulluri' => true,
1673+ 'timeout' => $connection_timeout,
1674+ )
1675+ );
1676+ $context = PMA_Util::handleContext($context);
1677+ if (! defined('TESTSUITE')) {
1678+ session_write_close();
1679+ }
1680+ $response = file_get_contents(
1681+ $file,
1682+ false,
1683+ stream_context_create($context)
1684+ );
1685+ } else if (function_exists('curl_init')) {
1686+ $curl_handle = curl_init($file);
1687+ if ($curl_handle === false) {
1688+ return null;
1689+ }
1690+ $curl_handle = PMA_Util::configureCurl($curl_handle);
1691+ curl_setopt(
1692+ $curl_handle,
1693+ CURLOPT_HEADER,
1694+ false
1695+ );
1696+ curl_setopt(
1697+ $curl_handle,
1698+ CURLOPT_RETURNTRANSFER,
1699+ true
1700+ );
1701+ curl_setopt(
1702+ $curl_handle,
1703+ CURLOPT_TIMEOUT,
1704+ $connection_timeout
1705+ );
1706+ if (! defined('TESTSUITE')) {
1707+ session_write_close();
1708+ }
1709+ $response = curl_exec($curl_handle);
1710+ }
1711+ }
1712+
1713+ $data = json_decode($response);
1714+ if (is_object($data)
1715+ && ! empty($data->version)
1716+ && ! empty($data->date)
1717+ && $save
1718+ ) {
1719+ if (! isset($_SESSION) && ! defined('TESTSUITE')) {
1720+ ini_set('session.use_only_cookies', 'false');
1721+ ini_set('session.use_cookies', 'false');
1722+ ini_set('session.use_trans_sid', 'false');
1723+ ini_set('session.cache_limiter', 'nocache');
1724+ session_start();
1725+ }
1726+ $_SESSION['cache']['version_check'] = array(
1727+ 'response' => $response,
1728+ 'timestamp' => time()
1729+ );
1730+ }
1731+ return $data;
1732+ }
1733+
1734+ /**
1735+ * Calculates numerical equivalent of phpMyAdmin version string
1736+ *
1737+ * @param string $version version
1738+ *
1739+ * @return mixed false on failure, integer on success
1740+ */
1741+ public function versionToInt($version)
1742+ {
1743+ $parts = explode('-', $version);
1744+ if (count($parts) > 1) {
1745+ $suffix = $parts[1];
1746+ } else {
1747+ $suffix = '';
1748+ }
1749+ $parts = explode('.', $parts[0]);
1750+
1751+ $result = 0;
1752+
1753+ if (count($parts) >= 1 && is_numeric($parts[0])) {
1754+ $result += 1000000 * $parts[0];
1755+ }
1756+
1757+ if (count($parts) >= 2 && is_numeric($parts[1])) {
1758+ $result += 10000 * $parts[1];
1759+ }
1760+
1761+ if (count($parts) >= 3 && is_numeric($parts[2])) {
1762+ $result += 100 * $parts[2];
1763+ }
1764+
1765+ if (count($parts) >= 4 && is_numeric($parts[3])) {
1766+ $result += 1 * $parts[3];
1767+ }
1768+
1769+ if (!empty($suffix)) {
1770+ $matches = array();
1771+ if (preg_match('/^(\D+)(\d+)$/', $suffix, $matches)) {
1772+ $suffix = $matches[1];
1773+ $result += intval($matches[2]);
1774+ }
1775+ switch ($suffix) {
1776+ case 'pl':
1777+ $result += 60;
1778+ break;
1779+ case 'rc':
1780+ $result += 30;
1781+ break;
1782+ case 'beta':
1783+ $result += 20;
1784+ break;
1785+ case 'alpha':
1786+ $result += 10;
1787+ break;
1788+ case 'dev':
1789+ $result += 0;
1790+ break;
1791+ }
1792+ } else {
1793+ $result += 50; // for final
1794+ }
1795+
1796+ return $result;
1797+ }
1798+
1799+ /**
1800+ * Returns the version and date of the latest phpMyAdmin version compatible
1801+ * with avilable PHP and MySQL versions
1802+ *
1803+ * @param array $releases array of information related to each version
1804+ *
1805+ * @return array containing the version and date of latest compatibel version
1806+ */
1807+ public function getLatestCompatibleVersion($releases)
1808+ {
1809+ foreach ($releases as $release) {
1810+ $phpVersions = $release->php_versions;
1811+ $phpConditions = explode(",", $phpVersions);
1812+ foreach ($phpConditions as $phpCondition) {
1813+ if (! $this->evaluateVersionCondition("PHP", $phpCondition)) {
1814+ continue 2;
1815+ }
1816+ }
1817+
1818+ // We evalute MySQL version constraint if there are only
1819+ // one server configured.
1820+ if (count($GLOBALS['cfg']['Servers']) == 1) {
1821+ $mysqlVersions = $release->mysql_versions;
1822+ $mysqlConditions = explode(",", $mysqlVersions);
1823+ foreach ($mysqlConditions as $mysqlCondition) {
1824+ if (! $this->evaluateVersionCondition('MySQL', $mysqlCondition)) {
1825+ continue 2;
1826+ }
1827+ }
1828+ }
1829+
1830+ return array(
1831+ 'version' => $release->version,
1832+ 'date' => $release->date,
1833+ );
1834+ }
1835+
1836+ // no compatible version
1837+ return null;
1838+ }
1839+
1840+ /**
1841+ * Checks whether PHP or MySQL version meets supplied version condition
1842+ *
1843+ * @param string $type PHP or MySQL
1844+ * @param string $condition version condition
1845+ *
1846+ * @return boolean whether the condition is met
1847+ */
1848+ public function evaluateVersionCondition($type, $condition)
1849+ {
1850+ $operator = null;
1851+ $operators = array("<=", ">=", "!=", "<>", "<", ">", "="); // preserve order
1852+ foreach ($operators as $oneOperator) {
1853+ if (strpos($condition, $oneOperator) === 0) {
1854+ $operator = $oneOperator;
1855+ $version = substr($condition, strlen($oneOperator));
1856+ break;
1857+ }
1858+ }
1859+
1860+ $myVersion = null;
1861+ if ($type == 'PHP') {
1862+ $myVersion = $this->getPHPVersion();
1863+ } elseif ($type == 'MySQL') {
1864+ $myVersion = $this->getMySQLVersion();
1865+ }
1866+
1867+ if ($myVersion != null && $operator != null) {
1868+ return version_compare($myVersion, $version, $operator);
1869+ }
1870+ return false;
1871+ }
1872+
1873+ /**
1874+ * Returns the PHP version
1875+ *
1876+ * @return string PHP version
1877+ */
1878+ protected function getPHPVersion()
1879+ {
1880+ return PHP_VERSION;
1881+ }
1882+
1883+ /**
1884+ * Returns the MySQL version
1885+ *
1886+ * @return string MySQL version
1887+ */
1888+ protected function getMySQLVersion()
1889+ {
1890+ return PMA_Util::cacheGet('PMA_MYSQL_STR_VERSION');
1891+ }
1892+}
1893+?>
1894\ No newline at end of file
1895
1896=== modified file 'libraries/config/messages.inc.php'
1897--- libraries/config/messages.inc.php 2015-05-11 11:38:33 +0000
1898+++ libraries/config/messages.inc.php 2015-10-27 17:36:50 +0000
1899@@ -360,6 +360,7 @@
1900 $strConfigImport_sql_compatibility_name = __('SQL compatibility mode');
1901 $strConfigImport_sql_no_auto_value_on_zero_name
1902 = __('Do not use AUTO_INCREMENT for zero values');
1903+$strConfigImport_sql_read_as_multibytes_name = __('Read as multibytes');
1904 $strConfigImport_xls_col_names_name = __('Column names in first row');
1905 $strConfigImport_xlsx_col_names_name = __('Column names in first row');
1906 $strConfigInitialSlidersState_name = __('Initial state for sliders');
1907
1908=== modified file 'libraries/dbi/DBIDummy.class.php'
1909--- libraries/dbi/DBIDummy.class.php 2015-04-28 10:31:57 +0000
1910+++ libraries/dbi/DBIDummy.class.php 2015-10-27 17:36:50 +0000
1911@@ -26,6 +26,10 @@
1912 'result' => array(array('pma_test@localhost')),
1913 ),
1914 array(
1915+ 'query' => "SHOW VARIABLES LIKE 'lower_case_table_names'",
1916+ 'result' => array(array('lower_case_table_names', '1'))
1917+ ),
1918+ array(
1919 'query' => 'SELECT 1 FROM mysql.user LIMIT 1',
1920 'result' => array(array('1')),
1921 ),
1922@@ -122,7 +126,7 @@
1923 )
1924 ),
1925 array(
1926- 'query' => 'SHOW VARIABLES LIKE \'language\';',
1927+ 'query' => 'SELECT @@lc_messages;',
1928 'result' => array(),
1929 ),
1930 array(
1931@@ -258,7 +262,7 @@
1932 . ' `CHECKSUM` AS `Checksum`, `CREATE_OPTIONS` AS `Create_options`,'
1933 . ' `TABLE_COMMENT` AS `Comment`'
1934 . ' FROM `information_schema`.`TABLES` t'
1935- . ' WHERE BINARY `TABLE_SCHEMA` IN (\'pma_test\')'
1936+ . ' WHERE `TABLE_SCHEMA` IN (\'pma_test\')'
1937 . ' AND t.`TABLE_NAME` = \'table1\' ORDER BY Name ASC',
1938 'columns' => array(
1939 'TABLE_CATALOG', 'TABLE_SCHEMA', 'TABLE_NAME', 'TABLE_TYPE', 'ENGINE',
1940
1941=== modified file 'libraries/language_stats.inc.php'
1942--- libraries/language_stats.inc.php 2015-08-10 10:02:56 +0000
1943+++ libraries/language_stats.inc.php 2015-10-27 17:36:50 +0000
1944@@ -16,7 +16,7 @@
1945 'ckb' => 20,
1946 'cs' => 98,
1947 'cy' => 19,
1948- 'da' => 99,
1949+ 'da' => 100,
1950 'de' => 100,
1951 'el' => 100,
1952 'en_GB' => 88,
1953@@ -28,12 +28,12 @@
1954 'fi' => 63,
1955 'fr' => 100,
1956 'fy' => 21,
1957- 'gl' => 76,
1958+ 'gl' => 86,
1959 'he' => 18,
1960 'hi' => 41,
1961 'hr' => 32,
1962- 'hu' => 100,
1963- 'hy' => 49,
1964+ 'hu' => 99,
1965+ 'hy' => 66,
1966 'ia' => 69,
1967 'id' => 76,
1968 'it' => 100,
1969@@ -42,7 +42,7 @@
1970 'kk' => 10,
1971 'km' => 5,
1972 'kn' => 4,
1973- 'ko' => 81,
1974+ 'ko' => 82,
1975 'ksh' => 1,
1976 'ky' => 1,
1977 'li' => 1,
1978@@ -58,15 +58,15 @@
1979 'pa' => 2,
1980 'pl' => 86,
1981 'pt' => 59,
1982- 'pt_BR' => 100,
1983+ 'pt_BR' => 99,
1984 'ro' => 59,
1985 'ru' => 99,
1986 'si' => 65,
1987 'sk' => 85,
1988 'sl' => 100,
1989- 'sq' => 99,
1990+ 'sq' => 100,
1991 'sr' => 25,
1992- 'sr@latin' => 50,
1993+ 'sr@latin' => 49,
1994 'sv' => 88,
1995 'ta' => 38,
1996 'te' => 10,
1997@@ -81,7 +81,7 @@
1998 'uz@latin' => 35,
1999 'vi' => 2,
2000 'vls' => 3,
2001- 'zh_CN' => 80,
2002+ 'zh_CN' => 82,
2003 'zh_TW' => 99,
2004 );
2005 ?>
2006
2007=== modified file 'libraries/phpseclib/Crypt/AES.php'
2008--- libraries/phpseclib/Crypt/AES.php 2015-04-28 10:31:57 +0000
2009+++ libraries/phpseclib/Crypt/AES.php 2015-10-27 17:36:50 +0000
2010@@ -5,23 +5,27 @@
2011 *
2012 * Uses mcrypt, if available/possible, and an internal implementation, otherwise.
2013 *
2014- * PHP versions 4 and 5
2015- *
2016- * If {@link Crypt_AES::setKeyLength() setKeyLength()} isn't called, it'll be calculated from
2017- * {@link Crypt_AES::setKey() setKey()}. ie. if the key is 128-bits, the key length will be 128-bits. If it's 136-bits
2018- * it'll be null-padded to 192-bits and 192 bits will be the key length until {@link Crypt_AES::setKey() setKey()}
2019+ * PHP version 5
2020+ *
2021+ * NOTE: Since AES.php is (for compatibility and phpseclib-historical reasons) virtually
2022+ * just a wrapper to Rijndael.php you may consider using Rijndael.php instead of
2023+ * to save one include_once().
2024+ *
2025+ * If {@link \phpseclib\Crypt\AES::setKeyLength() setKeyLength()} isn't called, it'll be calculated from
2026+ * {@link \phpseclib\Crypt\AES::setKey() setKey()}. ie. if the key is 128-bits, the key length will be 128-bits. If it's 136-bits
2027+ * it'll be null-padded to 192-bits and 192 bits will be the key length until {@link \phpseclib\Crypt\AES::setKey() setKey()}
2028 * is called, again, at which point, it'll be recalculated.
2029 *
2030- * Since Crypt_AES extends Crypt_Rijndael, some functions are available to be called that, in the context of AES, don't
2031- * make a whole lot of sense. {@link Crypt_AES::setBlockLength() setBlockLength()}, for instance. Calling that function,
2032+ * Since \phpseclib\Crypt\AES extends \phpseclib\Crypt\Rijndael, some functions are available to be called that, in the context of AES, don't
2033+ * make a whole lot of sense. {@link \phpseclib\Crypt\AES::setBlockLength() setBlockLength()}, for instance. Calling that function,
2034 * however possible, won't do anything (AES has a fixed block length whereas Rijndael has a variable one).
2035 *
2036 * Here's a short example of how to use this library:
2037 * <code>
2038 * <?php
2039- * include 'Crypt/AES.php';
2040+ * include 'vendor/autoload.php';
2041 *
2042- * $aes = new Crypt_AES();
2043+ * $aes = new \phpseclib\Crypt\AES();
2044 *
2045 * $aes->setKey('abcdefghijklmnop');
2046 *
2047@@ -35,145 +39,33 @@
2048 * ?>
2049 * </code>
2050 *
2051- * LICENSE: Permission is hereby granted, free of charge, to any person obtaining a copy
2052- * of this software and associated documentation files (the "Software"), to deal
2053- * in the Software without restriction, including without limitation the rights
2054- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
2055- * copies of the Software, and to permit persons to whom the Software is
2056- * furnished to do so, subject to the following conditions:
2057- *
2058- * The above copyright notice and this permission notice shall be included in
2059- * all copies or substantial portions of the Software.
2060- *
2061- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
2062- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
2063- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
2064- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
2065- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
2066- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
2067- * THE SOFTWARE.
2068- *
2069 * @category Crypt
2070- * @package Crypt_AES
2071+ * @package AES
2072 * @author Jim Wigginton <terrafrost@php.net>
2073- * @copyright MMVIII Jim Wigginton
2074+ * @copyright 2008 Jim Wigginton
2075 * @license http://www.opensource.org/licenses/mit-license.html MIT License
2076 * @link http://phpseclib.sourceforge.net
2077 */
2078
2079-/**
2080- * Include Crypt_Rijndael
2081- */
2082-if (!class_exists('Crypt_Rijndael')) {
2083- include_once 'Rijndael.php';
2084-}
2085-
2086-/**#@+
2087- * @access public
2088- * @see Crypt_AES::encrypt()
2089- * @see Crypt_AES::decrypt()
2090- */
2091-/**
2092- * Encrypt / decrypt using the Counter mode.
2093- *
2094- * Set to -1 since that's what Crypt/Random.php uses to index the CTR mode.
2095- *
2096- * @link http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation#Counter_.28CTR.29
2097- */
2098-define('CRYPT_AES_MODE_CTR', CRYPT_MODE_CTR);
2099-/**
2100- * Encrypt / decrypt using the Electronic Code Book mode.
2101- *
2102- * @link http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation#Electronic_codebook_.28ECB.29
2103- */
2104-define('CRYPT_AES_MODE_ECB', CRYPT_MODE_ECB);
2105-/**
2106- * Encrypt / decrypt using the Code Book Chaining mode.
2107- *
2108- * @link http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation#Cipher-block_chaining_.28CBC.29
2109- */
2110-define('CRYPT_AES_MODE_CBC', CRYPT_MODE_CBC);
2111-/**
2112- * Encrypt / decrypt using the Cipher Feedback mode.
2113- *
2114- * @link http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation#Cipher_feedback_.28CFB.29
2115- */
2116-define('CRYPT_AES_MODE_CFB', CRYPT_MODE_CFB);
2117-/**
2118- * Encrypt / decrypt using the Cipher Feedback mode.
2119- *
2120- * @link http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation#Output_feedback_.28OFB.29
2121- */
2122-define('CRYPT_AES_MODE_OFB', CRYPT_MODE_OFB);
2123-/**#@-*/
2124-
2125-/**#@+
2126- * @access private
2127- * @see Crypt_AES::Crypt_AES()
2128- */
2129-/**
2130- * Toggles the internal implementation
2131- */
2132-define('CRYPT_AES_MODE_INTERNAL', CRYPT_MODE_INTERNAL);
2133-/**
2134- * Toggles the mcrypt implementation
2135- */
2136-define('CRYPT_AES_MODE_MCRYPT', CRYPT_MODE_MCRYPT);
2137-/**#@-*/
2138+namespace phpseclib\Crypt;
2139+
2140+use phpseclib\Crypt\Rijndael;
2141
2142 /**
2143 * Pure-PHP implementation of AES.
2144 *
2145- * @package Crypt_AES
2146+ * @package AES
2147 * @author Jim Wigginton <terrafrost@php.net>
2148 * @access public
2149 */
2150-class Crypt_AES extends Crypt_Rijndael
2151+class AES extends Rijndael
2152 {
2153 /**
2154- * The namespace used by the cipher for its constants.
2155- *
2156- * @see Crypt_Base::const_namespace
2157- * @var String
2158- * @access private
2159- */
2160- var $const_namespace = 'AES';
2161-
2162- /**
2163- * Default Constructor.
2164- *
2165- * Determines whether or not the mcrypt extension should be used.
2166- *
2167- * $mode could be:
2168- *
2169- * - CRYPT_AES_MODE_ECB
2170- *
2171- * - CRYPT_AES_MODE_CBC
2172- *
2173- * - CRYPT_AES_MODE_CTR
2174- *
2175- * - CRYPT_AES_MODE_CFB
2176- *
2177- * - CRYPT_AES_MODE_OFB
2178- *
2179- * If not explicitly set, CRYPT_AES_MODE_CBC will be used.
2180- *
2181- * @see Crypt_Rijndael::Crypt_Rijndael()
2182- * @see Crypt_Base::Crypt_Base()
2183- * @param optional Integer $mode
2184- * @access public
2185- */
2186- function Crypt_AES($mode = CRYPT_AES_MODE_CBC)
2187- {
2188- parent::Crypt_Rijndael($mode);
2189- }
2190-
2191- /**
2192 * Dummy function
2193 *
2194- * Since Crypt_AES extends Crypt_Rijndael, this function is, technically, available, but it doesn't do anything.
2195+ * Since \phpseclib\Crypt\AES extends \phpseclib\Crypt\Rijndael, this function is, technically, available, but it doesn't do anything.
2196 *
2197- * @see Crypt_Rijndael::setBlockLength()
2198+ * @see \phpseclib\Crypt\Rijndael::setBlockLength()
2199 * @access public
2200 * @param Integer $length
2201 */
2202@@ -181,4 +73,56 @@
2203 {
2204 return;
2205 }
2206+
2207+ /**
2208+ * Sets the key length
2209+ *
2210+ * Valid key lengths are 128, 192, and 256. If the length is less than 128, it will be rounded up to
2211+ * 128. If the length is greater than 128 and invalid, it will be rounded down to the closest valid amount.
2212+ *
2213+ * @see \phpseclib\Crypt\Rijndael:setKeyLength()
2214+ * @access public
2215+ * @param Integer $length
2216+ */
2217+ function setKeyLength($length)
2218+ {
2219+ switch ($length) {
2220+ case 160:
2221+ $length = 192;
2222+ break;
2223+ case 224:
2224+ $length = 256;
2225+ }
2226+ parent::setKeyLength($length);
2227+ }
2228+
2229+ /**
2230+ * Sets the key.
2231+ *
2232+ * Rijndael supports five different key lengths, AES only supports three.
2233+ *
2234+ * @see \phpseclib\Crypt\Rijndael:setKey()
2235+ * @see setKeyLength()
2236+ * @access public
2237+ * @param String $key
2238+ */
2239+ function setKey($key)
2240+ {
2241+ parent::setKey($key);
2242+
2243+ if (!$this->explicit_key_length) {
2244+ $length = strlen($key);
2245+ switch (true) {
2246+ case $length <= 16:
2247+ $this->key_size = 16;
2248+ break;
2249+ case $length <= 24:
2250+ $this->key_size = 24;
2251+ break;
2252+ default:
2253+ $this->key_size = 32;
2254+ }
2255+ $this->_setEngine();
2256+ }
2257+ }
2258 }
2259
2260=== modified file 'libraries/phpseclib/Crypt/Base.php'
2261--- libraries/phpseclib/Crypt/Base.php 2015-04-28 10:31:57 +0000
2262+++ libraries/phpseclib/Crypt/Base.php 2015-10-27 17:36:50 +0000
2263@@ -1,14 +1,14 @@
2264 <?php
2265
2266 /**
2267- * Base Class for all Crypt_* cipher classes
2268+ * Base Class for all \phpseclib\Crypt\* cipher classes
2269 *
2270- * PHP versions 4 and 5
2271+ * PHP version 5
2272 *
2273 * Internally for phpseclib developers:
2274 * If you plan to add a new cipher class, please note following rules:
2275 *
2276- * - The new Crypt_* cipher class should extend Crypt_Base
2277+ * - The new \phpseclib\Crypt\* cipher class should extend \phpseclib\Crypt\Base
2278 *
2279 * - Following methods are then required to be overridden/overloaded:
2280 *
2281@@ -20,110 +20,107 @@
2282 *
2283 * - All other methods are optional to be overridden/overloaded
2284 *
2285- * - Look at the source code of the current ciphers how they extend Crypt_Base
2286+ * - Look at the source code of the current ciphers how they extend \phpseclib\Crypt\Base
2287 * and take one of them as a start up for the new cipher class.
2288 *
2289 * - Please read all the other comments/notes/hints here also for each class var/method
2290 *
2291- * LICENSE: Permission is hereby granted, free of charge, to any person obtaining a copy
2292- * of this software and associated documentation files (the "Software"), to deal
2293- * in the Software without restriction, including without limitation the rights
2294- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
2295- * copies of the Software, and to permit persons to whom the Software is
2296- * furnished to do so, subject to the following conditions:
2297- *
2298- * The above copyright notice and this permission notice shall be included in
2299- * all copies or substantial portions of the Software.
2300- *
2301- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
2302- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
2303- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
2304- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
2305- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
2306- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
2307- * THE SOFTWARE.
2308- *
2309 * @category Crypt
2310- * @package Crypt_Base
2311+ * @package Base
2312 * @author Jim Wigginton <terrafrost@php.net>
2313 * @author Hans-Juergen Petrich <petrich@tronic-media.com>
2314- * @copyright MMVII Jim Wigginton
2315+ * @copyright 2007 Jim Wigginton
2316 * @license http://www.opensource.org/licenses/mit-license.html MIT License
2317 * @link http://phpseclib.sourceforge.net
2318 */
2319
2320-/**#@+
2321- * @access public
2322- * @see Crypt_Base::encrypt()
2323- * @see Crypt_Base::decrypt()
2324- */
2325-/**
2326- * Encrypt / decrypt using the Counter mode.
2327- *
2328- * Set to -1 since that's what Crypt/Random.php uses to index the CTR mode.
2329- *
2330- * @link http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation#Counter_.28CTR.29
2331- */
2332-define('CRYPT_MODE_CTR', -1);
2333-/**
2334- * Encrypt / decrypt using the Electronic Code Book mode.
2335- *
2336- * @link http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation#Electronic_codebook_.28ECB.29
2337- */
2338-define('CRYPT_MODE_ECB', 1);
2339-/**
2340- * Encrypt / decrypt using the Code Book Chaining mode.
2341- *
2342- * @link http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation#Cipher-block_chaining_.28CBC.29
2343- */
2344-define('CRYPT_MODE_CBC', 2);
2345-/**
2346- * Encrypt / decrypt using the Cipher Feedback mode.
2347- *
2348- * @link http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation#Cipher_feedback_.28CFB.29
2349- */
2350-define('CRYPT_MODE_CFB', 3);
2351-/**
2352- * Encrypt / decrypt using the Output Feedback mode.
2353- *
2354- * @link http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation#Output_feedback_.28OFB.29
2355- */
2356-define('CRYPT_MODE_OFB', 4);
2357-/**
2358- * Encrypt / decrypt using streaming mode.
2359- *
2360- */
2361-define('CRYPT_MODE_STREAM', 5);
2362-/**#@-*/
2363-
2364-/**#@+
2365- * @access private
2366- * @see Crypt_Base::Crypt_Base()
2367- */
2368-/**
2369- * Base value for the internal implementation $engine switch
2370- */
2371-define('CRYPT_MODE_INTERNAL', 1);
2372-/**
2373- * Base value for the mcrypt implementation $engine switch
2374- */
2375-define('CRYPT_MODE_MCRYPT', 2);
2376-/**#@-*/
2377-
2378-/**
2379- * Base Class for all Crypt_* cipher classes
2380- *
2381- * @package Crypt_Base
2382+namespace phpseclib\Crypt;
2383+
2384+use phpseclib\Crypt\Hash;
2385+
2386+/**
2387+ * Base Class for all \phpseclib\Crypt\* cipher classes
2388+ *
2389+ * @package Base
2390 * @author Jim Wigginton <terrafrost@php.net>
2391 * @author Hans-Juergen Petrich <petrich@tronic-media.com>
2392- * @access public
2393 */
2394-class Crypt_Base
2395+abstract class Base
2396 {
2397+ /**#@+
2398+ * @access public
2399+ * @see \phpseclib\Crypt\Base::encrypt()
2400+ * @see \phpseclib\Crypt\Base::decrypt()
2401+ */
2402+ /**
2403+ * Encrypt / decrypt using the Counter mode.
2404+ *
2405+ * Set to -1 since that's what Crypt/Random.php uses to index the CTR mode.
2406+ *
2407+ * @link http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation#Counter_.28CTR.29
2408+ */
2409+ const MODE_CTR = -1;
2410+ /**
2411+ * Encrypt / decrypt using the Electronic Code Book mode.
2412+ *
2413+ * @link http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation#Electronic_codebook_.28ECB.29
2414+ */
2415+ const MODE_ECB = 1;
2416+ /**
2417+ * Encrypt / decrypt using the Code Book Chaining mode.
2418+ *
2419+ * @link http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation#Cipher-block_chaining_.28CBC.29
2420+ */
2421+ const MODE_CBC = 2;
2422+ /**
2423+ * Encrypt / decrypt using the Cipher Feedback mode.
2424+ *
2425+ * @link http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation#Cipher_feedback_.28CFB.29
2426+ */
2427+ const MODE_CFB = 3;
2428+ /**
2429+ * Encrypt / decrypt using the Output Feedback mode.
2430+ *
2431+ * @link http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation#Output_feedback_.28OFB.29
2432+ */
2433+ const MODE_OFB = 4;
2434+ /**
2435+ * Encrypt / decrypt using streaming mode.
2436+ */
2437+ const MODE_STREAM = 5;
2438+ /**#@-*/
2439+
2440+ /**
2441+ * Whirlpool available flag
2442+ *
2443+ * @see \phpseclib\Crypt\Base::_hashInlineCryptFunction()
2444+ * @var Boolean
2445+ * @access private
2446+ */
2447+ static $WHIRLPOOL_AVAILABLE;
2448+
2449+ /**#@+
2450+ * @access private
2451+ * @see \phpseclib\Crypt\Base::__construct()
2452+ */
2453+ /**
2454+ * Base value for the internal implementation $engine switch
2455+ */
2456+ const ENGINE_INTERNAL = 1;
2457+ /**
2458+ * Base value for the mcrypt implementation $engine switch
2459+ */
2460+ const ENGINE_MCRYPT = 2;
2461+ /**
2462+ * Base value for the mcrypt implementation $engine switch
2463+ */
2464+ const ENGINE_OPENSSL = 3;
2465+ /**#@-*/
2466+
2467 /**
2468 * The Encryption Mode
2469 *
2470- * @see Crypt_Base::Crypt_Base()
2471+ * @see \phpseclib\Crypt\Base::__construct()
2472 * @var Integer
2473 * @access private
2474 */
2475@@ -140,7 +137,7 @@
2476 /**
2477 * The Key
2478 *
2479- * @see Crypt_Base::setKey()
2480+ * @see \phpseclib\Crypt\Base::setKey()
2481 * @var String
2482 * @access private
2483 */
2484@@ -149,7 +146,7 @@
2485 /**
2486 * The Initialization Vector
2487 *
2488- * @see Crypt_Base::setIV()
2489+ * @see \phpseclib\Crypt\Base::setIV()
2490 * @var String
2491 * @access private
2492 */
2493@@ -158,8 +155,8 @@
2494 /**
2495 * A "sliding" Initialization Vector
2496 *
2497- * @see Crypt_Base::enableContinuousBuffer()
2498- * @see Crypt_Base::_clearBuffers()
2499+ * @see \phpseclib\Crypt\Base::enableContinuousBuffer()
2500+ * @see \phpseclib\Crypt\Base::_clearBuffers()
2501 * @var String
2502 * @access private
2503 */
2504@@ -168,8 +165,8 @@
2505 /**
2506 * A "sliding" Initialization Vector
2507 *
2508- * @see Crypt_Base::enableContinuousBuffer()
2509- * @see Crypt_Base::_clearBuffers()
2510+ * @see \phpseclib\Crypt\Base::enableContinuousBuffer()
2511+ * @see \phpseclib\Crypt\Base::_clearBuffers()
2512 * @var String
2513 * @access private
2514 */
2515@@ -178,7 +175,7 @@
2516 /**
2517 * Continuous Buffer status
2518 *
2519- * @see Crypt_Base::enableContinuousBuffer()
2520+ * @see \phpseclib\Crypt\Base::enableContinuousBuffer()
2521 * @var Boolean
2522 * @access private
2523 */
2524@@ -187,8 +184,8 @@
2525 /**
2526 * Encryption buffer for CTR, OFB and CFB modes
2527 *
2528- * @see Crypt_Base::encrypt()
2529- * @see Crypt_Base::_clearBuffers()
2530+ * @see \phpseclib\Crypt\Base::encrypt()
2531+ * @see \phpseclib\Crypt\Base::_clearBuffers()
2532 * @var Array
2533 * @access private
2534 */
2535@@ -197,8 +194,8 @@
2536 /**
2537 * Decryption buffer for CTR, OFB and CFB modes
2538 *
2539- * @see Crypt_Base::decrypt()
2540- * @see Crypt_Base::_clearBuffers()
2541+ * @see \phpseclib\Crypt\Base::decrypt()
2542+ * @see \phpseclib\Crypt\Base::_clearBuffers()
2543 * @var Array
2544 * @access private
2545 */
2546@@ -210,7 +207,7 @@
2547 * The mcrypt resource can be recreated every time something needs to be created or it can be created just once.
2548 * Since mcrypt operates in continuous mode, by default, it'll need to be recreated when in non-continuous mode.
2549 *
2550- * @see Crypt_Base::encrypt()
2551+ * @see \phpseclib\Crypt\Base::encrypt()
2552 * @var Resource
2553 * @access private
2554 */
2555@@ -222,7 +219,7 @@
2556 * The mcrypt resource can be recreated every time something needs to be created or it can be created just once.
2557 * Since mcrypt operates in continuous mode, by default, it'll need to be recreated when in non-continuous mode.
2558 *
2559- * @see Crypt_Base::decrypt()
2560+ * @see \phpseclib\Crypt\Base::decrypt()
2561 * @var Resource
2562 * @access private
2563 */
2564@@ -231,8 +228,8 @@
2565 /**
2566 * Does the enmcrypt resource need to be (re)initialized?
2567 *
2568- * @see Crypt_Twofish::setKey()
2569- * @see Crypt_Twofish::setIV()
2570+ * @see \phpseclib\Crypt\Twofish::setKey()
2571+ * @see \phpseclib\Crypt\Twofish::setIV()
2572 * @var Boolean
2573 * @access private
2574 */
2575@@ -241,8 +238,8 @@
2576 /**
2577 * Does the demcrypt resource need to be (re)initialized?
2578 *
2579- * @see Crypt_Twofish::setKey()
2580- * @see Crypt_Twofish::setIV()
2581+ * @see \phpseclib\Crypt\Twofish::setKey()
2582+ * @see \phpseclib\Crypt\Twofish::setIV()
2583 * @var Boolean
2584 * @access private
2585 */
2586@@ -259,9 +256,9 @@
2587 * use a separate ECB-mode mcrypt resource.
2588 *
2589 * @link http://phpseclib.sourceforge.net/cfb-demo.phps
2590- * @see Crypt_Base::encrypt()
2591- * @see Crypt_Base::decrypt()
2592- * @see Crypt_Base::_setupMcrypt()
2593+ * @see \phpseclib\Crypt\Base::encrypt()
2594+ * @see \phpseclib\Crypt\Base::decrypt()
2595+ * @see \phpseclib\Crypt\Base::_setupMcrypt()
2596 * @var Resource
2597 * @access private
2598 */
2599@@ -271,7 +268,7 @@
2600 * Optimizing value while CFB-encrypting
2601 *
2602 * Only relevant if $continuousBuffer enabled
2603- * and $engine == CRYPT_MODE_MCRYPT
2604+ * and $engine == self::ENGINE_MCRYPT
2605 *
2606 * It's faster to re-init $enmcrypt if
2607 * $buffer bytes > $cfb_init_len than
2608@@ -283,7 +280,7 @@
2609 * which, typically, depends on the complexity
2610 * on its internaly Key-expanding algorithm.
2611 *
2612- * @see Crypt_Base::encrypt()
2613+ * @see \phpseclib\Crypt\Base::encrypt()
2614 * @var Integer
2615 * @access private
2616 */
2617@@ -303,7 +300,7 @@
2618 /**
2619 * Padding status
2620 *
2621- * @see Crypt_Base::enablePadding()
2622+ * @see \phpseclib\Crypt\Base::enablePadding()
2623 * @var Boolean
2624 * @access private
2625 */
2626@@ -312,7 +309,7 @@
2627 /**
2628 * Is the mode one that is paddable?
2629 *
2630- * @see Crypt_Base::Crypt_Base()
2631+ * @see \phpseclib\Crypt\Base::__construct()
2632 * @var Boolean
2633 * @access private
2634 */
2635@@ -323,39 +320,68 @@
2636 * which will be determined automatically on __construct()
2637 *
2638 * Currently available $engines are:
2639- * - CRYPT_MODE_MCRYPT (fast, php-extension: mcrypt, extension_loaded('mcrypt') required)
2640- * - CRYPT_MODE_INTERNAL (slower, pure php-engine, no php-extension required)
2641- *
2642- * In the pipeline... maybe. But currently not available:
2643- * - CRYPT_MODE_OPENSSL (very fast, php-extension: openssl, extension_loaded('openssl') required)
2644- *
2645- * If possible, CRYPT_MODE_MCRYPT will be used for each cipher.
2646- * Otherwise CRYPT_MODE_INTERNAL
2647- *
2648- * @see Crypt_Base::encrypt()
2649- * @see Crypt_Base::decrypt()
2650+ * - self::ENGINE_OPENSSL (very fast, php-extension: openssl, extension_loaded('openssl') required)
2651+ * - self::ENGINE_MCRYPT (fast, php-extension: mcrypt, extension_loaded('mcrypt') required)
2652+ * - self::ENGINE_INTERNAL (slower, pure php-engine, no php-extension required)
2653+ *
2654+ * @see \phpseclib\Crypt\Base::_setEngine()
2655+ * @see \phpseclib\Crypt\Base::encrypt()
2656+ * @see \phpseclib\Crypt\Base::decrypt()
2657 * @var Integer
2658 * @access private
2659 */
2660 var $engine;
2661
2662 /**
2663+ * Holds the preferred crypt engine
2664+ *
2665+ * @see \phpseclib\Crypt\Base::_setEngine()
2666+ * @see \phpseclib\Crypt\Base::setPreferredEngine()
2667+ * @var Integer
2668+ * @access private
2669+ */
2670+ var $preferredEngine;
2671+
2672+ /**
2673 * The mcrypt specific name of the cipher
2674 *
2675- * Only used if $engine == CRYPT_MODE_MCRYPT
2676+ * Only used if $engine == self::ENGINE_MCRYPT
2677 *
2678 * @link http://www.php.net/mcrypt_module_open
2679 * @link http://www.php.net/mcrypt_list_algorithms
2680- * @see Crypt_Base::_setupMcrypt()
2681+ * @see \phpseclib\Crypt\Base::_setupMcrypt()
2682 * @var String
2683 * @access private
2684 */
2685 var $cipher_name_mcrypt;
2686
2687 /**
2688+ * The openssl specific name of the cipher
2689+ *
2690+ * Only used if $engine == CRYPT_ENGINE_OPENSSL
2691+ *
2692+ * @link http://www.php.net/openssl-get-cipher-methods
2693+ * @var String
2694+ * @access private
2695+ */
2696+ var $cipher_name_openssl;
2697+
2698+ /**
2699+ * The openssl specific name of the cipher in ECB mode
2700+ *
2701+ * If OpenSSL does not support the mode we're trying to use (CTR)
2702+ * it can still be emulated with ECB mode.
2703+ *
2704+ * @link http://www.php.net/openssl-get-cipher-methods
2705+ * @var String
2706+ * @access private
2707+ */
2708+ var $cipher_name_openssl_ecb;
2709+
2710+ /**
2711 * The default password key_size used by setPassword()
2712 *
2713- * @see Crypt_Base::setPassword()
2714+ * @see \phpseclib\Crypt\Base::setPassword()
2715 * @var Integer
2716 * @access private
2717 */
2718@@ -364,45 +390,22 @@
2719 /**
2720 * The default salt used by setPassword()
2721 *
2722- * @see Crypt_Base::setPassword()
2723+ * @see \phpseclib\Crypt\Base::setPassword()
2724 * @var String
2725 * @access private
2726 */
2727 var $password_default_salt = 'phpseclib/salt';
2728
2729 /**
2730- * The namespace used by the cipher for its constants.
2731- *
2732- * ie: AES.php is using CRYPT_AES_MODE_* for its constants
2733- * so $const_namespace is AES
2734- *
2735- * DES.php is using CRYPT_DES_MODE_* for its constants
2736- * so $const_namespace is DES... and so on
2737- *
2738- * All CRYPT_<$const_namespace>_MODE_* are aliases of
2739- * the generic CRYPT_MODE_* constants, so both could be used
2740- * for each cipher.
2741- *
2742- * Example:
2743- * $aes = new Crypt_AES(CRYPT_AES_MODE_CFB); // $aes will operate in cfb mode
2744- * $aes = new Crypt_AES(CRYPT_MODE_CFB); // identical
2745- *
2746- * @see Crypt_Base::Crypt_Base()
2747- * @var String
2748- * @access private
2749- */
2750- var $const_namespace;
2751-
2752- /**
2753 * The name of the performance-optimized callback function
2754 *
2755 * Used by encrypt() / decrypt()
2756- * only if $engine == CRYPT_MODE_INTERNAL
2757+ * only if $engine == self::ENGINE_INTERNAL
2758 *
2759- * @see Crypt_Base::encrypt()
2760- * @see Crypt_Base::decrypt()
2761- * @see Crypt_Base::_setupInlineCrypt()
2762- * @see Crypt_Base::$use_inline_crypt
2763+ * @see \phpseclib\Crypt\Base::encrypt()
2764+ * @see \phpseclib\Crypt\Base::decrypt()
2765+ * @see \phpseclib\Crypt\Base::_setupInlineCrypt()
2766+ * @see \phpseclib\Crypt\Base::$use_inline_crypt
2767 * @var Callback
2768 * @access private
2769 */
2770@@ -411,84 +414,78 @@
2771 /**
2772 * Holds whether performance-optimized $inline_crypt() can/should be used.
2773 *
2774- * @see Crypt_Base::encrypt()
2775- * @see Crypt_Base::decrypt()
2776- * @see Crypt_Base::inline_crypt
2777+ * @see \phpseclib\Crypt\Base::encrypt()
2778+ * @see \phpseclib\Crypt\Base::decrypt()
2779+ * @see \phpseclib\Crypt\Base::inline_crypt
2780 * @var mixed
2781 * @access private
2782 */
2783 var $use_inline_crypt;
2784
2785 /**
2786+ * If OpenSSL can be used in ECB but not in CTR we can emulate CTR
2787+ *
2788+ * @see \phpseclib\Crypt\Base::_openssl_ctr_process()
2789+ * @var Boolean
2790+ * @access private
2791+ */
2792+ var $openssl_emulate_ctr = false;
2793+
2794+ /**
2795+ * Determines what options are passed to openssl_encrypt/decrypt
2796+ *
2797+ * @see \phpseclib\Crypt\Base::isValidEngine()
2798+ * @var mixed
2799+ * @access private
2800+ */
2801+ var $openssl_options;
2802+
2803+ /**
2804 * Default Constructor.
2805 *
2806 * Determines whether or not the mcrypt extension should be used.
2807 *
2808 * $mode could be:
2809 *
2810- * - CRYPT_MODE_ECB
2811- *
2812- * - CRYPT_MODE_CBC
2813- *
2814- * - CRYPT_MODE_CTR
2815- *
2816- * - CRYPT_MODE_CFB
2817- *
2818- * - CRYPT_MODE_OFB
2819+ * - self::MODE_ECB
2820+ *
2821+ * - self::MODE_CBC
2822+ *
2823+ * - self::MODE_CTR
2824+ *
2825+ * - self::MODE_CFB
2826+ *
2827+ * - self::MODE_OFB
2828 *
2829 * (or the alias constants of the chosen cipher, for example for AES: CRYPT_AES_MODE_ECB or CRYPT_AES_MODE_CBC ...)
2830 *
2831- * If not explicitly set, CRYPT_MODE_CBC will be used.
2832+ * If not explicitly set, self::MODE_CBC will be used.
2833 *
2834 * @param optional Integer $mode
2835 * @access public
2836 */
2837- function Crypt_Base($mode = CRYPT_MODE_CBC)
2838+ function __construct($mode = self::MODE_CBC)
2839 {
2840- $const_crypt_mode = 'CRYPT_' . $this->const_namespace . '_MODE';
2841-
2842- // Determining the availibility of mcrypt support for the cipher
2843- if (!defined($const_crypt_mode)) {
2844- switch (true) {
2845- case extension_loaded('mcrypt') && in_array($this->cipher_name_mcrypt, mcrypt_list_algorithms()):
2846- define($const_crypt_mode, CRYPT_MODE_MCRYPT);
2847- break;
2848- default:
2849- define($const_crypt_mode, CRYPT_MODE_INTERNAL);
2850- }
2851- }
2852-
2853- // Determining which internal $engine should be used.
2854- // The fastes possible first.
2855- switch (true) {
2856- case empty($this->cipher_name_mcrypt): // The cipher module has no mcrypt-engine support at all so we force CRYPT_MODE_INTERNAL
2857- $this->engine = CRYPT_MODE_INTERNAL;
2858- break;
2859- case constant($const_crypt_mode) == CRYPT_MODE_MCRYPT:
2860- $this->engine = CRYPT_MODE_MCRYPT;
2861- break;
2862- default:
2863- $this->engine = CRYPT_MODE_INTERNAL;
2864- }
2865-
2866 // $mode dependent settings
2867 switch ($mode) {
2868- case CRYPT_MODE_ECB:
2869+ case self::MODE_ECB:
2870 $this->paddable = true;
2871- $this->mode = $mode;
2872- break;
2873- case CRYPT_MODE_CTR:
2874- case CRYPT_MODE_CFB:
2875- case CRYPT_MODE_OFB:
2876- case CRYPT_MODE_STREAM:
2877- $this->mode = $mode;
2878- break;
2879- case CRYPT_MODE_CBC:
2880+ $this->mode = self::MODE_ECB;
2881+ break;
2882+ case self::MODE_CTR:
2883+ case self::MODE_CFB:
2884+ case self::MODE_OFB:
2885+ case self::MODE_STREAM:
2886+ $this->mode = $mode;
2887+ break;
2888+ case self::MODE_CBC:
2889 default:
2890 $this->paddable = true;
2891- $this->mode = CRYPT_MODE_CBC;
2892+ $this->mode = self::MODE_CBC;
2893 }
2894
2895+ $this->_setEngine();
2896+
2897 // Determining whether inline crypting can be used by the cipher
2898 if ($this->use_inline_crypt !== false && function_exists('create_function')) {
2899 $this->use_inline_crypt = true;
2900@@ -498,17 +495,16 @@
2901 /**
2902 * Sets the initialization vector. (optional)
2903 *
2904- * SetIV is not required when CRYPT_MODE_ECB (or ie for AES: CRYPT_AES_MODE_ECB) is being used. If not explicitly set, it'll be assumed
2905+ * SetIV is not required when self::MODE_ECB (or ie for AES: \phpseclib\Crypt\AES::MODE_ECB) is being used. If not explicitly set, it'll be assumed
2906 * to be all zero's.
2907 *
2908- * Note: Could, but not must, extend by the child Crypt_* class
2909- *
2910 * @access public
2911 * @param String $iv
2912+ * @internal Can be overwritten by a sub class, but does not have to be
2913 */
2914 function setIV($iv)
2915 {
2916- if ($this->mode == CRYPT_MODE_ECB) {
2917+ if ($this->mode == self::MODE_ECB) {
2918 return;
2919 }
2920
2921@@ -526,39 +522,39 @@
2922 *
2923 * If the key is not explicitly set, it'll be assumed to be all null bytes.
2924 *
2925- * Note: Could, but not must, extend by the child Crypt_* class
2926- *
2927 * @access public
2928 * @param String $key
2929+ * @internal Could, but not must, extend by the child Crypt_* class
2930 */
2931 function setKey($key)
2932 {
2933 $this->key = $key;
2934 $this->changed = true;
2935+ $this->_setEngine();
2936 }
2937
2938 /**
2939 * Sets the password.
2940 *
2941 * Depending on what $method is set to, setPassword()'s (optional) parameters are as follows:
2942- * {@link http://en.wikipedia.org/wiki/PBKDF2 pbkdf2}:
2943+ * {@link http://en.wikipedia.org/wiki/PBKDF2 pbkdf2} or pbkdf1:
2944 * $hash, $salt, $count, $dkLen
2945 *
2946 * Where $hash (default = sha1) currently supports the following hashes: see: Crypt/Hash.php
2947 *
2948- * Note: Could, but not must, extend by the child Crypt_* class
2949- *
2950 * @see Crypt/Hash.php
2951 * @param String $password
2952 * @param optional String $method
2953+ * @return Boolean
2954 * @access public
2955+ * @internal Could, but not must, extend by the child Crypt_* class
2956 */
2957 function setPassword($password, $method = 'pbkdf2')
2958 {
2959 $key = '';
2960
2961 switch ($method) {
2962- default: // 'pbkdf2'
2963+ default: // 'pbkdf2' or 'pbkdf1'
2964 $func_args = func_get_args();
2965
2966 // Hash function
2967@@ -572,19 +568,37 @@
2968 $count = isset($func_args[4]) ? $func_args[4] : 1000;
2969
2970 // Keylength
2971- $dkLen = isset($func_args[5]) ? $func_args[5] : $this->password_key_size;
2972+ if (isset($func_args[5])) {
2973+ $dkLen = $func_args[5];
2974+ } else {
2975+ $dkLen = $method == 'pbkdf1' ? 2 * $this->password_key_size : $this->password_key_size;
2976+ }
2977
2978- // Determining if php[>=5.5.0]'s hash_pbkdf2() function avail- and useable
2979 switch (true) {
2980+ case $method == 'pbkdf1':
2981+ $hashObj = new Hash();
2982+ $hashObj->setHash($hash);
2983+ if ($dkLen > $hashObj->getLength()) {
2984+ user_error('Derived key too long');
2985+ return false;
2986+ }
2987+ $t = $password . $salt;
2988+ for ($i = 0; $i < $count; ++$i) {
2989+ $t = $hashObj->hash($t);
2990+ }
2991+ $key = substr($t, 0, $dkLen);
2992+
2993+ $this->setKey(substr($key, 0, $dkLen >> 1));
2994+ $this->setIV(substr($key, $dkLen >> 1));
2995+
2996+ return true;
2997+ // Determining if php[>=5.5.0]'s hash_pbkdf2() function avail- and useable
2998 case !function_exists('hash_pbkdf2'):
2999 case !function_exists('hash_algos'):
3000 case !in_array($hash, hash_algos()):
3001- if (!class_exists('Crypt_Hash')) {
3002- include_once 'Crypt/Hash.php';
3003- }
3004 $i = 1;
3005 while (strlen($key) < $dkLen) {
3006- $hmac = new Crypt_Hash();
3007+ $hmac = new Hash();
3008 $hmac->setHash($hash);
3009 $hmac->setKey($password);
3010 $f = $u = $hmac->hash($salt . pack('N', $i++));
3011@@ -602,6 +616,8 @@
3012 }
3013
3014 $this->setKey($key);
3015+
3016+ return true;
3017 }
3018
3019 /**
3020@@ -618,16 +634,91 @@
3021 * strlen($plaintext) will still need to be a multiple of the block size, however, arbitrary values can be added to make it that
3022 * length.
3023 *
3024- * Note: Could, but not must, extend by the child Crypt_* class
3025- *
3026- * @see Crypt_Base::decrypt()
3027+ * @see \phpseclib\Crypt\Base::decrypt()
3028 * @access public
3029 * @param String $plaintext
3030- * @return String $cipertext
3031+ * @return String $ciphertext
3032+ * @internal Could, but not must, extend by the child Crypt_* class
3033 */
3034 function encrypt($plaintext)
3035 {
3036- if ($this->engine == CRYPT_MODE_MCRYPT) {
3037+ if ($this->paddable) {
3038+ $plaintext = $this->_pad($plaintext);
3039+ }
3040+
3041+ if ($this->engine === self::ENGINE_OPENSSL) {
3042+ if ($this->changed) {
3043+ $this->_clearBuffers();
3044+ $this->changed = false;
3045+ }
3046+ switch ($this->mode) {
3047+ case self::MODE_STREAM:
3048+ return openssl_encrypt($plaintext, $this->cipher_name_openssl, $this->key, $this->openssl_options);
3049+ case self::MODE_ECB:
3050+ $result = openssl_encrypt($plaintext, $this->cipher_name_openssl, $this->key, $this->openssl_options);
3051+ return !defined('OPENSSL_RAW_DATA') ? substr($result, 0, -$this->block_size) : $result;
3052+ case self::MODE_CBC:
3053+ $result = openssl_encrypt($plaintext, $this->cipher_name_openssl, $this->key, $this->openssl_options, $this->encryptIV);
3054+ if ($this->continuousBuffer) {
3055+ $this->encryptIV = substr($result, -$this->block_size);
3056+ }
3057+ return !defined('OPENSSL_RAW_DATA') ? substr($result, 0, -$this->block_size) : $result;
3058+ case self::MODE_CTR:
3059+ return $this->_openssl_ctr_process($plaintext, $this->encryptIV, $this->enbuffer);
3060+ case self::MODE_CFB:
3061+ // cfb loosely routines inspired by openssl's:
3062+ // {@link http://cvs.openssl.org/fileview?f=openssl/crypto/modes/cfb128.c&v=1.3.2.2.2.1}
3063+ $ciphertext = '';
3064+ if ($this->continuousBuffer) {
3065+ $iv = &$this->encryptIV;
3066+ $pos = &$this->enbuffer['pos'];
3067+ } else {
3068+ $iv = $this->encryptIV;
3069+ $pos = 0;
3070+ }
3071+ $len = strlen($plaintext);
3072+ $i = 0;
3073+ if ($pos) {
3074+ $orig_pos = $pos;
3075+ $max = $this->block_size - $pos;
3076+ if ($len >= $max) {
3077+ $i = $max;
3078+ $len-= $max;
3079+ $pos = 0;
3080+ } else {
3081+ $i = $len;
3082+ $pos+= $len;
3083+ $len = 0;
3084+ }
3085+ // ie. $i = min($max, $len), $len-= $i, $pos+= $i, $pos%= $blocksize
3086+ $ciphertext = substr($iv, $orig_pos) ^ $plaintext;
3087+ $iv = substr_replace($iv, $ciphertext, $orig_pos, $i);
3088+ $plaintext = substr($plaintext, $i);
3089+ }
3090+
3091+ $overflow = $len % $this->block_size;
3092+
3093+ if ($overflow) {
3094+ $ciphertext.= openssl_encrypt(substr($plaintext, 0, -$overflow) . str_repeat("\0", $this->block_size), $this->cipher_name_openssl, $this->key, $this->openssl_options, $iv);
3095+ $iv = $this->_string_pop($ciphertext, $this->block_size);
3096+
3097+ $size = $len - $overflow;
3098+ $block = $iv ^ substr($plaintext, -$overflow);
3099+ $iv = substr_replace($iv, $block, 0, $overflow);
3100+ $ciphertext.= $block;
3101+ $pos = $overflow;
3102+ } elseif ($len) {
3103+ $ciphertext = openssl_encrypt($plaintext, $this->cipher_name_openssl, $this->key, $this->openssl_options, $iv);
3104+ $iv = substr($ciphertext, -$this->block_size);
3105+ }
3106+
3107+ return $ciphertext;
3108+ case self::MODE_OFB:
3109+ return $this->_openssl_ofb_process($plaintext, $this->encryptIV, $this->enbuffer);
3110+ }
3111+ }
3112+
3113+ if ($this->engine === self::ENGINE_MCRYPT) {
3114 if ($this->changed) {
3115 $this->_setupMcrypt();
3116 $this->changed = false;
3117@@ -640,7 +731,7 @@
3118 // re: {@link http://phpseclib.sourceforge.net/cfb-demo.phps}
3119 // using mcrypt's default handing of CFB the above would output two different things. using phpseclib's
3120 // rewritten CFB implementation the above outputs the same thing twice.
3121- if ($this->mode == CRYPT_MODE_CFB && $this->continuousBuffer) {
3122+ if ($this->mode == self::MODE_CFB && $this->continuousBuffer) {
3123 $block_size = $this->block_size;
3124 $iv = &$this->encryptIV;
3125 $pos = &$this->enbuffer['pos'];
3126@@ -693,10 +784,6 @@
3127 return $ciphertext;
3128 }
3129
3130- if ($this->paddable) {
3131- $plaintext = $this->_pad($plaintext);
3132- }
3133-
3134 $ciphertext = mcrypt_generic($this->enmcrypt, $plaintext);
3135
3136 if (!$this->continuousBuffer) {
3137@@ -714,20 +801,17 @@
3138 $inline = $this->inline_crypt;
3139 return $inline('encrypt', $this, $plaintext);
3140 }
3141- if ($this->paddable) {
3142- $plaintext = $this->_pad($plaintext);
3143- }
3144
3145 $buffer = &$this->enbuffer;
3146 $block_size = $this->block_size;
3147 $ciphertext = '';
3148 switch ($this->mode) {
3149- case CRYPT_MODE_ECB:
3150+ case self::MODE_ECB:
3151 for ($i = 0; $i < strlen($plaintext); $i+=$block_size) {
3152 $ciphertext.= $this->_encryptBlock(substr($plaintext, $i, $block_size));
3153 }
3154 break;
3155- case CRYPT_MODE_CBC:
3156+ case self::MODE_CBC:
3157 $xor = $this->encryptIV;
3158 for ($i = 0; $i < strlen($plaintext); $i+=$block_size) {
3159 $block = substr($plaintext, $i, $block_size);
3160@@ -739,32 +823,34 @@
3161 $this->encryptIV = $xor;
3162 }
3163 break;
3164- case CRYPT_MODE_CTR:
3165+ case self::MODE_CTR:
3166 $xor = $this->encryptIV;
3167- if (strlen($buffer['encrypted'])) {
3168+ if (strlen($buffer['ciphertext'])) {
3169 for ($i = 0; $i < strlen($plaintext); $i+=$block_size) {
3170 $block = substr($plaintext, $i, $block_size);
3171- if (strlen($block) > strlen($buffer['encrypted'])) {
3172- $buffer['encrypted'].= $this->_encryptBlock($this->_generateXor($xor, $block_size));
3173+ if (strlen($block) > strlen($buffer['ciphertext'])) {
3174+ $buffer['ciphertext'].= $this->_encryptBlock($xor);
3175 }
3176- $key = $this->_stringShift($buffer['encrypted'], $block_size);
3177+ $this->_increment_str($xor);
3178+ $key = $this->_string_shift($buffer['ciphertext'], $block_size);
3179 $ciphertext.= $block ^ $key;
3180 }
3181 } else {
3182 for ($i = 0; $i < strlen($plaintext); $i+=$block_size) {
3183 $block = substr($plaintext, $i, $block_size);
3184- $key = $this->_encryptBlock($this->_generateXor($xor, $block_size));
3185+ $key = $this->_encryptBlock($xor);
3186+ $this->_increment_str($xor);
3187 $ciphertext.= $block ^ $key;
3188 }
3189 }
3190 if ($this->continuousBuffer) {
3191 $this->encryptIV = $xor;
3192 if ($start = strlen($plaintext) % $block_size) {
3193- $buffer['encrypted'] = substr($key, $start) . $buffer['encrypted'];
3194+ $buffer['ciphertext'] = substr($key, $start) . $buffer['ciphertext'];
3195 }
3196 }
3197 break;
3198- case CRYPT_MODE_CFB:
3199+ case self::MODE_CFB:
3200 // cfb loosely routines inspired by openssl's:
3201 // {@link http://cvs.openssl.org/fileview?f=openssl/crypto/modes/cfb128.c&v=1.3.2.2.2.1}
3202 if ($this->continuousBuffer) {
3203@@ -806,7 +892,7 @@
3204 $pos = $len;
3205 }
3206 break;
3207- case CRYPT_MODE_OFB:
3208+ case self::MODE_OFB:
3209 $xor = $this->encryptIV;
3210 if (strlen($buffer['xor'])) {
3211 for ($i = 0; $i < strlen($plaintext); $i+=$block_size) {
3212@@ -815,7 +901,7 @@
3213 $xor = $this->_encryptBlock($xor);
3214 $buffer['xor'].= $xor;
3215 }
3216- $key = $this->_stringShift($buffer['xor'], $block_size);
3217+ $key = $this->_string_shift($buffer['xor'], $block_size);
3218 $ciphertext.= $block ^ $key;
3219 }
3220 } else {
3221@@ -832,7 +918,7 @@
3222 }
3223 }
3224 break;
3225- case CRYPT_MODE_STREAM:
3226+ case self::MODE_STREAM:
3227 $ciphertext = $this->_encryptBlock($plaintext);
3228 break;
3229 }
3230@@ -846,16 +932,101 @@
3231 * If strlen($ciphertext) is not a multiple of the block size, null bytes will be added to the end of the string until
3232 * it is.
3233 *
3234- * Note: Could, but not must, extend by the child Crypt_* class
3235- *
3236- * @see Crypt_Base::encrypt()
3237+ * @see \phpseclib\Crypt\Base::encrypt()
3238 * @access public
3239 * @param String $ciphertext
3240 * @return String $plaintext
3241+ * @internal Could, but not must, extend by the child Crypt_* class
3242 */
3243 function decrypt($ciphertext)
3244 {
3245- if ($this->engine == CRYPT_MODE_MCRYPT) {
3246+ if ($this->paddable) {
3247+ // we pad with chr(0) since that's what mcrypt_generic does. to quote from {@link http://www.php.net/function.mcrypt-generic}:
3248+ // "The data is padded with "\0" to make sure the length of the data is n * blocksize."
3249+ $ciphertext = str_pad($ciphertext, strlen($ciphertext) + ($this->block_size - strlen($ciphertext) % $this->block_size) % $this->block_size, chr(0));
3250+ }
3251+
3252+ if ($this->engine === self::ENGINE_OPENSSL) {
3253+ if ($this->changed) {
3254+ $this->_clearBuffers();
3255+ $this->changed = false;
3256+ }
3257+ switch ($this->mode) {
3258+ case self::MODE_STREAM:
3259+ $plaintext = openssl_decrypt($ciphertext, $this->cipher_name_openssl, $this->key, $this->openssl_options);
3260+ break;
3261+ case self::MODE_ECB:
3262+ if (!defined('OPENSSL_RAW_DATA')) {
3263+ $ciphetext.= openssl_encrypt('', $this->cipher_name_openssl_ecb, $this->key, true);
3264+ }
3265+ $plaintext = openssl_decrypt($ciphertext, $this->cipher_name_openssl, $this->key, $this->openssl_options);
3266+ break;
3267+ case self::MODE_CBC:
3268+ if (!defined('OPENSSL_RAW_DATA')) {
3269+ $padding = str_repeat(chr($this->block_size), $this->block_size) ^ substr($ciphertext, -$this->block_size);
3270+ $ciphertext.= substr(openssl_encrypt($padding, $this->cipher_name_openssl_ecb, $this->key, true), 0, $this->block_size);
3271+ }
3272+ $plaintext = openssl_decrypt($ciphertext, $this->cipher_name_openssl, $this->key, $this->openssl_options, $this->decryptIV);
3273+ if ($this->continuousBuffer) {
3274+ $this->decryptIV = substr($ciphertext, -$this->block_size);
3275+ }
3276+ break;
3277+ case self::MODE_CTR:
3278+ $plaintext = $this->_openssl_ctr_process($ciphertext, $this->decryptIV, $this->debuffer);
3279+ break;
3280+ case self::MODE_CFB:
3281+ // cfb loosely routines inspired by openssl's:
3282+ // {@link http://cvs.openssl.org/fileview?f=openssl/crypto/modes/cfb128.c&v=1.3.2.2.2.1}
3283+ $plaintext = '';
3284+ if ($this->continuousBuffer) {
3285+ $iv = &$this->decryptIV;
3286+ $pos = &$this->buffer['pos'];
3287+ } else {
3288+ $iv = $this->decryptIV;
3289+ $pos = 0;
3290+ }
3291+ $len = strlen($ciphertext);
3292+ $i = 0;
3293+ if ($pos) {
3294+ $orig_pos = $pos;
3295+ $max = $this->block_size - $pos;
3296+ if ($len >= $max) {
3297+ $i = $max;
3298+ $len-= $max;
3299+ $pos = 0;
3300+ } else {
3301+ $i = $len;
3302+ $pos+= $len;
3303+ $len = 0;
3304+ }
3305+ // ie. $i = min($max, $len), $len-= $i, $pos+= $i, $pos%= $this->blocksize
3306+ $plaintext = substr($iv, $orig_pos) ^ $ciphertext;
3307+ $iv = substr_replace($iv, substr($ciphertext, 0, $i), $orig_pos, $i);
3308+ $ciphertext = substr($ciphertext, $i);
3309+ }
3310+ $overflow = $len % $this->block_size;
3311+ if ($overflow) {
3312+ $plaintext.= openssl_decrypt(substr($ciphertext, 0, -$overflow), $this->cipher_name_openssl, $this->key, $this->openssl_options, $iv);
3313+ if ($len - $overflow) {
3314+ $iv = substr($ciphertext, -$overflow - $this->block_size, -$overflow);
3315+ }
3316+ $iv = openssl_encrypt(str_repeat("\0", $this->block_size), $this->cipher_name_openssl, $this->key, $this->openssl_options, $iv);
3317+ $plaintext.= $iv ^ substr($ciphertext, -$overflow);
3318+ $iv = substr_replace($iv, substr($ciphertext, -$overflow), 0, $overflow);
3319+ $pos = $overflow;
3320+ } elseif ($len) {
3321+ $plaintext.= openssl_decrypt($ciphertext, $this->cipher_name_openssl, $this->key, $this->openssl_options, $iv);
3322+ $iv = substr($ciphertext, -$this->block_size);
3323+ }
3324+ break;
3325+ case self::MODE_OFB:
3326+ $plaintext = $this->_openssl_ofb_process($ciphertext, $this->decryptIV, $this->debuffer);
3327+ }
3328+
3329+ return $this->paddable ? $this->_unpad($plaintext) : $plaintext;
3330+ }
3331+
3332+ if ($this->engine === self::ENGINE_MCRYPT) {
3333 $block_size = $this->block_size;
3334 if ($this->changed) {
3335 $this->_setupMcrypt();
3336@@ -866,7 +1037,7 @@
3337 $this->dechanged = false;
3338 }
3339
3340- if ($this->mode == CRYPT_MODE_CFB && $this->continuousBuffer) {
3341+ if ($this->mode == self::MODE_CFB && $this->continuousBuffer) {
3342 $iv = &$this->decryptIV;
3343 $pos = &$this->debuffer['pos'];
3344 $len = strlen($ciphertext);
3345@@ -904,12 +1075,6 @@
3346 return $plaintext;
3347 }
3348
3349- if ($this->paddable) {
3350- // we pad with chr(0) since that's what mcrypt_generic does. to quote from {@link http://www.php.net/function.mcrypt-generic}:
3351- // "The data is padded with "\0" to make sure the length of the data is n * blocksize."
3352- $ciphertext = str_pad($ciphertext, strlen($ciphertext) + ($block_size - strlen($ciphertext) % $block_size) % $block_size, chr(0));
3353- }
3354-
3355 $plaintext = mdecrypt_generic($this->demcrypt, $ciphertext);
3356
3357 if (!$this->continuousBuffer) {
3358@@ -929,20 +1094,16 @@
3359 }
3360
3361 $block_size = $this->block_size;
3362- if ($this->paddable) {
3363- // we pad with chr(0) since that's what mcrypt_generic does [...]
3364- $ciphertext = str_pad($ciphertext, strlen($ciphertext) + ($block_size - strlen($ciphertext) % $block_size) % $block_size, chr(0));
3365- }
3366
3367 $buffer = &$this->debuffer;
3368 $plaintext = '';
3369 switch ($this->mode) {
3370- case CRYPT_MODE_ECB:
3371+ case self::MODE_ECB:
3372 for ($i = 0; $i < strlen($ciphertext); $i+=$block_size) {
3373 $plaintext.= $this->_decryptBlock(substr($ciphertext, $i, $block_size));
3374 }
3375 break;
3376- case CRYPT_MODE_CBC:
3377+ case self::MODE_CBC:
3378 $xor = $this->decryptIV;
3379 for ($i = 0; $i < strlen($ciphertext); $i+=$block_size) {
3380 $block = substr($ciphertext, $i, $block_size);
3381@@ -953,21 +1114,23 @@
3382 $this->decryptIV = $xor;
3383 }
3384 break;
3385- case CRYPT_MODE_CTR:
3386+ case self::MODE_CTR:
3387 $xor = $this->decryptIV;
3388 if (strlen($buffer['ciphertext'])) {
3389 for ($i = 0; $i < strlen($ciphertext); $i+=$block_size) {
3390 $block = substr($ciphertext, $i, $block_size);
3391 if (strlen($block) > strlen($buffer['ciphertext'])) {
3392- $buffer['ciphertext'].= $this->_encryptBlock($this->_generateXor($xor, $block_size));
3393+ $buffer['ciphertext'].= $this->_encryptBlock($xor);
3394+ $this->_increment_str($xor);
3395 }
3396- $key = $this->_stringShift($buffer['ciphertext'], $block_size);
3397+ $key = $this->_string_shift($buffer['ciphertext'], $block_size);
3398 $plaintext.= $block ^ $key;
3399 }
3400 } else {
3401 for ($i = 0; $i < strlen($ciphertext); $i+=$block_size) {
3402 $block = substr($ciphertext, $i, $block_size);
3403- $key = $this->_encryptBlock($this->_generateXor($xor, $block_size));
3404+ $key = $this->_encryptBlock($xor);
3405+ $this->_increment_str($xor);
3406 $plaintext.= $block ^ $key;
3407 }
3408 }
3409@@ -978,7 +1141,7 @@
3410 }
3411 }
3412 break;
3413- case CRYPT_MODE_CFB:
3414+ case self::MODE_CFB:
3415 if ($this->continuousBuffer) {
3416 $iv = &$this->decryptIV;
3417 $pos = &$buffer['pos'];
3418@@ -1019,7 +1182,7 @@
3419 $pos = $len;
3420 }
3421 break;
3422- case CRYPT_MODE_OFB:
3423+ case self::MODE_OFB:
3424 $xor = $this->decryptIV;
3425 if (strlen($buffer['xor'])) {
3426 for ($i = 0; $i < strlen($ciphertext); $i+=$block_size) {
3427@@ -1028,7 +1191,7 @@
3428 $xor = $this->_encryptBlock($xor);
3429 $buffer['xor'].= $xor;
3430 }
3431- $key = $this->_stringShift($buffer['xor'], $block_size);
3432+ $key = $this->_string_shift($buffer['xor'], $block_size);
3433 $plaintext.= $block ^ $key;
3434 }
3435 } else {
3436@@ -1045,7 +1208,7 @@
3437 }
3438 }
3439 break;
3440- case CRYPT_MODE_STREAM:
3441+ case self::MODE_STREAM:
3442 $plaintext = $this->_decryptBlock($ciphertext);
3443 break;
3444 }
3445@@ -1053,6 +1216,178 @@
3446 }
3447
3448 /**
3449+ * OpenSSL CTR Processor
3450+ *
3451+ * PHP's OpenSSL bindings do not operate in continuous mode so we'll wrap around it. Since the keystream
3452+ * for CTR is the same for both encrypting and decrypting this function is re-used by both Crypt_Base::encrypt()
3453+ * and Crypt_Base::decrypt(). Also, OpenSSL doesn't implement CTR for all of it's symmetric ciphers so this
3454+ * function will emulate CTR with ECB when necesary.
3455+ *
3456+ * @see Crypt_Base::encrypt()
3457+ * @see Crypt_Base::decrypt()
3458+ * @param String $plaintext
3459+ * @param String $encryptIV
3460+ * @param Array $buffer
3461+ * @return String
3462+ * @access private
3463+ */
3464+ function _openssl_ctr_process($plaintext, &$encryptIV, &$buffer)
3465+ {
3466+ $ciphertext = '';
3467+
3468+ $block_size = $this->block_size;
3469+ $key = $this->key;
3470+
3471+ if ($this->openssl_emulate_ctr) {
3472+ $xor = $encryptIV;
3473+ if (strlen($buffer['ciphertext'])) {
3474+ for ($i = 0; $i < strlen($plaintext); $i+=$block_size) {
3475+ $block = substr($plaintext, $i, $block_size);
3476+ if (strlen($block) > strlen($buffer['ciphertext'])) {
3477+ $result = openssl_encrypt($xor, $this->cipher_name_openssl_ecb, $key, $this->openssl_options);
3478+ $result = !defined('OPENSSL_RAW_DATA') ? substr($result, 0, -$this->block_size) : $result;
3479+ $buffer['ciphertext'].= $result;
3480+ }
3481+ $this->_increment_str($xor);
3482+ $otp = $this->_string_shift($buffer['ciphertext'], $block_size);
3483+ $ciphertext.= $block ^ $otp;
3484+ }
3485+ } else {
3486+ for ($i = 0; $i < strlen($plaintext); $i+=$block_size) {
3487+ $block = substr($plaintext, $i, $block_size);
3488+ $otp = openssl_encrypt($xor, $this->cipher_name_openssl_ecb, $key, $this->openssl_options);
3489+ $otp = !defined('OPENSSL_RAW_DATA') ? substr($otp, 0, -$this->block_size) : $otp;
3490+ $this->_increment_str($xor);
3491+ $ciphertext.= $block ^ $otp;
3492+ }
3493+ }
3494+ if ($this->continuousBuffer) {
3495+ $encryptIV = $xor;
3496+ if ($start = strlen($plaintext) % $block_size) {
3497+ $buffer['ciphertext'] = substr($key, $start) . $buffer['ciphertext'];
3498+ }
3499+ }
3500+
3501+ return $ciphertext;
3502+ }
3503+
3504+ if (strlen($buffer['ciphertext'])) {
3505+ $ciphertext = $plaintext ^ $this->_string_shift($buffer['ciphertext'], strlen($plaintext));
3506+ $plaintext = substr($plaintext, strlen($ciphertext));
3507+
3508+ if (!strlen($plaintext)) {
3509+ return $ciphertext;
3510+ }
3511+ }
3512+
3513+ $overflow = strlen($plaintext) % $block_size;
3514+ if ($overflow) {
3515+ $plaintext2 = $this->_string_pop($plaintext, $overflow); // ie. trim $plaintext to a multiple of $block_size and put rest of $plaintext in $plaintext2
3516+ $encrypted = openssl_encrypt($plaintext . str_repeat("\0", $block_size), $this->cipher_name_openssl, $key, $this->openssl_options, $encryptIV);
3517+ $temp = $this->_string_pop($encrypted, $block_size);
3518+ $ciphertext.= $encrypted . ($plaintext2 ^ $temp);
3519+ if ($this->continuousBuffer) {
3520+ $buffer['ciphertext'] = substr($temp, $overflow);
3521+ $encryptIV = $temp;
3522+ }
3523+ } elseif (!strlen($buffer['ciphertext'])) {
3524+ $ciphertext.= openssl_encrypt($plaintext . str_repeat("\0", $block_size), $this->cipher_name_openssl, $key, $this->openssl_options, $encryptIV);
3525+ $temp = $this->_string_pop($ciphertext, $block_size);
3526+ if ($this->continuousBuffer) {
3527+ $encryptIV = $temp;
3528+ }
3529+ }
3530+ if ($this->continuousBuffer) {
3531+ if (!defined('OPENSSL_RAW_DATA')) {
3532+ $encryptIV.= openssl_encrypt('', $this->cipher_name_openssl_ecb, $key, $this->openssl_options);
3533+ }
3534+ $encryptIV = openssl_decrypt($encryptIV, $this->cipher_name_openssl_ecb, $key, $this->openssl_options);
3535+ if ($overflow) {
3536+ $this->_increment_str($encryptIV);
3537+ }
3538+ }
3539+
3540+ return $ciphertext;
3541+ }
3542+
3543+ /**
3544+ * OpenSSL OFB Processor
3545+ *
3546+ * PHP's OpenSSL bindings do not operate in continuous mode so we'll wrap around it. Since the keystream
3547+ * for OFB is the same for both encrypting and decrypting this function is re-used by both Crypt_Base::encrypt()
3548+ * and Crypt_Base::decrypt().
3549+ *
3550+ * @see Crypt_Base::encrypt()
3551+ * @see Crypt_Base::decrypt()
3552+ * @param String $plaintext
3553+ * @param String $encryptIV
3554+ * @param Array $buffer
3555+ * @return String
3556+ * @access private
3557+ */
3558+ function _openssl_ofb_process($plaintext, &$encryptIV, &$buffer)
3559+ {
3560+ if (strlen($buffer['xor'])) {
3561+ $ciphertext = $plaintext ^ $buffer['xor'];
3562+ $buffer['xor'] = substr($buffer['xor'], strlen($ciphertext));
3563+ $plaintext = substr($plaintext, strlen($ciphertext));
3564+ } else {
3565+ $ciphertext = '';
3566+ }
3567+
3568+ $block_size = $this->block_size;
3569+
3570+ $len = strlen($plaintext);
3571+ $key = $this->key;
3572+ $overflow = $len % $block_size;
3573+
3574+ if (strlen($plaintext)) {
3575+ if ($overflow) {
3576+ $ciphertext.= openssl_encrypt(substr($plaintext, 0, -$overflow) . str_repeat("\0", $block_size), $this->cipher_name_openssl, $key, $this->openssl_options, $encryptIV);
3577+ $xor = $this->_string_pop($ciphertext, $block_size);
3578+ if ($this->continuousBuffer) {
3579+ $encryptIV = $xor;
3580+ }
3581+ $ciphertext.= $this->_string_shift($xor, $overflow) ^ substr($plaintext, -$overflow);
3582+ if ($this->continuousBuffer) {
3583+ $buffer['xor'] = $xor;
3584+ }
3585+ } else {
3586+ $ciphertext = openssl_encrypt($plaintext, $this->cipher_name_openssl, $key, $this->openssl_options, $encryptIV);
3587+ if ($this->continuousBuffer) {
3588+ $encryptIV = substr($ciphertext, -$block_size) ^ substr($plaintext, -$block_size);
3589+ }
3590+ }
3591+ }
3592+
3593+ return $ciphertext;
3594+ }
3595+
3596+ /**
3597+ * phpseclib <-> OpenSSL Mode Mapper
3598+ *
3599+ * May need to be overwritten by classes extending this one in some cases
3600+ *
3601+ * @return Integer
3602+ * @access private
3603+ */
3604+ function _openssl_translate_mode()
3605+ {
3606+ switch ($this->mode) {
3607+ case self::MODE_ECB:
3608+ return 'ecb';
3609+ case self::MODE_CBC:
3610+ return 'cbc';
3611+ case self::MODE_CTR:
3612+ return 'ctr';
3613+ case self::MODE_CFB:
3614+ return 'cfb';
3615+ case self::MODE_OFB:
3616+ return 'ofb';
3617+ }
3618+ }
3619+
3620+ /**
3621 * Pad "packets".
3622 *
3623 * Block ciphers working by encrypting between their specified [$this->]block_size at a time
3624@@ -1064,7 +1399,7 @@
3625 * away characters that shouldn't be stripped away. (SSH knows how many bytes are added because the length is
3626 * transmitted separately)
3627 *
3628- * @see Crypt_Base::disablePadding()
3629+ * @see \phpseclib\Crypt\Base::disablePadding()
3630 * @access public
3631 */
3632 function enablePadding()
3633@@ -1075,7 +1410,7 @@
3634 /**
3635 * Do not pad packets.
3636 *
3637- * @see Crypt_Base::enablePadding()
3638+ * @see \phpseclib\Crypt\Base::enablePadding()
3639 * @access public
3640 */
3641 function disablePadding()
3642@@ -1112,23 +1447,24 @@
3643 * outputs. The reason is due to the fact that the initialization vector's change after every encryption /
3644 * decryption round when the continuous buffer is enabled. When it's disabled, they remain constant.
3645 *
3646- * Put another way, when the continuous buffer is enabled, the state of the Crypt_*() object changes after each
3647+ * Put another way, when the continuous buffer is enabled, the state of the \phpseclib\Crypt\*() object changes after each
3648 * encryption / decryption round, whereas otherwise, it'd remain constant. For this reason, it's recommended that
3649 * continuous buffers not be used. They do offer better security and are, in fact, sometimes required (SSH uses them),
3650 * however, they are also less intuitive and more likely to cause you problems.
3651 *
3652- * Note: Could, but not must, extend by the child Crypt_* class
3653- *
3654- * @see Crypt_Base::disableContinuousBuffer()
3655+ * @see \phpseclib\Crypt\Base::disableContinuousBuffer()
3656 * @access public
3657+ * @internal Could, but not must, extend by the child Crypt_* class
3658 */
3659 function enableContinuousBuffer()
3660 {
3661- if ($this->mode == CRYPT_MODE_ECB) {
3662+ if ($this->mode == self::MODE_ECB) {
3663 return;
3664 }
3665
3666 $this->continuousBuffer = true;
3667+
3668+ $this->_setEngine();
3669 }
3670
3671 /**
3672@@ -1136,14 +1472,13 @@
3673 *
3674 * The default behavior.
3675 *
3676- * Note: Could, but not must, extend by the child Crypt_* class
3677- *
3678- * @see Crypt_Base::enableContinuousBuffer()
3679+ * @see \phpseclib\Crypt\Base::enableContinuousBuffer()
3680 * @access public
3681+ * @internal Could, but not must, extend by the child Crypt_* class
3682 */
3683 function disableContinuousBuffer()
3684 {
3685- if ($this->mode == CRYPT_MODE_ECB) {
3686+ if ($this->mode == self::MODE_ECB) {
3687 return;
3688 }
3689 if (!$this->continuousBuffer) {
3690@@ -1152,56 +1487,191 @@
3691
3692 $this->continuousBuffer = false;
3693 $this->changed = true;
3694+
3695+ $this->_setEngine();
3696+ }
3697+
3698+ /**
3699+ * Test for engine validity
3700+ *
3701+ * @see \phpseclib\Crypt\Base::Crypt_Base()
3702+ * @param Integer $engine
3703+ * @access public
3704+ * @return Boolean
3705+ */
3706+ function isValidEngine($engine)
3707+ {
3708+ switch ($engine) {
3709+ case self::ENGINE_OPENSSL:
3710+ if ($this->mode == self::MODE_STREAM && $this->continuousBuffer) {
3711+ return false;
3712+ }
3713+ $this->openssl_emulate_ctr = false;
3714+ $result = $this->cipher_name_openssl &&
3715+ extension_loaded('openssl') &&
3716+ // PHP 5.3.0 - 5.3.2 did not let you set IV's
3717+ version_compare(PHP_VERSION, '5.3.3', '>=');
3718+ if (!$result) {
3719+ return false;
3720+ }
3721+
3722+ // prior to PHP 5.4.0 OPENSSL_RAW_DATA and OPENSSL_ZERO_PADDING were not defined. instead of expecting an integer
3723+ // $options openssl_encrypt expected a boolean $raw_data.
3724+ if (!defined('OPENSSL_RAW_DATA')) {
3725+ $this->openssl_options = true;
3726+ } else {
3727+ $this->openssl_options = OPENSSL_RAW_DATA | OPENSSL_ZERO_PADDING;
3728+ }
3729+
3730+ $methods = openssl_get_cipher_methods();
3731+ if (in_array($this->cipher_name_openssl, $methods)) {
3732+ return true;
3733+ }
3734+ // not all of openssl's symmetric cipher's support ctr. for those
3735+ // that don't we'll emulate it
3736+ switch ($this->mode) {
3737+ case self::MODE_CTR:
3738+ if (in_array($this->cipher_name_openssl_ecb, $methods)) {
3739+ $this->openssl_emulate_ctr = true;
3740+ return true;
3741+ }
3742+ }
3743+ return false;
3744+ case self::ENGINE_MCRYPT:
3745+ return $this->cipher_name_mcrypt &&
3746+ extension_loaded('mcrypt') &&
3747+ in_array($this->cipher_name_mcrypt, mcrypt_list_algorithms());
3748+ case self::ENGINE_INTERNAL:
3749+ return true;
3750+ }
3751+
3752+ return false;
3753+ }
3754+
3755+ /**
3756+ * Sets the preferred crypt engine
3757+ *
3758+ * Currently, $engine could be:
3759+ *
3760+ * - \phpseclib\Crypt\Base::ENGINE_OPENSSL [very fast]
3761+ *
3762+ * - \phpseclib\Crypt\Base::ENGINE_MCRYPT [fast]
3763+ *
3764+ * - \phpseclib\Crypt\Base::ENGINE_INTERNAL [slow]
3765+ *
3766+ * If the preferred crypt engine is not available the fastest available one will be used
3767+ *
3768+ * @see \phpseclib\Crypt\Base::Crypt_Base()
3769+ * @param Integer $engine
3770+ * @access public
3771+ */
3772+ function setPreferredEngine($engine)
3773+ {
3774+ switch ($engine) {
3775+ //case self::ENGINE_OPENSSL;
3776+ case self::ENGINE_MCRYPT:
3777+ case self::ENGINE_INTERNAL:
3778+ $this->preferredEngine = $engine;
3779+ break;
3780+ default:
3781+ $this->preferredEngine = self::ENGINE_OPENSSL;
3782+ }
3783+
3784+ $this->_setEngine();
3785+ }
3786+
3787+ /**
3788+ * Returns the engine currently being utilized
3789+ *
3790+ * @see \phpseclib\Crypt\Base::_setEngine()
3791+ * @access public
3792+ */
3793+ function getEngine()
3794+ {
3795+ return $this->engine;
3796+ }
3797+
3798+ /**
3799+ * Sets the engine as appropriate
3800+ *
3801+ * @see \phpseclib\Crypt\Base::Crypt_Base()
3802+ * @access private
3803+ */
3804+ function _setEngine()
3805+ {
3806+ $this->engine = null;
3807+
3808+ $candidateEngines = array(
3809+ $this->preferredEngine,
3810+ self::ENGINE_OPENSSL,
3811+ self::ENGINE_MCRYPT
3812+ );
3813+ foreach ($candidateEngines as $engine) {
3814+ if ($this->isValidEngine($engine)) {
3815+ $this->engine = $engine;
3816+ break;
3817+ }
3818+ }
3819+ if (!$this->engine) {
3820+ $this->engine = self::ENGINE_INTERNAL;
3821+ }
3822+
3823+ if ($this->engine != self::ENGINE_MCRYPT && $this->enmcrypt) {
3824+ // Closing the current mcrypt resource(s). _mcryptSetup() will, if needed,
3825+ // (re)open them with the module named in $this->cipher_name_mcrypt
3826+ mcrypt_module_close($this->enmcrypt);
3827+ mcrypt_module_close($this->demcrypt);
3828+ $this->enmcrypt = null;
3829+ $this->demcrypt = null;
3830+
3831+ if ($this->ecb) {
3832+ mcrypt_module_close($this->ecb);
3833+ $this->ecb = null;
3834+ }
3835+ }
3836+
3837+ $this->changed = true;
3838 }
3839
3840 /**
3841 * Encrypts a block
3842 *
3843- * Note: Must extend by the child Crypt_* class
3844+ * Note: Must be extended by the child \phpseclib\Crypt\* class
3845 *
3846 * @access private
3847 * @param String $in
3848 * @return String
3849 */
3850- function _encryptBlock($in)
3851- {
3852- user_error((version_compare(PHP_VERSION, '5.0.0', '>=') ? __METHOD__ : __FUNCTION__) . '() must extend by class ' . get_class($this), E_USER_ERROR);
3853- }
3854+ abstract function _encryptBlock($in);
3855
3856 /**
3857 * Decrypts a block
3858 *
3859- * Note: Must extend by the child Crypt_* class
3860+ * Note: Must be extended by the child \phpseclib\Crypt\* class
3861 *
3862 * @access private
3863 * @param String $in
3864 * @return String
3865 */
3866- function _decryptBlock($in)
3867- {
3868- user_error((version_compare(PHP_VERSION, '5.0.0', '>=') ? __METHOD__ : __FUNCTION__) . '() must extend by class ' . get_class($this), E_USER_ERROR);
3869- }
3870+ abstract function _decryptBlock($in);
3871
3872 /**
3873 * Setup the key (expansion)
3874 *
3875- * Only used if $engine == CRYPT_MODE_INTERNAL
3876- *
3877- * Note: Must extend by the child Crypt_* class
3878- *
3879- * @see Crypt_Base::_setup()
3880+ * Only used if $engine == self::ENGINE_INTERNAL
3881+ *
3882+ * Note: Must extend by the child \phpseclib\Crypt\* class
3883+ *
3884+ * @see \phpseclib\Crypt\Base::_setup()
3885 * @access private
3886 */
3887- function _setupKey()
3888- {
3889- user_error((version_compare(PHP_VERSION, '5.0.0', '>=') ? __METHOD__ : __FUNCTION__) . '() must extend by class ' . get_class($this), E_USER_ERROR);
3890- }
3891+ abstract function _setupKey();
3892
3893 /**
3894- * Setup the CRYPT_MODE_INTERNAL $engine
3895+ * Setup the self::ENGINE_INTERNAL $engine
3896 *
3897 * (re)init, if necessary, the internal cipher $engine and flush all $buffers
3898- * Used (only) if $engine == CRYPT_MODE_INTERNAL
3899+ * Used (only) if $engine == self::ENGINE_INTERNAL
3900 *
3901 * _setup() will be called each time if $changed === true
3902 * typically this happens when using one or more of following public methods:
3903@@ -1214,14 +1684,12 @@
3904 *
3905 * - First run of encrypt() / decrypt() with no init-settings
3906 *
3907- * Internally: _setup() is called always before(!) en/decryption.
3908- *
3909- * Note: Could, but not must, extend by the child Crypt_* class
3910- *
3911 * @see setKey()
3912 * @see setIV()
3913 * @see disableContinuousBuffer()
3914 * @access private
3915+ * @internal _setup() is always called before en/decryption.
3916+ * @internal Could, but not must, extend by the child Crypt_* class
3917 */
3918 function _setup()
3919 {
3920@@ -1234,10 +1702,10 @@
3921 }
3922
3923 /**
3924- * Setup the CRYPT_MODE_MCRYPT $engine
3925+ * Setup the self::ENGINE_MCRYPT $engine
3926 *
3927 * (re)init, if necessary, the (ext)mcrypt resources and flush all $buffers
3928- * Used (only) if $engine = CRYPT_MODE_MCRYPT
3929+ * Used (only) if $engine = self::ENGINE_MCRYPT
3930 *
3931 * _setupMcrypt() will be called each time if $changed === true
3932 * typically this happens when using one or more of following public methods:
3933@@ -1250,13 +1718,11 @@
3934 *
3935 * - First run of encrypt() / decrypt()
3936 *
3937- *
3938- * Note: Could, but not must, extend by the child Crypt_* class
3939- *
3940 * @see setKey()
3941 * @see setIV()
3942 * @see disableContinuousBuffer()
3943 * @access private
3944+ * @internal Could, but not must, extend by the child Crypt_* class
3945 */
3946 function _setupMcrypt()
3947 {
3948@@ -1265,12 +1731,12 @@
3949
3950 if (!isset($this->enmcrypt)) {
3951 static $mcrypt_modes = array(
3952- CRYPT_MODE_CTR => 'ctr',
3953- CRYPT_MODE_ECB => MCRYPT_MODE_ECB,
3954- CRYPT_MODE_CBC => MCRYPT_MODE_CBC,
3955- CRYPT_MODE_CFB => 'ncfb',
3956- CRYPT_MODE_OFB => MCRYPT_MODE_NOFB,
3957- CRYPT_MODE_STREAM => MCRYPT_MODE_STREAM,
3958+ self::MODE_CTR => 'ctr',
3959+ self::MODE_ECB => MCRYPT_MODE_ECB,
3960+ self::MODE_CBC => MCRYPT_MODE_CBC,
3961+ self::MODE_CFB => 'ncfb',
3962+ self::MODE_OFB => MCRYPT_MODE_NOFB,
3963+ self::MODE_STREAM => MCRYPT_MODE_STREAM,
3964 );
3965
3966 $this->demcrypt = mcrypt_module_open($this->cipher_name_mcrypt, '', $mcrypt_modes[$this->mode], '');
3967@@ -1279,13 +1745,13 @@
3968 // we need the $ecb mcrypt resource (only) in MODE_CFB with enableContinuousBuffer()
3969 // to workaround mcrypt's broken ncfb implementation in buffered mode
3970 // see: {@link http://phpseclib.sourceforge.net/cfb-demo.phps}
3971- if ($this->mode == CRYPT_MODE_CFB) {
3972+ if ($this->mode == self::MODE_CFB) {
3973 $this->ecb = mcrypt_module_open($this->cipher_name_mcrypt, '', MCRYPT_MODE_ECB, '');
3974 }
3975
3976 } // else should mcrypt_generic_deinit be called?
3977
3978- if ($this->mode == CRYPT_MODE_CFB) {
3979+ if ($this->mode == self::MODE_CFB) {
3980 mcrypt_generic_init($this->ecb, $this->key, str_repeat("\0", $this->block_size));
3981 }
3982 }
3983@@ -1300,7 +1766,7 @@
3984 * If padding is disabled and $text is not a multiple of the blocksize, the string will be padded regardless
3985 * and padding will, hence forth, be enabled.
3986 *
3987- * @see Crypt_Base::_unpad()
3988+ * @see \phpseclib\Crypt\Base::_unpad()
3989 * @param String $text
3990 * @access private
3991 * @return String
3992@@ -1329,7 +1795,7 @@
3993 * If padding is enabled and the reported padding length is invalid the encryption key will be assumed to be wrong
3994 * and false will be returned.
3995 *
3996- * @see Crypt_Base::_pad()
3997+ * @see \phpseclib\Crypt\Base::_pad()
3998 * @param String $text
3999 * @access private
4000 * @return String
4001@@ -1356,14 +1822,12 @@
4002 * after disableContinuousBuffer() or on cipher $engine (re)init
4003 * ie after setKey() or setIV()
4004 *
4005- * Note: Could, but not must, extend by the child Crypt_* class
4006- *
4007 * @access public
4008+ * @internal Could, but not must, extend by the child Crypt_* class
4009 */
4010 function _clearBuffers()
4011 {
4012- $this->enbuffer = array('encrypted' => '', 'xor' => '', 'pos' => 0, 'enmcrypt_init' => true);
4013- $this->debuffer = array('ciphertext' => '', 'xor' => '', 'pos' => 0, 'demcrypt_init' => true);
4014+ $this->enbuffer = $this->debuffer = array('ciphertext' => '', 'xor' => '', 'pos' => 0, 'enmcrypt_init' => true);
4015
4016 // mcrypt's handling of invalid's $iv:
4017 // $this->encryptIV = $this->decryptIV = strlen($this->iv) == $this->block_size ? $this->iv : str_repeat("\0", $this->block_size);
4018@@ -1380,7 +1844,7 @@
4019 * @access private
4020 * @return String
4021 */
4022- function _stringShift(&$string, $index = 1)
4023+ function _string_shift(&$string, $index = 1)
4024 {
4025 $substr = substr($string, 0, $index);
4026 $string = substr($string, $index);
4027@@ -1388,43 +1852,57 @@
4028 }
4029
4030 /**
4031- * Generate CTR XOR encryption key
4032- *
4033- * Encrypt the output of this and XOR it against the ciphertext / plaintext to get the
4034- * plaintext / ciphertext in CTR mode.
4035- *
4036- * @see Crypt_Base::decrypt()
4037- * @see Crypt_Base::encrypt()
4038- * @param String $iv
4039- * @param Integer $length
4040- * @access private
4041- * @return String $xor
4042- */
4043- function _generateXor(&$iv, $length)
4044- {
4045- $xor = '';
4046- $block_size = $this->block_size;
4047- $num_blocks = floor(($length + ($block_size - 1)) / $block_size);
4048- for ($i = 0; $i < $num_blocks; $i++) {
4049- $xor.= $iv;
4050- for ($j = 4; $j <= $block_size; $j+= 4) {
4051- $temp = substr($iv, -$j, 4);
4052- switch ($temp) {
4053- case "\xFF\xFF\xFF\xFF":
4054- $iv = substr_replace($iv, "\x00\x00\x00\x00", -$j, 4);
4055- break;
4056- case "\x7F\xFF\xFF\xFF":
4057- $iv = substr_replace($iv, "\x80\x00\x00\x00", -$j, 4);
4058- break 2;
4059- default:
4060- extract(unpack('Ncount', $temp));
4061- $iv = substr_replace($iv, pack('N', $count + 1), -$j, 4);
4062- break 2;
4063- }
4064+ * String Pop
4065+ *
4066+ * Inspired by array_pop
4067+ *
4068+ * @param String $string
4069+ * @param optional Integer $index
4070+ * @access private
4071+ * @return String
4072+ */
4073+ function _string_pop(&$string, $index = 1)
4074+ {
4075+ $substr = substr($string, -$index);
4076+ $string = substr($string, 0, -$index);
4077+ return $substr;
4078+ }
4079+
4080+ /**
4081+ * Increment the current string
4082+ *
4083+ * @see \phpseclib\Crypt\Base::decrypt()
4084+ * @see \phpseclib\Crypt\Base::encrypt()
4085+ * @param String $var
4086+ * @access private
4087+ */
4088+ function _increment_str(&$var)
4089+ {
4090+ for ($i = 4; $i <= strlen($var); $i+= 4) {
4091+ $temp = substr($var, -$i, 4);
4092+ switch ($temp) {
4093+ case "\xFF\xFF\xFF\xFF":
4094+ $var = substr_replace($var, "\x00\x00\x00\x00", -$i, 4);
4095+ break;
4096+ case "\x7F\xFF\xFF\xFF":
4097+ $var = substr_replace($var, "\x80\x00\x00\x00", -$i, 4);
4098+ return;
4099+ default:
4100+ $temp = unpack('Nnum', $temp);
4101+ $var = substr_replace($var, pack('N', $temp['num'] + 1), -$i, 4);
4102+ return;
4103 }
4104 }
4105
4106- return $xor;
4107+ $remainder = strlen($var) % 4;
4108+
4109+ if ($remainder == 0) {
4110+ return;
4111+ }
4112+
4113+ $temp = unpack('Nnum', str_pad(substr($var, 0, $remainder), 4, "\0", STR_PAD_LEFT));
4114+ $temp = substr(pack('N', $temp['num'] + 1), -$remainder);
4115+ $var = substr_replace($var, $temp, 0, $remainder);
4116 }
4117
4118 /**
4119@@ -1437,7 +1915,7 @@
4120 *
4121 * _setupInlineCrypt() would be called only if:
4122 *
4123- * - $engine == CRYPT_MODE_INTERNAL and
4124+ * - $engine == self::ENGINE_INTERNAL and
4125 *
4126 * - $use_inline_crypt === true
4127 *
4128@@ -1472,7 +1950,7 @@
4129 * - short (as good as possible)
4130 *
4131 * Note: - _setupInlineCrypt() is using _createInlineCryptFunction() to create the full callback function code.
4132- * - In case of using inline crypting, _setupInlineCrypt() must extend by the child Crypt_* class.
4133+ * - In case of using inline crypting, _setupInlineCrypt() must extend by the child \phpseclib\Crypt\* class.
4134 * - The following variable names are reserved:
4135 * - $_* (all variable names prefixed with an underscore)
4136 * - $self (object reference to it self. Do not use $this, but $self instead)
4137@@ -1480,19 +1958,18 @@
4138 * - The callback function should not use the 'return' statement, but en/decrypt'ing the content of $in only
4139 *
4140 *
4141- * @see Crypt_Base::_setup()
4142- * @see Crypt_Base::_createInlineCryptFunction()
4143- * @see Crypt_Base::encrypt()
4144- * @see Crypt_Base::decrypt()
4145+ * @see \phpseclib\Crypt\Base::_setup()
4146+ * @see \phpseclib\Crypt\Base::_createInlineCryptFunction()
4147+ * @see \phpseclib\Crypt\Base::encrypt()
4148+ * @see \phpseclib\Crypt\Base::decrypt()
4149 * @access private
4150+ * @internal If a Crypt_* class providing inline crypting it must extend _setupInlineCrypt()
4151 */
4152 function _setupInlineCrypt()
4153 {
4154- // If a Crypt_* class providing inline crypting it must extend _setupInlineCrypt()
4155-
4156- // If, for any reason, an extending Crypt_Base() Crypt_* class
4157+ // If, for any reason, an extending \phpseclib\Crypt\Base() \phpseclib\Crypt\* class
4158 // not using inline crypting then it must be ensured that: $this->use_inline_crypt = false
4159- // ie in the class var declaration of $use_inline_crypt in general for the Crypt_* class,
4160+ // ie in the class var declaration of $use_inline_crypt in general for the \phpseclib\Crypt\* class,
4161 // in the constructor at object instance-time
4162 // or, if it's runtime-specific, at runtime
4163
4164@@ -1589,7 +2066,7 @@
4165 * +----------------------------------------------------------------------------------------------+
4166 * </code>
4167 *
4168- * See also the Crypt_*::_setupInlineCrypt()'s for
4169+ * See also the \phpseclib\Crypt\*::_setupInlineCrypt()'s for
4170 * productive inline $cipher_code's how they works.
4171 *
4172 * Structure of:
4173@@ -1603,9 +2080,9 @@
4174 * );
4175 * </code>
4176 *
4177- * @see Crypt_Base::_setupInlineCrypt()
4178- * @see Crypt_Base::encrypt()
4179- * @see Crypt_Base::decrypt()
4180+ * @see \phpseclib\Crypt\Base::_setupInlineCrypt()
4181+ * @see \phpseclib\Crypt\Base::encrypt()
4182+ * @see \phpseclib\Crypt\Base::decrypt()
4183 * @param Array $cipher_code
4184 * @access private
4185 * @return String (the name of the created callback function)
4186@@ -1626,10 +2103,9 @@
4187 // merged with the $cipher_code algorithm
4188 // for encrypt- and decryption.
4189 switch ($this->mode) {
4190- case CRYPT_MODE_ECB:
4191+ case self::MODE_ECB:
4192 $encrypt = $init_encrypt . '
4193 $_ciphertext = "";
4194- $_text = $self->_pad($_text);
4195 $_plaintext_len = strlen($_text);
4196
4197 for ($_i = 0; $_i < $_plaintext_len; $_i+= '.$block_size.') {
4198@@ -1655,29 +2131,30 @@
4199 return $self->_unpad($_plaintext);
4200 ';
4201 break;
4202- case CRYPT_MODE_CTR:
4203+ case self::MODE_CTR:
4204 $encrypt = $init_encrypt . '
4205 $_ciphertext = "";
4206 $_plaintext_len = strlen($_text);
4207 $_xor = $self->encryptIV;
4208 $_buffer = &$self->enbuffer;
4209-
4210- if (strlen($_buffer["encrypted"])) {
4211+ if (strlen($_buffer["ciphertext"])) {
4212 for ($_i = 0; $_i < $_plaintext_len; $_i+= '.$block_size.') {
4213 $_block = substr($_text, $_i, '.$block_size.');
4214- if (strlen($_block) > strlen($_buffer["encrypted"])) {
4215- $in = $self->_generateXor($_xor, '.$block_size.');
4216+ if (strlen($_block) > strlen($_buffer["ciphertext"])) {
4217+ $in = $_xor;
4218 '.$encrypt_block.'
4219- $_buffer["encrypted"].= $in;
4220+ $self->_increment_str($_xor);
4221+ $_buffer["ciphertext"].= $in;
4222 }
4223- $_key = $self->_stringShift($_buffer["encrypted"], '.$block_size.');
4224+ $_key = $self->_string_shift($_buffer["ciphertext"], '.$block_size.');
4225 $_ciphertext.= $_block ^ $_key;
4226 }
4227 } else {
4228 for ($_i = 0; $_i < $_plaintext_len; $_i+= '.$block_size.') {
4229 $_block = substr($_text, $_i, '.$block_size.');
4230- $in = $self->_generateXor($_xor, '.$block_size.');
4231+ $in = $_xor;
4232 '.$encrypt_block.'
4233+ $self->_increment_str($_xor);
4234 $_key = $in;
4235 $_ciphertext.= $_block ^ $_key;
4236 }
4237@@ -1685,7 +2162,7 @@
4238 if ($self->continuousBuffer) {
4239 $self->encryptIV = $_xor;
4240 if ($_start = $_plaintext_len % '.$block_size.') {
4241- $_buffer["encrypted"] = substr($_key, $_start) . $_buffer["encrypted"];
4242+ $_buffer["ciphertext"] = substr($_key, $_start) . $_buffer["ciphertext"];
4243 }
4244 }
4245
4246@@ -1702,18 +2179,20 @@
4247 for ($_i = 0; $_i < $_ciphertext_len; $_i+= '.$block_size.') {
4248 $_block = substr($_text, $_i, '.$block_size.');
4249 if (strlen($_block) > strlen($_buffer["ciphertext"])) {
4250- $in = $self->_generateXor($_xor, '.$block_size.');
4251+ $in = $_xor;
4252 '.$encrypt_block.'
4253+ $self->_increment_str($_xor);
4254 $_buffer["ciphertext"].= $in;
4255 }
4256- $_key = $self->_stringShift($_buffer["ciphertext"], '.$block_size.');
4257+ $_key = $self->_string_shift($_buffer["ciphertext"], '.$block_size.');
4258 $_plaintext.= $_block ^ $_key;
4259 }
4260 } else {
4261 for ($_i = 0; $_i < $_ciphertext_len; $_i+= '.$block_size.') {
4262 $_block = substr($_text, $_i, '.$block_size.');
4263- $in = $self->_generateXor($_xor, '.$block_size.');
4264+ $in = $_xor;
4265 '.$encrypt_block.'
4266+ $self->_increment_str($_xor);
4267 $_key = $in;
4268 $_plaintext.= $_block ^ $_key;
4269 }
4270@@ -1728,7 +2207,7 @@
4271 return $_plaintext;
4272 ';
4273 break;
4274- case CRYPT_MODE_CFB:
4275+ case self::MODE_CFB:
4276 $encrypt = $init_encrypt . '
4277 $_ciphertext = "";
4278 $_buffer = &$self->enbuffer;
4279@@ -1827,7 +2306,7 @@
4280 return $_plaintext;
4281 ';
4282 break;
4283- case CRYPT_MODE_OFB:
4284+ case self::MODE_OFB:
4285 $encrypt = $init_encrypt . '
4286 $_ciphertext = "";
4287 $_plaintext_len = strlen($_text);
4288@@ -1843,7 +2322,7 @@
4289 $_xor = $in;
4290 $_buffer["xor"].= $_xor;
4291 }
4292- $_key = $self->_stringShift($_buffer["xor"], '.$block_size.');
4293+ $_key = $self->_string_shift($_buffer["xor"], '.$block_size.');
4294 $_ciphertext.= $_block ^ $_key;
4295 }
4296 } else {
4297@@ -1879,7 +2358,7 @@
4298 $_xor = $in;
4299 $_buffer["xor"].= $_xor;
4300 }
4301- $_key = $self->_stringShift($_buffer["xor"], '.$block_size.');
4302+ $_key = $self->_string_shift($_buffer["xor"], '.$block_size.');
4303 $_plaintext.= $_block ^ $_key;
4304 }
4305 } else {
4306@@ -1900,7 +2379,7 @@
4307 return $_plaintext;
4308 ';
4309 break;
4310- case CRYPT_MODE_STREAM:
4311+ case self::MODE_STREAM:
4312 $encrypt = $init_encrypt . '
4313 $_ciphertext = "";
4314 '.$encrypt_block.'
4315@@ -1912,11 +2391,10 @@
4316 return $_plaintext;
4317 ';
4318 break;
4319- // case CRYPT_MODE_CBC:
4320+ // case self::MODE_CBC:
4321 default:
4322 $encrypt = $init_encrypt . '
4323 $_ciphertext = "";
4324- $_text = $self->_pad($_text);
4325 $_plaintext_len = strlen($_text);
4326
4327 $in = $self->encryptIV;
4328@@ -1974,11 +2452,46 @@
4329 * for which $mode the lambda function was created.
4330 *
4331 * @access private
4332- * @return &Array
4333+ * @return Array &$functions
4334 */
4335 function &_getLambdaFunctions()
4336 {
4337 static $functions = array();
4338 return $functions;
4339 }
4340+
4341+ /**
4342+ * Generates a digest from $bytes
4343+ *
4344+ * @see _setupInlineCrypt()
4345+ * @access private
4346+ * @param $bytes
4347+ * @return String
4348+ */
4349+ function _hashInlineCryptFunction($bytes)
4350+ {
4351+ if (!isset(self::$WHIRLPOOL_AVAILABLE)) {
4352+ self::$WHIRLPOOL_AVAILABLE = extension_loaded('hash') && in_array('whirlpool', hash_algos());
4353+ }
4354+
4355+ $result = '';
4356+ $hash = $bytes;
4357+
4358+ switch (true) {
4359+ case self::$WHIRLPOOL_AVAILABLE:
4360+ foreach (str_split($bytes, 64) as $t) {
4361+ $hash = hash('whirlpool', $hash, true);
4362+ $result .= $t ^ $hash;
4363+ }
4364+ return $result . hash('whirlpool', $hash, true);
4365+ default:
4366+ $len = strlen($bytes);
4367+ for ($i = 0; $i < $len; $i+=20) {
4368+ $t = substr($bytes, $i, 20);
4369+ $hash = pack('H*', sha1($hash));
4370+ $result .= $t ^ $hash;
4371+ }
4372+ return $result . pack('H*', sha1($hash));
4373+ }
4374+ }
4375 }
4376
4377=== modified file 'libraries/phpseclib/Crypt/Random.php'
4378--- libraries/phpseclib/Crypt/Random.php 2015-04-28 10:31:57 +0000
4379+++ libraries/phpseclib/Crypt/Random.php 2015-10-27 17:36:50 +0000
4380@@ -3,54 +3,44 @@
4381 /**
4382 * Random Number Generator
4383 *
4384- * PHP versions 4 and 5
4385+ * PHP version 5
4386 *
4387 * Here's a short example of how to use this library:
4388 * <code>
4389 * <?php
4390- * include 'Crypt/Random.php';
4391+ * include 'vendor/autoload.php';
4392 *
4393- * echo bin2hex(crypt_random_string(8));
4394+ * echo bin2hex(\phpseclib\Crypt\Random::string(8));
4395 * ?>
4396 * </code>
4397 *
4398- * LICENSE: Permission is hereby granted, free of charge, to any person obtaining a copy
4399- * of this software and associated documentation files (the "Software"), to deal
4400- * in the Software without restriction, including without limitation the rights
4401- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
4402- * copies of the Software, and to permit persons to whom the Software is
4403- * furnished to do so, subject to the following conditions:
4404- *
4405- * The above copyright notice and this permission notice shall be included in
4406- * all copies or substantial portions of the Software.
4407- *
4408- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
4409- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
4410- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
4411- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
4412- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
4413- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
4414- * THE SOFTWARE.
4415- *
4416 * @category Crypt
4417- * @package Crypt_Random
4418+ * @package Random
4419 * @author Jim Wigginton <terrafrost@php.net>
4420- * @copyright MMVII Jim Wigginton
4421+ * @copyright 2007 Jim Wigginton
4422 * @license http://www.opensource.org/licenses/mit-license.html MIT License
4423 * @link http://phpseclib.sourceforge.net
4424 */
4425
4426-// laravel is a PHP framework that utilizes phpseclib. laravel workbenches may, independently,
4427-// have phpseclib as a requirement as well. if you're developing such a program you may encounter
4428-// a "Cannot redeclare crypt_random_string()" error.
4429-if (!function_exists('crypt_random_string')) {
4430- /**
4431- * "Is Windows" test
4432- *
4433- * @access private
4434- */
4435- define('CRYPT_RANDOM_IS_WINDOWS', strtoupper(substr(PHP_OS, 0, 3)) === 'WIN');
4436-
4437+namespace phpseclib\Crypt;
4438+
4439+use phpseclib\Crypt\AES;
4440+use phpseclib\Crypt\Base;
4441+use phpseclib\Crypt\Blowfish;
4442+use phpseclib\Crypt\DES;
4443+use phpseclib\Crypt\RC4;
4444+use phpseclib\Crypt\TripleDES;
4445+use phpseclib\Crypt\Twofish;
4446+
4447+/**
4448+ * Pure-PHP Random Number Generator
4449+ *
4450+ * @package Random
4451+ * @author Jim Wigginton <terrafrost@php.net>
4452+ * @access public
4453+ */
4454+class Random
4455+{
4456 /**
4457 * Generate a random string.
4458 *
4459@@ -60,11 +50,10 @@
4460 *
4461 * @param Integer $length
4462 * @return String
4463- * @access public
4464 */
4465- function crypt_random_string($length)
4466+ public static function string($length)
4467 {
4468- if (CRYPT_RANDOM_IS_WINDOWS) {
4469+ if (strtoupper(substr(PHP_OS, 0, 3)) === 'WIN') {
4470 // method 1. prior to PHP 5.3 this would call rand() on windows hence the function_exists('class_alias') call.
4471 // ie. class_alias is a function that was introduced in PHP 5.3
4472 if (function_exists('mcrypt_create_iv') && function_exists('class_alias')) {
4473@@ -120,7 +109,7 @@
4474 // easy to guess at. linux uses mouse clicks, keyboard timings, etc, as entropy sources, but
4475 // PHP isn't low level to be able to use those as sources and on a web server there's not likely
4476 // going to be a ton of keyboard or mouse action. web servers do have one thing that we can use
4477- // however. a ton of people visiting the website. obviously you don't want to base your seeding
4478+ // however, a ton of people visiting the website. obviously you don't want to base your seeding
4479 // soley on parameters a potential attacker sends but (1) not everything in $_SERVER is controlled
4480 // by the user and (2) this isn't just looking at the data sent by the current user - it's based
4481 // on the data sent by all users. one user requests the page and a hash of their info is saved.
4482@@ -168,9 +157,9 @@
4483 ini_set('session.use_cookies', $old_use_cookies);
4484 session_cache_limiter($old_session_cache_limiter);
4485 } else {
4486- if ($_OLD_SESSION !== false) {
4487- $_SESSION = $_OLD_SESSION;
4488- unset($_OLD_SESSION);
4489+ if ($_OLD_SESSION !== false) {
4490+ $_SESSION = $_OLD_SESSION;
4491+ unset($_OLD_SESSION);
4492 } else {
4493 unset($_SESSION);
4494 }
4495@@ -191,21 +180,27 @@
4496 //
4497 // http://en.wikipedia.org/wiki/Cryptographically_secure_pseudorandom_number_generator#Designs_based_on_cryptographic_primitives
4498 switch (true) {
4499- case class_exists('Crypt_AES'):
4500- $crypto = new Crypt_AES(CRYPT_AES_MODE_CTR);
4501- break;
4502- case class_exists('Crypt_TripleDES'):
4503- $crypto = new Crypt_TripleDES(CRYPT_DES_MODE_CTR);
4504- break;
4505- case class_exists('Crypt_DES'):
4506- $crypto = new Crypt_DES(CRYPT_DES_MODE_CTR);
4507- break;
4508- case class_exists('Crypt_RC4'):
4509- $crypto = new Crypt_RC4();
4510+ case class_exists('\phpseclib\Crypt\AES'):
4511+ $crypto = new AES(Base::MODE_CTR);
4512+ break;
4513+ case class_exists('\phpseclib\Crypt\Twofish'):
4514+ $crypto = new Twofish(Base::MODE_CTR);
4515+ break;
4516+ case class_exists('\phpseclib\Crypt\Blowfish'):
4517+ $crypto = new Blowfish(Base::MODE_CTR);
4518+ break;
4519+ case class_exists('\phpseclib\Crypt\TripleDES'):
4520+ $crypto = new TripleDES(Base::MODE_CTR);
4521+ break;
4522+ case class_exists('\phpseclib\Crypt\DES'):
4523+ $crypto = new DES(Base::MODE_CTR);
4524+ break;
4525+ case class_exists('\phpseclib\Crypt\RC4'):
4526+ $crypto = new RC4();
4527 break;
4528 default:
4529- $crypto = $seed;
4530- return crypt_random_string($length);
4531+ user_error(__CLASS__ . ' requires at least one symmetric cipher be loaded');
4532+ return false;
4533 }
4534
4535 $crypto->setKey($key);
4536@@ -213,37 +208,21 @@
4537 $crypto->enableContinuousBuffer();
4538 }
4539
4540- if (is_string($crypto)) {
4541- // the following is based off of ANSI X9.31:
4542- //
4543- // http://csrc.nist.gov/groups/STM/cavp/documents/rng/931rngext.pdf
4544- //
4545- // OpenSSL uses that same standard for it's random numbers:
4546- //
4547- // http://www.opensource.apple.com/source/OpenSSL/OpenSSL-38/openssl/fips-1.0/rand/fips_rand.c
4548- // (do a search for "ANS X9.31 A.2.4")
4549- //
4550- // ANSI X9.31 recommends ciphers be used and phpseclib does use them if they're available (see
4551- // later on in the code) but if they're not we'll use sha1
4552- $result = '';
4553- while (strlen($result) < $length) { // each loop adds 20 bytes
4554- // microtime() isn't packed as "densely" as it could be but then neither is that the idea.
4555- // the idea is simply to ensure that each "block" has a unique element to it.
4556- $i = pack('H*', sha1(microtime()));
4557- $r = pack('H*', sha1($i ^ $v));
4558- $v = pack('H*', sha1($r ^ $i));
4559- $result.= $r;
4560- }
4561- return substr($result, 0, $length);
4562- }
4563-
4564 //return $crypto->encrypt(str_repeat("\0", $length));
4565
4566+ // the following is based off of ANSI X9.31:
4567+ //
4568+ // http://csrc.nist.gov/groups/STM/cavp/documents/rng/931rngext.pdf
4569+ //
4570+ // OpenSSL uses that same standard for it's random numbers:
4571+ //
4572+ // http://www.opensource.apple.com/source/OpenSSL/OpenSSL-38/openssl/fips-1.0/rand/fips_rand.c
4573+ // (do a search for "ANS X9.31 A.2.4")
4574 $result = '';
4575 while (strlen($result) < $length) {
4576- $i = $crypto->encrypt(microtime());
4577- $r = $crypto->encrypt($i ^ $v);
4578- $v = $crypto->encrypt($r ^ $i);
4579+ $i = $crypto->encrypt(microtime()); // strlen(microtime()) == 21
4580+ $r = $crypto->encrypt($i ^ $v); // strlen($v) == 20
4581+ $v = $crypto->encrypt($r ^ $i); // strlen($r) == 20
4582 $result.= $r;
4583 }
4584 return substr($result, 0, $length);
4585
4586=== modified file 'libraries/phpseclib/Crypt/Rijndael.php'
4587--- libraries/phpseclib/Crypt/Rijndael.php 2015-04-28 10:31:57 +0000
4588+++ libraries/phpseclib/Crypt/Rijndael.php 2015-10-27 17:36:50 +0000
4589@@ -5,13 +5,13 @@
4590 *
4591 * Uses mcrypt, if available/possible, and an internal implementation, otherwise.
4592 *
4593- * PHP versions 4 and 5
4594+ * PHP version 5
4595 *
4596- * If {@link Crypt_Rijndael::setBlockLength() setBlockLength()} isn't called, it'll be assumed to be 128 bits. If
4597- * {@link Crypt_Rijndael::setKeyLength() setKeyLength()} isn't called, it'll be calculated from
4598- * {@link Crypt_Rijndael::setKey() setKey()}. ie. if the key is 128-bits, the key length will be 128-bits. If it's
4599+ * If {@link \phpseclib\Crypt\Rijndael::setBlockLength() setBlockLength()} isn't called, it'll be assumed to be 128 bits. If
4600+ * {@link \phpseclib\Crypt\Rijndael::setKeyLength() setKeyLength()} isn't called, it'll be calculated from
4601+ * {@link \phpseclib\Crypt\Rijndael::setKey() setKey()}. ie. if the key is 128-bits, the key length will be 128-bits. If it's
4602 * 136-bits it'll be null-padded to 192-bits and 192 bits will be the key length until
4603- * {@link Crypt_Rijndael::setKey() setKey()} is called, again, at which point, it'll be recalculated.
4604+ * {@link \phpseclib\Crypt\Rijndael::setKey() setKey()} is called, again, at which point, it'll be recalculated.
4605 *
4606 * Not all Rijndael implementations may support 160-bits or 224-bits as the block length / key length. mcrypt, for example,
4607 * does not. AES, itself, only supports block lengths of 128 and key lengths of 128, 192, and 256.
4608@@ -28,9 +28,9 @@
4609 * Here's a short example of how to use this library:
4610 * <code>
4611 * <?php
4612- * include 'Crypt/Rijndael.php';
4613+ * include 'vendor/autoload.php';
4614 *
4615- * $rijndael = new Crypt_Rijndael();
4616+ * $rijndael = new \phpseclib\Crypt\Rijndael();
4617 *
4618 * $rijndael->setKey('abcdefghijklmnop');
4619 *
4620@@ -44,133 +44,48 @@
4621 * ?>
4622 * </code>
4623 *
4624- * LICENSE: Permission is hereby granted, free of charge, to any person obtaining a copy
4625- * of this software and associated documentation files (the "Software"), to deal
4626- * in the Software without restriction, including without limitation the rights
4627- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
4628- * copies of the Software, and to permit persons to whom the Software is
4629- * furnished to do so, subject to the following conditions:
4630- *
4631- * The above copyright notice and this permission notice shall be included in
4632- * all copies or substantial portions of the Software.
4633- *
4634- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
4635- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
4636- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
4637- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
4638- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
4639- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
4640- * THE SOFTWARE.
4641- *
4642 * @category Crypt
4643- * @package Crypt_Rijndael
4644+ * @package Rijndael
4645 * @author Jim Wigginton <terrafrost@php.net>
4646- * @copyright MMVIII Jim Wigginton
4647+ * @copyright 2008 Jim Wigginton
4648 * @license http://www.opensource.org/licenses/mit-license.html MIT License
4649 * @link http://phpseclib.sourceforge.net
4650 */
4651
4652-/**
4653- * Include Crypt_Base
4654- *
4655- * Base cipher class
4656- */
4657-if (!class_exists('Crypt_Base')) {
4658- include_once 'Base.php';
4659-}
4660-
4661-/**#@+
4662- * @access public
4663- * @see Crypt_Rijndael::encrypt()
4664- * @see Crypt_Rijndael::decrypt()
4665- */
4666-/**
4667- * Encrypt / decrypt using the Counter mode.
4668- *
4669- * Set to -1 since that's what Crypt/Random.php uses to index the CTR mode.
4670- *
4671- * @link http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation#Counter_.28CTR.29
4672- */
4673-define('CRYPT_RIJNDAEL_MODE_CTR', CRYPT_MODE_CTR);
4674-/**
4675- * Encrypt / decrypt using the Electronic Code Book mode.
4676- *
4677- * @link http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation#Electronic_codebook_.28ECB.29
4678- */
4679-define('CRYPT_RIJNDAEL_MODE_ECB', CRYPT_MODE_ECB);
4680-/**
4681- * Encrypt / decrypt using the Code Book Chaining mode.
4682- *
4683- * @link http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation#Cipher-block_chaining_.28CBC.29
4684- */
4685-define('CRYPT_RIJNDAEL_MODE_CBC', CRYPT_MODE_CBC);
4686-/**
4687- * Encrypt / decrypt using the Cipher Feedback mode.
4688- *
4689- * @link http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation#Cipher_feedback_.28CFB.29
4690- */
4691-define('CRYPT_RIJNDAEL_MODE_CFB', CRYPT_MODE_CFB);
4692-/**
4693- * Encrypt / decrypt using the Cipher Feedback mode.
4694- *
4695- * @link http://en.wikipedia.org/wiki/Block_cipher_modes_of_operation#Output_feedback_.28OFB.29
4696- */
4697-define('CRYPT_RIJNDAEL_MODE_OFB', CRYPT_MODE_OFB);
4698-/**#@-*/
4699-
4700-/**#@+
4701- * @access private
4702- * @see Crypt_Rijndael::Crypt_Rijndael()
4703- */
4704-/**
4705- * Toggles the internal implementation
4706- */
4707-define('CRYPT_RIJNDAEL_MODE_INTERNAL', CRYPT_MODE_INTERNAL);
4708-/**
4709- * Toggles the mcrypt implementation
4710- */
4711-define('CRYPT_RIJNDAEL_MODE_MCRYPT', CRYPT_MODE_MCRYPT);
4712-/**#@-*/
4713+namespace phpseclib\Crypt;
4714+
4715+use phpseclib\Crypt\Base;
4716
4717 /**
4718 * Pure-PHP implementation of Rijndael.
4719 *
4720- * @package Crypt_Rijndael
4721+ * @package Rijndael
4722 * @author Jim Wigginton <terrafrost@php.net>
4723 * @access public
4724 */
4725-class Crypt_Rijndael extends Crypt_Base
4726+class Rijndael extends Base
4727 {
4728 /**
4729 * The default password key_size used by setPassword()
4730 *
4731- * @see Crypt_Base::password_key_size
4732- * @see Crypt_Base::setPassword()
4733+ * @see \phpseclib\Crypt\Base::password_key_size
4734+ * @see \phpseclib\Crypt\Base::setPassword()
4735 * @var Integer
4736 * @access private
4737 */
4738 var $password_key_size = 16;
4739
4740 /**
4741- * The namespace used by the cipher for its constants.
4742- *
4743- * @see Crypt_Base::const_namespace
4744- * @var String
4745- * @access private
4746- */
4747- var $const_namespace = 'RIJNDAEL';
4748-
4749- /**
4750 * The mcrypt specific name of the cipher
4751 *
4752 * Mcrypt is useable for 128/192/256-bit $block_size/$key_size. For 160/224 not.
4753- * Crypt_Rijndael determines automatically whether mcrypt is useable
4754+ * \phpseclib\Crypt\Rijndael determines automatically whether mcrypt is useable
4755 * or not for the current $block_size/$key_size.
4756 * In case of, $cipher_name_mcrypt will be set dynamically at run time accordingly.
4757 *
4758- * @see Crypt_Base::cipher_name_mcrypt
4759- * @see Crypt_Base::engine
4760- * @see _setupEngine()
4761+ * @see \phpseclib\Crypt\Base::cipher_name_mcrypt
4762+ * @see \phpseclib\Crypt\Base::engine
4763+ * @see isValidEngine()
4764 * @var String
4765 * @access private
4766 */
4767@@ -179,8 +94,8 @@
4768 /**
4769 * The default salt used by setPassword()
4770 *
4771- * @see Crypt_Base::password_default_salt
4772- * @see Crypt_Base::setPassword()
4773+ * @see \phpseclib\Crypt\Base::password_default_salt
4774+ * @see \phpseclib\Crypt\Base::setPassword()
4775 * @var String
4776 * @access private
4777 */
4778@@ -223,7 +138,6 @@
4779 * because the encryption / decryption / key schedule creation requires this number and not $block_size. We could
4780 * derive this from $block_size or vice versa, but that'd mean we'd have to do multiple shift operations, so in lieu
4781 * of that, we'll just precompute it once.
4782- *
4783 */
4784 var $Nb = 4;
4785
4786@@ -276,432 +190,27 @@
4787 var $kl;
4788
4789 /**
4790- * Precomputed mixColumns table
4791- *
4792- * According to <http://csrc.nist.gov/archive/aes/rijndael/Rijndael-ammended.pdf#page=19> (section 5.2.1),
4793- * precomputed tables can be used in the mixColumns phase. in that example, they're assigned t0...t3, so
4794- * those are the names we'll use.
4795- *
4796- * @see Crypt_Rijndael:_encryptBlock()
4797- * @see Crypt_Rijndael:_decryptBlock()
4798- * @var Array
4799- * @access private
4800- */
4801- var $t0 = array(
4802- 0xC66363A5, 0xF87C7C84, 0xEE777799, 0xF67B7B8D, 0xFFF2F20D, 0xD66B6BBD, 0xDE6F6FB1, 0x91C5C554,
4803- 0x60303050, 0x02010103, 0xCE6767A9, 0x562B2B7D, 0xE7FEFE19, 0xB5D7D762, 0x4DABABE6, 0xEC76769A,
4804- 0x8FCACA45, 0x1F82829D, 0x89C9C940, 0xFA7D7D87, 0xEFFAFA15, 0xB25959EB, 0x8E4747C9, 0xFBF0F00B,
4805- 0x41ADADEC, 0xB3D4D467, 0x5FA2A2FD, 0x45AFAFEA, 0x239C9CBF, 0x53A4A4F7, 0xE4727296, 0x9BC0C05B,
4806- 0x75B7B7C2, 0xE1FDFD1C, 0x3D9393AE, 0x4C26266A, 0x6C36365A, 0x7E3F3F41, 0xF5F7F702, 0x83CCCC4F,
4807- 0x6834345C, 0x51A5A5F4, 0xD1E5E534, 0xF9F1F108, 0xE2717193, 0xABD8D873, 0x62313153, 0x2A15153F,
4808- 0x0804040C, 0x95C7C752, 0x46232365, 0x9DC3C35E, 0x30181828, 0x379696A1, 0x0A05050F, 0x2F9A9AB5,
4809- 0x0E070709, 0x24121236, 0x1B80809B, 0xDFE2E23D, 0xCDEBEB26, 0x4E272769, 0x7FB2B2CD, 0xEA75759F,
4810- 0x1209091B, 0x1D83839E, 0x582C2C74, 0x341A1A2E, 0x361B1B2D, 0xDC6E6EB2, 0xB45A5AEE, 0x5BA0A0FB,
4811- 0xA45252F6, 0x763B3B4D, 0xB7D6D661, 0x7DB3B3CE, 0x5229297B, 0xDDE3E33E, 0x5E2F2F71, 0x13848497,
4812- 0xA65353F5, 0xB9D1D168, 0x00000000, 0xC1EDED2C, 0x40202060, 0xE3FCFC1F, 0x79B1B1C8, 0xB65B5BED,
4813- 0xD46A6ABE, 0x8DCBCB46, 0x67BEBED9, 0x7239394B, 0x944A4ADE, 0x984C4CD4, 0xB05858E8, 0x85CFCF4A,
4814- 0xBBD0D06B, 0xC5EFEF2A, 0x4FAAAAE5, 0xEDFBFB16, 0x864343C5, 0x9A4D4DD7, 0x66333355, 0x11858594,
4815- 0x8A4545CF, 0xE9F9F910, 0x04020206, 0xFE7F7F81, 0xA05050F0, 0x783C3C44, 0x259F9FBA, 0x4BA8A8E3,
4816- 0xA25151F3, 0x5DA3A3FE, 0x804040C0, 0x058F8F8A, 0x3F9292AD, 0x219D9DBC, 0x70383848, 0xF1F5F504,
4817- 0x63BCBCDF, 0x77B6B6C1, 0xAFDADA75, 0x42212163, 0x20101030, 0xE5FFFF1A, 0xFDF3F30E, 0xBFD2D26D,
4818- 0x81CDCD4C, 0x180C0C14, 0x26131335, 0xC3ECEC2F, 0xBE5F5FE1, 0x359797A2, 0x884444CC, 0x2E171739,
4819- 0x93C4C457, 0x55A7A7F2, 0xFC7E7E82, 0x7A3D3D47, 0xC86464AC, 0xBA5D5DE7, 0x3219192B, 0xE6737395,
4820- 0xC06060A0, 0x19818198, 0x9E4F4FD1, 0xA3DCDC7F, 0x44222266, 0x542A2A7E, 0x3B9090AB, 0x0B888883,
4821- 0x8C4646CA, 0xC7EEEE29, 0x6BB8B8D3, 0x2814143C, 0xA7DEDE79, 0xBC5E5EE2, 0x160B0B1D, 0xADDBDB76,
4822- 0xDBE0E03B, 0x64323256, 0x743A3A4E, 0x140A0A1E, 0x924949DB, 0x0C06060A, 0x4824246C, 0xB85C5CE4,
4823- 0x9FC2C25D, 0xBDD3D36E, 0x43ACACEF, 0xC46262A6, 0x399191A8, 0x319595A4, 0xD3E4E437, 0xF279798B,
4824- 0xD5E7E732, 0x8BC8C843, 0x6E373759, 0xDA6D6DB7, 0x018D8D8C, 0xB1D5D564, 0x9C4E4ED2, 0x49A9A9E0,
4825- 0xD86C6CB4, 0xAC5656FA, 0xF3F4F407, 0xCFEAEA25, 0xCA6565AF, 0xF47A7A8E, 0x47AEAEE9, 0x10080818,
4826- 0x6FBABAD5, 0xF0787888, 0x4A25256F, 0x5C2E2E72, 0x381C1C24, 0x57A6A6F1, 0x73B4B4C7, 0x97C6C651,
4827- 0xCBE8E823, 0xA1DDDD7C, 0xE874749C, 0x3E1F1F21, 0x964B4BDD, 0x61BDBDDC, 0x0D8B8B86, 0x0F8A8A85,
4828- 0xE0707090, 0x7C3E3E42, 0x71B5B5C4, 0xCC6666AA, 0x904848D8, 0x06030305, 0xF7F6F601, 0x1C0E0E12,
4829- 0xC26161A3, 0x6A35355F, 0xAE5757F9, 0x69B9B9D0, 0x17868691, 0x99C1C158, 0x3A1D1D27, 0x279E9EB9,
4830- 0xD9E1E138, 0xEBF8F813, 0x2B9898B3, 0x22111133, 0xD26969BB, 0xA9D9D970, 0x078E8E89, 0x339494A7,
4831- 0x2D9B9BB6, 0x3C1E1E22, 0x15878792, 0xC9E9E920, 0x87CECE49, 0xAA5555FF, 0x50282878, 0xA5DFDF7A,
4832- 0x038C8C8F, 0x59A1A1F8, 0x09898980, 0x1A0D0D17, 0x65BFBFDA, 0xD7E6E631, 0x844242C6, 0xD06868B8,
4833- 0x824141C3, 0x299999B0, 0x5A2D2D77, 0x1E0F0F11, 0x7BB0B0CB, 0xA85454FC, 0x6DBBBBD6, 0x2C16163A
4834- );
4835-
4836- /**
4837- * Precomputed mixColumns table
4838- *
4839- * @see Crypt_Rijndael:_encryptBlock()
4840- * @see Crypt_Rijndael:_decryptBlock()
4841- * @var Array
4842- * @access private
4843- */
4844- var $t1 = array(
4845- 0xA5C66363, 0x84F87C7C, 0x99EE7777, 0x8DF67B7B, 0x0DFFF2F2, 0xBDD66B6B, 0xB1DE6F6F, 0x5491C5C5,
4846- 0x50603030, 0x03020101, 0xA9CE6767, 0x7D562B2B, 0x19E7FEFE, 0x62B5D7D7, 0xE64DABAB, 0x9AEC7676,
4847- 0x458FCACA, 0x9D1F8282, 0x4089C9C9, 0x87FA7D7D, 0x15EFFAFA, 0xEBB25959, 0xC98E4747, 0x0BFBF0F0,
4848- 0xEC41ADAD, 0x67B3D4D4, 0xFD5FA2A2, 0xEA45AFAF, 0xBF239C9C, 0xF753A4A4, 0x96E47272, 0x5B9BC0C0,
4849- 0xC275B7B7, 0x1CE1FDFD, 0xAE3D9393, 0x6A4C2626, 0x5A6C3636, 0x417E3F3F, 0x02F5F7F7, 0x4F83CCCC,
4850- 0x5C683434, 0xF451A5A5, 0x34D1E5E5, 0x08F9F1F1, 0x93E27171, 0x73ABD8D8, 0x53623131, 0x3F2A1515,
4851- 0x0C080404, 0x5295C7C7, 0x65462323, 0x5E9DC3C3, 0x28301818, 0xA1379696, 0x0F0A0505, 0xB52F9A9A,
4852- 0x090E0707, 0x36241212, 0x9B1B8080, 0x3DDFE2E2, 0x26CDEBEB, 0x694E2727, 0xCD7FB2B2, 0x9FEA7575,
4853- 0x1B120909, 0x9E1D8383, 0x74582C2C, 0x2E341A1A, 0x2D361B1B, 0xB2DC6E6E, 0xEEB45A5A, 0xFB5BA0A0,
4854- 0xF6A45252, 0x4D763B3B, 0x61B7D6D6, 0xCE7DB3B3, 0x7B522929, 0x3EDDE3E3, 0x715E2F2F, 0x97138484,
4855- 0xF5A65353, 0x68B9D1D1, 0x00000000, 0x2CC1EDED, 0x60402020, 0x1FE3FCFC, 0xC879B1B1, 0xEDB65B5B,
4856- 0xBED46A6A, 0x468DCBCB, 0xD967BEBE, 0x4B723939, 0xDE944A4A, 0xD4984C4C, 0xE8B05858, 0x4A85CFCF,
4857- 0x6BBBD0D0, 0x2AC5EFEF, 0xE54FAAAA, 0x16EDFBFB, 0xC5864343, 0xD79A4D4D, 0x55663333, 0x94118585,
4858- 0xCF8A4545, 0x10E9F9F9, 0x06040202, 0x81FE7F7F, 0xF0A05050, 0x44783C3C, 0xBA259F9F, 0xE34BA8A8,
4859- 0xF3A25151, 0xFE5DA3A3, 0xC0804040, 0x8A058F8F, 0xAD3F9292, 0xBC219D9D, 0x48703838, 0x04F1F5F5,
4860- 0xDF63BCBC, 0xC177B6B6, 0x75AFDADA, 0x63422121, 0x30201010, 0x1AE5FFFF, 0x0EFDF3F3, 0x6DBFD2D2,
4861- 0x4C81CDCD, 0x14180C0C, 0x35261313, 0x2FC3ECEC, 0xE1BE5F5F, 0xA2359797, 0xCC884444, 0x392E1717,
4862- 0x5793C4C4, 0xF255A7A7, 0x82FC7E7E, 0x477A3D3D, 0xACC86464, 0xE7BA5D5D, 0x2B321919, 0x95E67373,
4863- 0xA0C06060, 0x98198181, 0xD19E4F4F, 0x7FA3DCDC, 0x66442222, 0x7E542A2A, 0xAB3B9090, 0x830B8888,
4864- 0xCA8C4646, 0x29C7EEEE, 0xD36BB8B8, 0x3C281414, 0x79A7DEDE, 0xE2BC5E5E, 0x1D160B0B, 0x76ADDBDB,
4865- 0x3BDBE0E0, 0x56643232, 0x4E743A3A, 0x1E140A0A, 0xDB924949, 0x0A0C0606, 0x6C482424, 0xE4B85C5C,
4866- 0x5D9FC2C2, 0x6EBDD3D3, 0xEF43ACAC, 0xA6C46262, 0xA8399191, 0xA4319595, 0x37D3E4E4, 0x8BF27979,
4867- 0x32D5E7E7, 0x438BC8C8, 0x596E3737, 0xB7DA6D6D, 0x8C018D8D, 0x64B1D5D5, 0xD29C4E4E, 0xE049A9A9,
4868- 0xB4D86C6C, 0xFAAC5656, 0x07F3F4F4, 0x25CFEAEA, 0xAFCA6565, 0x8EF47A7A, 0xE947AEAE, 0x18100808,
4869- 0xD56FBABA, 0x88F07878, 0x6F4A2525, 0x725C2E2E, 0x24381C1C, 0xF157A6A6, 0xC773B4B4, 0x5197C6C6,
4870- 0x23CBE8E8, 0x7CA1DDDD, 0x9CE87474, 0x213E1F1F, 0xDD964B4B, 0xDC61BDBD, 0x860D8B8B, 0x850F8A8A,
4871- 0x90E07070, 0x427C3E3E, 0xC471B5B5, 0xAACC6666, 0xD8904848, 0x05060303, 0x01F7F6F6, 0x121C0E0E,
4872- 0xA3C26161, 0x5F6A3535, 0xF9AE5757, 0xD069B9B9, 0x91178686, 0x5899C1C1, 0x273A1D1D, 0xB9279E9E,
4873- 0x38D9E1E1, 0x13EBF8F8, 0xB32B9898, 0x33221111, 0xBBD26969, 0x70A9D9D9, 0x89078E8E, 0xA7339494,
4874- 0xB62D9B9B, 0x223C1E1E, 0x92158787, 0x20C9E9E9, 0x4987CECE, 0xFFAA5555, 0x78502828, 0x7AA5DFDF,
4875- 0x8F038C8C, 0xF859A1A1, 0x80098989, 0x171A0D0D, 0xDA65BFBF, 0x31D7E6E6, 0xC6844242, 0xB8D06868,
4876- 0xC3824141, 0xB0299999, 0x775A2D2D, 0x111E0F0F, 0xCB7BB0B0, 0xFCA85454, 0xD66DBBBB, 0x3A2C1616
4877- );
4878-
4879- /**
4880- * Precomputed mixColumns table
4881- *
4882- * @see Crypt_Rijndael:_encryptBlock()
4883- * @see Crypt_Rijndael:_decryptBlock()
4884- * @var Array
4885- * @access private
4886- */
4887- var $t2 = array(
4888- 0x63A5C663, 0x7C84F87C, 0x7799EE77, 0x7B8DF67B, 0xF20DFFF2, 0x6BBDD66B, 0x6FB1DE6F, 0xC55491C5,
4889- 0x30506030, 0x01030201, 0x67A9CE67, 0x2B7D562B, 0xFE19E7FE, 0xD762B5D7, 0xABE64DAB, 0x769AEC76,
4890- 0xCA458FCA, 0x829D1F82, 0xC94089C9, 0x7D87FA7D, 0xFA15EFFA, 0x59EBB259, 0x47C98E47, 0xF00BFBF0,
4891- 0xADEC41AD, 0xD467B3D4, 0xA2FD5FA2, 0xAFEA45AF, 0x9CBF239C, 0xA4F753A4, 0x7296E472, 0xC05B9BC0,
4892- 0xB7C275B7, 0xFD1CE1FD, 0x93AE3D93, 0x266A4C26, 0x365A6C36, 0x3F417E3F, 0xF702F5F7, 0xCC4F83CC,
4893- 0x345C6834, 0xA5F451A5, 0xE534D1E5, 0xF108F9F1, 0x7193E271, 0xD873ABD8, 0x31536231, 0x153F2A15,
4894- 0x040C0804, 0xC75295C7, 0x23654623, 0xC35E9DC3, 0x18283018, 0x96A13796, 0x050F0A05, 0x9AB52F9A,
4895- 0x07090E07, 0x12362412, 0x809B1B80, 0xE23DDFE2, 0xEB26CDEB, 0x27694E27, 0xB2CD7FB2, 0x759FEA75,
4896- 0x091B1209, 0x839E1D83, 0x2C74582C, 0x1A2E341A, 0x1B2D361B, 0x6EB2DC6E, 0x5AEEB45A, 0xA0FB5BA0,
4897- 0x52F6A452, 0x3B4D763B, 0xD661B7D6, 0xB3CE7DB3, 0x297B5229, 0xE33EDDE3, 0x2F715E2F, 0x84971384,
4898- 0x53F5A653, 0xD168B9D1, 0x00000000, 0xED2CC1ED, 0x20604020, 0xFC1FE3FC, 0xB1C879B1, 0x5BEDB65B,
4899- 0x6ABED46A, 0xCB468DCB, 0xBED967BE, 0x394B7239, 0x4ADE944A, 0x4CD4984C, 0x58E8B058, 0xCF4A85CF,
4900- 0xD06BBBD0, 0xEF2AC5EF, 0xAAE54FAA, 0xFB16EDFB, 0x43C58643, 0x4DD79A4D, 0x33556633, 0x85941185,
4901- 0x45CF8A45, 0xF910E9F9, 0x02060402, 0x7F81FE7F, 0x50F0A050, 0x3C44783C, 0x9FBA259F, 0xA8E34BA8,
4902- 0x51F3A251, 0xA3FE5DA3, 0x40C08040, 0x8F8A058F, 0x92AD3F92, 0x9DBC219D, 0x38487038, 0xF504F1F5,
4903- 0xBCDF63BC, 0xB6C177B6, 0xDA75AFDA, 0x21634221, 0x10302010, 0xFF1AE5FF, 0xF30EFDF3, 0xD26DBFD2,
4904- 0xCD4C81CD, 0x0C14180C, 0x13352613, 0xEC2FC3EC, 0x5FE1BE5F, 0x97A23597, 0x44CC8844, 0x17392E17,
4905- 0xC45793C4, 0xA7F255A7, 0x7E82FC7E, 0x3D477A3D, 0x64ACC864, 0x5DE7BA5D, 0x192B3219, 0x7395E673,
4906- 0x60A0C060, 0x81981981, 0x4FD19E4F, 0xDC7FA3DC, 0x22664422, 0x2A7E542A, 0x90AB3B90, 0x88830B88,
4907- 0x46CA8C46, 0xEE29C7EE, 0xB8D36BB8, 0x143C2814, 0xDE79A7DE, 0x5EE2BC5E, 0x0B1D160B, 0xDB76ADDB,
4908- 0xE03BDBE0, 0x32566432, 0x3A4E743A, 0x0A1E140A, 0x49DB9249, 0x060A0C06, 0x246C4824, 0x5CE4B85C,
4909- 0xC25D9FC2, 0xD36EBDD3, 0xACEF43AC, 0x62A6C462, 0x91A83991, 0x95A43195, 0xE437D3E4, 0x798BF279,
4910- 0xE732D5E7, 0xC8438BC8, 0x37596E37, 0x6DB7DA6D, 0x8D8C018D, 0xD564B1D5, 0x4ED29C4E, 0xA9E049A9,
4911- 0x6CB4D86C, 0x56FAAC56, 0xF407F3F4, 0xEA25CFEA, 0x65AFCA65, 0x7A8EF47A, 0xAEE947AE, 0x08181008,
4912- 0xBAD56FBA, 0x7888F078, 0x256F4A25, 0x2E725C2E, 0x1C24381C, 0xA6F157A6, 0xB4C773B4, 0xC65197C6,
4913- 0xE823CBE8, 0xDD7CA1DD, 0x749CE874, 0x1F213E1F, 0x4BDD964B, 0xBDDC61BD, 0x8B860D8B, 0x8A850F8A,
4914- 0x7090E070, 0x3E427C3E, 0xB5C471B5, 0x66AACC66, 0x48D89048, 0x03050603, 0xF601F7F6, 0x0E121C0E,
4915- 0x61A3C261, 0x355F6A35, 0x57F9AE57, 0xB9D069B9, 0x86911786, 0xC15899C1, 0x1D273A1D, 0x9EB9279E,
4916- 0xE138D9E1, 0xF813EBF8, 0x98B32B98, 0x11332211, 0x69BBD269, 0xD970A9D9, 0x8E89078E, 0x94A73394,
4917- 0x9BB62D9B, 0x1E223C1E, 0x87921587, 0xE920C9E9, 0xCE4987CE, 0x55FFAA55, 0x28785028, 0xDF7AA5DF,
4918- 0x8C8F038C, 0xA1F859A1, 0x89800989, 0x0D171A0D, 0xBFDA65BF, 0xE631D7E6, 0x42C68442, 0x68B8D068,
4919- 0x41C38241, 0x99B02999, 0x2D775A2D, 0x0F111E0F, 0xB0CB7BB0, 0x54FCA854, 0xBBD66DBB, 0x163A2C16
4920- );
4921-
4922- /**
4923- * Precomputed mixColumns table
4924- *
4925- * @see Crypt_Rijndael:_encryptBlock()
4926- * @see Crypt_Rijndael:_decryptBlock()
4927- * @var Array
4928- * @access private
4929- */
4930- var $t3 = array(
4931- 0x6363A5C6, 0x7C7C84F8, 0x777799EE, 0x7B7B8DF6, 0xF2F20DFF, 0x6B6BBDD6, 0x6F6FB1DE, 0xC5C55491,
4932- 0x30305060, 0x01010302, 0x6767A9CE, 0x2B2B7D56, 0xFEFE19E7, 0xD7D762B5, 0xABABE64D, 0x76769AEC,
4933- 0xCACA458F, 0x82829D1F, 0xC9C94089, 0x7D7D87FA, 0xFAFA15EF, 0x5959EBB2, 0x4747C98E, 0xF0F00BFB,
4934- 0xADADEC41, 0xD4D467B3, 0xA2A2FD5F, 0xAFAFEA45, 0x9C9CBF23, 0xA4A4F753, 0x727296E4, 0xC0C05B9B,
4935- 0xB7B7C275, 0xFDFD1CE1, 0x9393AE3D, 0x26266A4C, 0x36365A6C, 0x3F3F417E, 0xF7F702F5, 0xCCCC4F83,
4936- 0x34345C68, 0xA5A5F451, 0xE5E534D1, 0xF1F108F9, 0x717193E2, 0xD8D873AB, 0x31315362, 0x15153F2A,
4937- 0x04040C08, 0xC7C75295, 0x23236546, 0xC3C35E9D, 0x18182830, 0x9696A137, 0x05050F0A, 0x9A9AB52F,
4938- 0x0707090E, 0x12123624, 0x80809B1B, 0xE2E23DDF, 0xEBEB26CD, 0x2727694E, 0xB2B2CD7F, 0x75759FEA,
4939- 0x09091B12, 0x83839E1D, 0x2C2C7458, 0x1A1A2E34, 0x1B1B2D36, 0x6E6EB2DC, 0x5A5AEEB4, 0xA0A0FB5B,
4940- 0x5252F6A4, 0x3B3B4D76, 0xD6D661B7, 0xB3B3CE7D, 0x29297B52, 0xE3E33EDD, 0x2F2F715E, 0x84849713,
4941- 0x5353F5A6, 0xD1D168B9, 0x00000000, 0xEDED2CC1, 0x20206040, 0xFCFC1FE3, 0xB1B1C879, 0x5B5BEDB6,
4942- 0x6A6ABED4, 0xCBCB468D, 0xBEBED967, 0x39394B72, 0x4A4ADE94, 0x4C4CD498, 0x5858E8B0, 0xCFCF4A85,
4943- 0xD0D06BBB, 0xEFEF2AC5, 0xAAAAE54F, 0xFBFB16ED, 0x4343C586, 0x4D4DD79A, 0x33335566, 0x85859411,
4944- 0x4545CF8A, 0xF9F910E9, 0x02020604, 0x7F7F81FE, 0x5050F0A0, 0x3C3C4478, 0x9F9FBA25, 0xA8A8E34B,
4945- 0x5151F3A2, 0xA3A3FE5D, 0x4040C080, 0x8F8F8A05, 0x9292AD3F, 0x9D9DBC21, 0x38384870, 0xF5F504F1,
4946- 0xBCBCDF63, 0xB6B6C177, 0xDADA75AF, 0x21216342, 0x10103020, 0xFFFF1AE5, 0xF3F30EFD, 0xD2D26DBF,
4947- 0xCDCD4C81, 0x0C0C1418, 0x13133526, 0xECEC2FC3, 0x5F5FE1BE, 0x9797A235, 0x4444CC88, 0x1717392E,
4948- 0xC4C45793, 0xA7A7F255, 0x7E7E82FC, 0x3D3D477A, 0x6464ACC8, 0x5D5DE7BA, 0x19192B32, 0x737395E6,
4949- 0x6060A0C0, 0x81819819, 0x4F4FD19E, 0xDCDC7FA3, 0x22226644, 0x2A2A7E54, 0x9090AB3B, 0x8888830B,
4950- 0x4646CA8C, 0xEEEE29C7, 0xB8B8D36B, 0x14143C28, 0xDEDE79A7, 0x5E5EE2BC, 0x0B0B1D16, 0xDBDB76AD,
4951- 0xE0E03BDB, 0x32325664, 0x3A3A4E74, 0x0A0A1E14, 0x4949DB92, 0x06060A0C, 0x24246C48, 0x5C5CE4B8,
4952- 0xC2C25D9F, 0xD3D36EBD, 0xACACEF43, 0x6262A6C4, 0x9191A839, 0x9595A431, 0xE4E437D3, 0x79798BF2,
4953- 0xE7E732D5, 0xC8C8438B, 0x3737596E, 0x6D6DB7DA, 0x8D8D8C01, 0xD5D564B1, 0x4E4ED29C, 0xA9A9E049,
4954- 0x6C6CB4D8, 0x5656FAAC, 0xF4F407F3, 0xEAEA25CF, 0x6565AFCA, 0x7A7A8EF4, 0xAEAEE947, 0x08081810,
4955- 0xBABAD56F, 0x787888F0, 0x25256F4A, 0x2E2E725C, 0x1C1C2438, 0xA6A6F157, 0xB4B4C773, 0xC6C65197,
4956- 0xE8E823CB, 0xDDDD7CA1, 0x74749CE8, 0x1F1F213E, 0x4B4BDD96, 0xBDBDDC61, 0x8B8B860D, 0x8A8A850F,
4957- 0x707090E0, 0x3E3E427C, 0xB5B5C471, 0x6666AACC, 0x4848D890, 0x03030506, 0xF6F601F7, 0x0E0E121C,
4958- 0x6161A3C2, 0x35355F6A, 0x5757F9AE, 0xB9B9D069, 0x86869117, 0xC1C15899, 0x1D1D273A, 0x9E9EB927,
4959- 0xE1E138D9, 0xF8F813EB, 0x9898B32B, 0x11113322, 0x6969BBD2, 0xD9D970A9, 0x8E8E8907, 0x9494A733,
4960- 0x9B9BB62D, 0x1E1E223C, 0x87879215, 0xE9E920C9, 0xCECE4987, 0x5555FFAA, 0x28287850, 0xDFDF7AA5,
4961- 0x8C8C8F03, 0xA1A1F859, 0x89898009, 0x0D0D171A, 0xBFBFDA65, 0xE6E631D7, 0x4242C684, 0x6868B8D0,
4962- 0x4141C382, 0x9999B029, 0x2D2D775A, 0x0F0F111E, 0xB0B0CB7B, 0x5454FCA8, 0xBBBBD66D, 0x16163A2C
4963- );
4964-
4965- /**
4966- * Precomputed invMixColumns table
4967- *
4968- * @see Crypt_Rijndael:_encryptBlock()
4969- * @see Crypt_Rijndael:_decryptBlock()
4970- * @var Array
4971- * @access private
4972- */
4973- var $dt0 = array(
4974- 0x51F4A750, 0x7E416553, 0x1A17A4C3, 0x3A275E96, 0x3BAB6BCB, 0x1F9D45F1, 0xACFA58AB, 0x4BE30393,
4975- 0x2030FA55, 0xAD766DF6, 0x88CC7691, 0xF5024C25, 0x4FE5D7FC, 0xC52ACBD7, 0x26354480, 0xB562A38F,
4976- 0xDEB15A49, 0x25BA1B67, 0x45EA0E98, 0x5DFEC0E1, 0xC32F7502, 0x814CF012, 0x8D4697A3, 0x6BD3F9C6,
4977- 0x038F5FE7, 0x15929C95, 0xBF6D7AEB, 0x955259DA, 0xD4BE832D, 0x587421D3, 0x49E06929, 0x8EC9C844,
4978- 0x75C2896A, 0xF48E7978, 0x99583E6B, 0x27B971DD, 0xBEE14FB6, 0xF088AD17, 0xC920AC66, 0x7DCE3AB4,
4979- 0x63DF4A18, 0xE51A3182, 0x97513360, 0x62537F45, 0xB16477E0, 0xBB6BAE84, 0xFE81A01C, 0xF9082B94,
4980- 0x70486858, 0x8F45FD19, 0x94DE6C87, 0x527BF8B7, 0xAB73D323, 0x724B02E2, 0xE31F8F57, 0x6655AB2A,
4981- 0xB2EB2807, 0x2FB5C203, 0x86C57B9A, 0xD33708A5, 0x302887F2, 0x23BFA5B2, 0x02036ABA, 0xED16825C,
4982- 0x8ACF1C2B, 0xA779B492, 0xF307F2F0, 0x4E69E2A1, 0x65DAF4CD, 0x0605BED5, 0xD134621F, 0xC4A6FE8A,
4983- 0x342E539D, 0xA2F355A0, 0x058AE132, 0xA4F6EB75, 0x0B83EC39, 0x4060EFAA, 0x5E719F06, 0xBD6E1051,
4984- 0x3E218AF9, 0x96DD063D, 0xDD3E05AE, 0x4DE6BD46, 0x91548DB5, 0x71C45D05, 0x0406D46F, 0x605015FF,
4985- 0x1998FB24, 0xD6BDE997, 0x894043CC, 0x67D99E77, 0xB0E842BD, 0x07898B88, 0xE7195B38, 0x79C8EEDB,
4986- 0xA17C0A47, 0x7C420FE9, 0xF8841EC9, 0x00000000, 0x09808683, 0x322BED48, 0x1E1170AC, 0x6C5A724E,
4987- 0xFD0EFFFB, 0x0F853856, 0x3DAED51E, 0x362D3927, 0x0A0FD964, 0x685CA621, 0x9B5B54D1, 0x24362E3A,
4988- 0x0C0A67B1, 0x9357E70F, 0xB4EE96D2, 0x1B9B919E, 0x80C0C54F, 0x61DC20A2, 0x5A774B69, 0x1C121A16,
4989- 0xE293BA0A, 0xC0A02AE5, 0x3C22E043, 0x121B171D, 0x0E090D0B, 0xF28BC7AD, 0x2DB6A8B9, 0x141EA9C8,
4990- 0x57F11985, 0xAF75074C, 0xEE99DDBB, 0xA37F60FD, 0xF701269F, 0x5C72F5BC, 0x44663BC5, 0x5BFB7E34,
4991- 0x8B432976, 0xCB23C6DC, 0xB6EDFC68, 0xB8E4F163, 0xD731DCCA, 0x42638510, 0x13972240, 0x84C61120,
4992- 0x854A247D, 0xD2BB3DF8, 0xAEF93211, 0xC729A16D, 0x1D9E2F4B, 0xDCB230F3, 0x0D8652EC, 0x77C1E3D0,
4993- 0x2BB3166C, 0xA970B999, 0x119448FA, 0x47E96422, 0xA8FC8CC4, 0xA0F03F1A, 0x567D2CD8, 0x223390EF,
4994- 0x87494EC7, 0xD938D1C1, 0x8CCAA2FE, 0x98D40B36, 0xA6F581CF, 0xA57ADE28, 0xDAB78E26, 0x3FADBFA4,
4995- 0x2C3A9DE4, 0x5078920D, 0x6A5FCC9B, 0x547E4662, 0xF68D13C2, 0x90D8B8E8, 0x2E39F75E, 0x82C3AFF5,
4996- 0x9F5D80BE, 0x69D0937C, 0x6FD52DA9, 0xCF2512B3, 0xC8AC993B, 0x10187DA7, 0xE89C636E, 0xDB3BBB7B,
4997- 0xCD267809, 0x6E5918F4, 0xEC9AB701, 0x834F9AA8, 0xE6956E65, 0xAAFFE67E, 0x21BCCF08, 0xEF15E8E6,
4998- 0xBAE79BD9, 0x4A6F36CE, 0xEA9F09D4, 0x29B07CD6, 0x31A4B2AF, 0x2A3F2331, 0xC6A59430, 0x35A266C0,
4999- 0x744EBC37, 0xFC82CAA6, 0xE090D0B0, 0x33A7D815, 0xF104984A, 0x41ECDAF7, 0x7FCD500E, 0x1791F62F,
5000- 0x764DD68D, 0x43EFB04D, 0xCCAA4D54, 0xE49604DF, 0x9ED1B5E3, 0x4C6A881B, 0xC12C1FB8, 0x4665517F,
The diff has been truncated for viewing.

Subscribers

People subscribed via source and target branches