Commit Graph

475 Commits

Author SHA1 Message Date
Vincent Milum Jr
31b40f71bb Fix for SYSTEM VERSIONED tables #14514, #14515, and #14516 (#14536)
Fixes #14514
Fixes #14515
Possible fix for #14516

 #14514 Tables which enable the new MariaDB 10.3 versioning show up as "SYSTEM VERSIONED" instead of "BASE TABLE" inside of information schema. This patch now checks for both, so these new table types don't incorrectly display as views.

 #14515 MariaDB 10.3 also supports INVISIBLE columns, which is optionally paired with SYSTEM VERSIONED tabled (or implemented separately). This patch helps handle this new column attribute.

 #14516 This patch cannot be fully tested and verified with current MariaDB builds. Version 10.3.9 (currently unreleased) corrects an issue with column information for SYSTEM VERSIONED columns that this patch relies on. https://jira.mariadb.org/browse/MDEV-16804 - the reason for checking with preg_match instead of adding to the list is because there are now combined "extra" information for columns, such as INVISIBLE columns. Just matching entire strings also has a bug with these other "extra" parameters.

Signed-off-by: Vincent Milum Jr <git@darkain.com>
Signed-off-by: Maurício Meneghini Fauth <mauriciofauth@gmail.com>
(cherry picked from commit 3f6e360a4e)
Signed-off-by: Maurício Meneghini Fauth <mauriciofauth@gmail.com>
2019-02-15 17:27:55 -02:00
ales-bulko
0be9c13689 Fixes #14658 - Regression on multi table query (#14681)
Added functionality to generate SELECT query with JOINs of requested tables. It was mentioned that it's just a bug and it was working in previous versions, but I did not see any code fragments that would make it possible. Please, feel free to suggest any better solution if you don't like that one.

Fixes #14658

Signed-off-by: Aleš Buľko <ales.bulko@student.tuke.sk>
(cherry picked from commit 23ce7cec52)
Signed-off-by: Maurício Meneghini Fauth <mauriciofauth@gmail.com>
2018-11-26 20:59:58 -02:00
Michal Čihař
4fe87fb592 Remove usage of $GLOBALS['controllink']
This is now stored internally inside DatabaseInterface instance.

Signed-off-by: Michal Čihař <michal@cihar.com>
2017-10-25 10:21:18 +02:00
Michal Čihař
60c1b32472 Remove usage of $GLOBALS['userlink']
The links are internal to DatabaseInterface and user link is default.

Signed-off-by: Michal Čihař <michal@cihar.com>
2017-10-25 10:21:18 +02:00
Madhura Jayaratne
d53f394fc4 Fix charset description
Signed-off-by: Madhura Jayaratne <madhura.cj@gmail.com>
2017-10-07 22:26:55 +11:00
Madhura Jayaratne
fff3eabedf Update dummy dbi queries and results
Signed-off-by: Madhura Jayaratne <madhura.cj@gmail.com>
2017-10-07 20:53:39 +11:00
Michal Čihař
ad99c4ac4b Remove unused define PMA_MYSQL_CLIENT_API
Remove PMA_MYSQL_CLIENT_API and all logic for defining it.

Signed-off-by: Michal Čihař <michal@cihar.com>
2017-09-06 14:46:57 +02:00
Michal Čihař
bc6486e2e0 Move mysqli flag description sot Dbi class
Signed-off-by: Michal Čihař <michal@cihar.com>
2017-09-06 14:46:56 +02:00
Michal Čihař
339d42ca5d Remove no longer used PMA_MARIADB define
Signed-off-by: Michal Čihař <michal@cihar.com>
2017-07-17 15:02:49 +02:00
Maurício Meneghini Fauth
d9ac1865a2 Rename DBI include files
Signed-off-by: Maurício Meneghini Fauth <mauriciofauth@gmail.com>
2017-07-15 16:44:54 -03:00
Maurício Meneghini Fauth
6c6e86927a Move DBI classes to PhpMyAdmin namespace
Signed-off-by: Maurício Meneghini Fauth <mauriciofauth@gmail.com>
2017-07-15 15:52:10 -03:00
Maurício Meneghini Fauth
13c0f7bc3c Move classes to PhpMyAdmin namespace
- Move Advisor to PhpMyAdmin namespace
- Move Bookmark to PhpMyAdmin namespace
- Move Charsets to PhpMyAdmin namespace
- Move Config class to PhpMyAdmin namespace
- Move Console class to PhpMyAdmin namespace
- Move Core to PhpMyAdmin namespace
- Move DatabaseInterface to PhpMyAdmin namespace
- Move DbList to PhpMyAdmin namespace
- Move DbQbe to PhpMyAdmin namespace
- Move DbSearch to PhpMyAdmin namespace
- Move DisplayResults to PhpMyAdmin namespace
- Move Encoding to PhpMyAdmin namespace
- Move Error to PhpMyAdmin namespace
- Move ErrorHandler to PhpMyAdmin namespace
- Move File to PhpMyAdmin namespace
- Move Font to PhpMyAdmin namespace
- Move Footer to PhpMyAdmin namespace
- Move Header to PhpMyAdmin namespace
- Move Index to PhpMyAdmin namespace
- Move IndexColumn to PhpMyAdmin namespace
- Move LanguageManager to PhpMyAdmin namespace
- Move Language to PhpMyAdmin namespace
- Move Linter to PhpMyAdmin namespace
- Move ListAbstract to PhpMyAdmin namespace
- Move ListDatabase to PhpMyAdmin namespace

Signed-off-by: Maurício Meneghini Fauth <mauriciofauth@gmail.com>
2017-06-28 21:17:18 -03:00
Michal Čihař
b7a87ce156 Adjust tests to new column selection code
Signed-off-by: Michal Čihař <michal@cihar.com>
2017-03-01 15:57:18 +01:00
Michal Čihař
bb95ecf852 Extend Dummy driver to be able to inject expected queries results
Signed-off-by: Michal Čihař <michal@cihar.com>
2017-03-01 10:52:37 +01:00
Isaac Bennetch
7b4068da7d Fix undefined index warning with some SSL connections and ssl_ca_paths.
Fixes #12929

Signed-off-by: Isaac Bennetch <bennetch@gmail.com>
2017-01-28 23:06:46 -05:00
Michal Čihař
eafd5a5d93 Simplify mysqli database connection
- there is no need for _realConnect here as we call just one
  function in all cases (compared to mysql) backend
- properly pass connection flags (see #12898)

Signed-off-by: Michal Čihař <michal@cihar.com>
2017-01-18 09:47:47 +01:00
Michal Čihař
aabf306510 Merge branch 'QA_4_6' 2017-01-02 16:07:59 +01:00
Michal Čihař
d018add94b Set MySQL SSL parameters even if key is not set
User might want to set any of the SSL parameters without needing to set
the key.

Fixes #12293

Signed-off-by: Michal Čihař <michal@cihar.com>
2017-01-02 16:06:09 +01:00
Michal Čihař
dad93483c1 Merge branch 'QA_4_6' 2016-11-10 11:08:36 +01:00
Deven Bansod
f14cffdbe7 Properly escape strings in MySQL statement values
Use *_real_escape string functions provided by connectors to escape strings while exporting

Fix #12453

Signed-off-by: Deven Bansod <devenbansod.bits@gmail.com>

Conflicts:
	libraries/server_privileges.lib.php
2016-10-29 10:45:12 +05:30
Deven Bansod
5f84046759 Make PHPCS happy
Signed-off-by: Deven Bansod <devenbansod.bits@gmail.com>
2016-09-29 09:21:50 +05:30
Deven Bansod
ea5cc4a028 Merge branch 'QA_4_6' 2016-09-05 23:00:24 +05:30
Deven Bansod
6bcc593c84 Fix 'Unsupported query' message from Travis logs
Signed-off-by: Deven Bansod <devenbansod.bits@gmail.com>
2016-09-05 23:00:12 +05:30
Michal Čihař
44f5b605ae Merge branch 'QA_4_6' 2016-08-28 10:31:28 +02:00
Michal Čihař
38ce0c9d44 Remove unused paramenter when connecting to MySQLi
Fixes #12502

Signed-off-by: Michal Čihař <michal@cihar.com>
2016-08-28 10:30:32 +02:00
Michal Čihař
aebbb31aad Merge branch 'master' into master-security 2016-07-29 14:08:23 +02:00
Michal Čihař
f2e179b750 Simplify DBI code as $server no longer can be null
Signed-off-by: Michal Čihař <michal@cihar.com>
2016-07-29 12:21:06 +02:00
Michal Čihař
061c620723 Generate connection settings at one place
Signed-off-by: Michal Čihař <michal@cihar.com>
2016-07-29 12:19:40 +02:00
Michal Čihař
9592f66bd5 Share socket/port/host sanitization in DatabaseInterface
Signed-off-by: Michal Čihař <michal@cihar.com>
2016-07-29 12:09:26 +02:00
Michal Čihař
f46fd34081 Remove is_controluser flag from DBI backends
They no longer need it (it was used only for empty password fallback).

Signed-off-by: Michal Čihař <michal@cihar.com>
2016-07-29 11:34:55 +02:00
Michal Čihař
53f541af86 Removed MySQL connection retry without password
This really does not make sense for any decent setup. It is useful only
with http authentication, but still no password is not something we
would want to automatically fall back to.

Signed-off-by: Michal Čihař <michal@cihar.com>
2016-07-29 11:30:32 +02:00
Michal Čihař
bee2805b34 Remove auxiliary_connection flag from DBI backends
They do not use it anyway.

Signed-off-by: Michal Čihař <michal@cihar.com>
2016-07-29 11:23:29 +02:00
Michal Čihař
360b8e8a11 Merge branch 'master' into master-security 2016-07-28 09:44:08 +02:00
Michal Čihař
d31ff5a1e7 Merge branch 'QA_4_6' into QA_4_6-security 2016-07-28 09:43:26 +02:00
Michal Čihař
6d8e1d7935 Merge branch 'QA_4_6' 2016-07-28 09:38:08 +02:00
Michal Čihař
257e65ba9f Use https for outbound links where applicable
Signed-off-by: Michal Čihař <michal@cihar.com>
2016-07-28 09:19:13 +02:00
Michal Čihař
fce934bdb4 Merge branch 'QA_4_6-security' into master-security 2016-07-23 09:40:39 +02:00
Michal Čihař
1e6b740e6f Enable LOAD DATA LOCAL INFILE only when needed
There is no need to have this feature allowed for normal SQL queries, it
can lead to leaking sensitive files from the web server. It's enough to
enable it only in LDI import plugin, where we control what queries are
executed.

Signed-off-by: Michal Čihař <michal@cihar.com>
2016-07-23 09:02:31 +02:00
Michal Čihař
5bc426742d Merge branch 'QA_4_6' 2016-06-06 11:47:37 +02:00
Michal Čihař
5e536ab5f9 Do not set key if not set in config
Issue #12293

Signed-off-by: Michal Čihař <michal@cihar.com>
2016-06-06 11:47:16 +02:00
Michal Čihař
8ee70dfa08 Merge branch 'QA_4_6' 2016-06-06 09:33:22 +02:00
Michal Čihař
171bcb9a85 Fix MySQL SSL connection with some PHP versions
It seems that for some PHP versions this flag is needed even though it's
not documented like this. Anyway this flag doesn't cause any harm, so
lets keep it enabled.

Issue #12293

Signed-off-by: Michal Čihař <michal@cihar.com>
2016-06-06 09:32:47 +02:00
Michal Čihař
f3925a8b7c Merge branch 'QA_4_6' 2016-06-03 15:22:29 +02:00
Michal Čihař
2ae8b9248e Simplify server port handling
The intval function does return 0 for empty string, so we really do not
have to special case here.

Issue #12279

Signed-off-by: Michal Čihař <michal@cihar.com>
2016-06-03 15:21:48 +02:00
Michal Čihař
e9614da53a Merge branch 'QA_4_6' 2016-06-03 14:32:00 +02:00
Michal Čihař
d11185f5de Fixed error reporting on connect problems
The mysqli_real_connect seems to return NULL on invalid parameters, so
we need to handle it as well. This doesn't seem to be documented
anywhere.

Issue #12279

Signed-off-by: Michal Čihař <michal@cihar.com>
2016-06-03 14:24:45 +02:00
Michal Čihař
aaa707ab4d Merge branch 'QA_4_6' 2016-05-17 10:18:52 +02:00
Michal Čihař
11089cbe41 Use https for links to dev.mysql.com
Signed-off-by: Michal Čihař <michal@cihar.com>
2016-05-17 10:16:44 +02:00
Michal Čihař
d014c2893a Merge branch 'QA_4_6' 2016-04-20 10:09:24 +02:00
Michal Čihař
e0724d2660 Fixed check for ndb version
Fixes #12200

Signed-off-by: Michal Čihař <michal@cihar.com>
2016-04-20 10:07:06 +02:00