Commit graph

1247 commits

Author SHA1 Message Date
Alexander Barkov
a0d3a351b8 MDEV-20790 CSV table with INET6 can be created and inserted into, but cannot be read from 2019-10-11 22:51:01 +04:00
Alexander Barkov
5d6d28f274 MDEV-20798 Conversion from INET6 to other types performed without errors or warnings 2019-10-11 22:19:30 +04:00
Alexander Barkov
d8e599bb80 MDEV-20808 CAST from INET6 to FLOAT does not produce an error 2019-10-11 20:12:24 +04:00
Alexander Barkov
b5fae7f743 MDEV-20795 CAST(inet6 AS BINARY) returns wrong result 2019-10-11 14:50:11 +04:00
Marko Mäkelä
d04f2de80a Merge 10.4 into 10.5 2019-10-11 08:41:36 +03:00
Alexander Barkov
312ba3cc3d MDEV-20783 INET6 cannot be converted to BINARY(16) 2019-10-10 08:12:14 +04:00
Alexander Barkov
b37386d854 MDEV-20785 Converting INET6 to CHAR(39) produces garbage without a warning 2019-10-09 22:25:58 +04:00
Alexander Barkov
c78ae293b4 Adding missing "override" keywords, to make clang happy. 2019-10-09 13:39:27 +04:00
Alexander Barkov
6ea5c2b5b6 MDEV-274 The data type for IPv6/IPv4 addresses in MariaDB 2019-10-08 23:42:02 +04:00
Alexander Barkov
a07be05302 Fixing --ps test failures in "MDEV-20016 Add MariaDB_DATA_TYPE_PLUGIN" 2019-10-08 08:29:09 +04:00
Alexander Barkov
6afb2a37fd MDEV-20768 Turn INET functions into a function collection plugin 2019-10-07 23:17:21 +04:00
Alexander Barkov
cbf6beba40 MDEV-20764 Add MariaDB_FUNCTION_COLLECTION_PLUGIN 2019-10-07 11:31:32 +04:00
Alexander Barkov
c717483c9d MDEV-20016 Add MariaDB_DATA_TYPE_PLUGIN 2019-10-04 22:14:44 +04:00
Sergei Golubchik
b710d01dc7 mark PAMv2 plugin stable 2019-10-04 15:58:47 +02:00
Alexander Barkov
102bc7beb0 Fixing tests according to MDEV-20655 maturity stable for user_variables 2019-09-24 19:24:32 +04:00
Rasmus Johansson
fa9e012a34
MDEV-20655 maturity stable for user_variables 2019-09-24 14:37:01 +03:00
Marko Mäkelä
780d2bb8a7 Merge 10.4 into 10.5 2019-09-06 14:25:20 +03:00
Oleksandr Byelkin
4f10d0918d Merge branch '10.3' into 10.4 2019-09-02 14:57:05 +02:00
Alexander Barkov
afe6eb499d Revert "MDEV-20342 Turn Field::flags from a member to a method"
This reverts commit e86010f909.

Reverting on Monty's request, as this change makes merging
things from 10.5 to 10.2 much harder.
2019-08-14 20:27:00 +04:00
Alexander Barkov
e86010f909 MDEV-20342 Turn Field::flags from a member to a method 2019-08-14 13:33:01 +04:00
Alexander Barkov
c1599821a5 Merge remote-tracking branch 'origin/10.4' into 10.5 2019-08-13 23:49:10 +04:00
Marko Mäkelä
624dd71b94 Merge 10.4 into 10.5 2019-08-13 18:57:00 +03:00
Monty
05619f6989 Fixes based on warnings from gcc/clang and valgrind
- Initialize variables that could be used uninitialized
- Added extra end space to DbugStringItemTypeValue to get rid of warnings
  from c_ptr()
- Session_sysvars_tracker::update() accessed unitialized memory if called
  with NULL value.
- get_schema_stat_record() accessed unitialized memory if HA_KEY_LONG_HASH
  was used
- parse_vcol_defs() accessed random memory for tables without keys.
2019-08-12 10:48:38 +03:00
Alexey Botchkov
e244652831 MDEV-20246 Error compiling PAM plugin.
Ignore the setreuid() return here.
2019-08-03 01:02:32 +04:00
Oleksandr Byelkin
2792c6e7b0 Merge branch '10.3' into 10.4 2019-07-28 13:43:26 +02:00
Oleksandr Byelkin
d97342b6f2 Merge branch '10.2' into 10.3 2019-07-26 22:42:35 +02:00
Eugene Kosov
4c7a743964 Merge 10.3 into 10.4 2019-07-26 15:22:31 +03:00
Oleksandr Byelkin
cf8c2a3c3b Merge branch '10.1' into 10.2 2019-07-26 07:03:39 +02:00
Alexey Botchkov
51d58f566a MDEV-18350 Using audit plugin with MySQL, mysqld crashes when running COM_INIT_DB against invalid database.
mysql_event_general structure changed in 10.3.
the database_length should be size_t now instead of the int.
2019-07-26 08:44:43 +04:00
Marko Mäkelä
e9c1701e11 Merge 10.3 into 10.4 2019-07-25 18:42:06 +03:00
Oleksandr Byelkin
ae476868a5 Merge branch '5.5' into 10.1 2019-07-25 13:27:11 +02:00
Anushree Prakash B
9c6777c03c Bug#27259654 - ISSUES FOUND BY PVS-STUDIO STATIC ANALYZER
DESCRIPTION
===========
PVS-Studio static code analyzer found several suspicious
fragments of code across various files.

i)   sizeof() is using the pointer
ii)  memcpy() doesn't copy the whole string.
iii) enumeration constant 'wkb_multilinestring' is used as
     a variable of a Boolean-type.
iv) 'throw' keyword is missing from std::runtime_error()

FIX
===
i)   Use sizeof({actual object/data type})
ii)  Use strncpy() and set last char as '\0'
iii) N/A (Issue has already been fixed)
iv)  Add 'throw' before the exception.

RB: 21502
2019-07-24 18:32:24 +02:00
Marko Mäkelä
70b226d966 Merge 10.2 into 10.3 2019-07-22 17:37:04 +03:00
Julius Goryavsky
1f54b662ae The test for the wsrep_info plugin needs the same flexible wsrep version checking as the tests for Galera (continuation of MDEV-18565 task) 2019-07-22 12:24:01 +02:00
Julius Goryavsky
abeacb9c82 The test for the wsrep_info plugin needs the same flexible wsrep version checking as the tests for Galera (continuation of MDEV-18565 task) 2019-07-22 12:20:49 +02:00
Julius Goryavsky
f27a00435b The test for the wsrep_info plugin needs the same flexible wsrep version checking as the tests for Galera (continuation of MDEV-18565 task) 2019-07-22 12:16:39 +02:00
Oleksandr Byelkin
e2bbb6f5e9 switch to CC 3.1 2019-07-20 09:09:28 +02:00
Pali
5cc2096f93 Switch Perl DBI scripts from DBD::mysql to DBD::MariaDB driver
Perl DBD::MariaDB driver is available CPAN and is already used in
production environment.
2019-07-19 13:39:20 +03:00
Eugene Kosov
0f83c8878d Merge 10.2 into 10.3 2019-07-16 18:39:21 +03:00
Alexander Barkov
feb2695ed3 MDEV-20004 Move Field_geom from field.cc to sql_type_geom.cc 2019-07-09 19:47:57 +04:00
Eugene Kosov
26c389b7b7 Merge 10.1 into 10.2 2019-07-09 13:22:22 +03:00
Sergey Vojtovich
0940e25d69 MDEV-19991 Turn I_S tables GEOMETRY_COLUMNS and SPATIAL_REF_SYS into a plugin
Cleanups.
2019-07-09 13:02:52 +04:00
Alexander Barkov
a179de0402 MDEV-19991 Turn I_S tables GEOMETRY_COLUMNS and SPATIAL_REF_SYS into a plugin 2019-07-09 06:27:40 +04:00
HF
02a0ebc613 Make Win compiler happy about the SERVER_AUDIT code. 2019-07-06 12:22:45 +01:00
HF
d04961cdb3 Make Win compiler happy. 2019-07-05 12:22:04 +01:00
Vladislav Vaintroub
bd917e0811 Fix clang-cl warnings 2019-07-04 10:27:10 +02:00
Alexey Botchkov
a099284b71 MDEV-19851 server_audit plugin should not allow server_audit_output_type=SYSLOG on Windows.
'syslog' output type disabled on Windows.
2019-07-03 16:41:01 +04:00
Marko Mäkelä
7a3d34d645 Merge 10.3 into 10.4 2019-07-02 21:44:58 +03:00
Marko Mäkelä
e82fe21e3a Merge 10.2 into 10.3 2019-07-02 17:46:22 +03:00
Sergei Golubchik
4f87ad1975 MDEV-19879 server can send empty error message to client with pam_use_cleartext_plugin
fixed in MDEV-19878, here just adding tests
2019-07-02 14:27:31 +02:00
Sergei Golubchik
3914a792d8 MDEV-19880 pam v1: pam password authentication doesn't work at all in MariaDB 10.4
* fix incorrect parentheses
* if there was no password on the command line or in .cnf file,
  pkt will be "", and we need to request the user to enter the password
2019-07-02 14:27:31 +02:00
Sergei Golubchik
dd93028dae MDEV-19878 pam v2: pam password authentication doesn't work at all
* wait() for the child process to die, let it rest in peace
* fix incorrect parentheses
* if there was no password on the command line or in .cnf file,
  pkt will be "", and we need to request the user to enter the password
* make sure that auth->salt is always allocated on a permanent memroot.
  when called from set_user_salt_if_needed(), user_copy and its auth_str
  are on the thd memroot, but auth_copy->salt is then copied to auth->salt
* adjust service files so that systemd wouldn't interfere with our
  setuid executables

also
* print the pam error message in debug mode
2019-07-02 14:27:31 +02:00
Sergei Golubchik
a07c10f53f build pam test module as a part of the build
and install in mysql-test/suite/plugins/pam
so that it could be manually copied into /etc if needed
2019-07-02 14:27:31 +02:00
Sergei Golubchik
9c74cc4df7 Alter pam test to ask for a password first
this matches the common behavior with pam_unix and helps to
catch password related errors

also, use abort() instead of sigsegv to avoid polluting
/var/log/messages with intentional crashes
2019-07-02 14:27:31 +02:00
Eugene Kosov
ddeeb42e0b Merge 10.1 into 10.2 2019-06-23 20:33:13 +03:00
Oleksandr Byelkin
d1fa6ba845 MDEV-18328: Make DISKS plugin check some privilege to access information_schema.DISKS table
Check FILE privelege.
2019-06-19 10:19:17 +02:00
Marko Mäkelä
3c88ce4cd1 Merge 10.4 into 10.5 2019-06-18 11:30:06 +03:00
Sergei Golubchik
f02bc3cf0f change pam and disks plugin maturity beta->gamma 2019-06-17 12:26:26 +02:00
Alexander Barkov
4156b1a260 MDEV-19772 Add helper classes for ST_FIELD_INFO 2019-06-16 19:03:47 +04:00
Alexey Botchkov
65e0c9b91b MDEV-18661 loading the audit plugin causes performance regression.
Plugin fixed to not lock the LOCK_operations when not active.
Server fixed to lock the LOCK_plugin less - do it once per
thread and then only if a plugin was installed/uninstalled.
2019-06-15 01:02:55 +04:00
Oleksandr Byelkin
f66d1850ac Merge branch '10.3' into 10.4 2019-06-14 22:10:50 +02:00
Oleksandr Byelkin
4a3d51c76c Merge branch '10.2' into 10.3 2019-06-14 07:36:47 +02:00
Marko Mäkelä
984d7100cd Merge 10.4 into 10.5 2019-06-13 18:36:09 +03:00
Marko Mäkelä
90fec9602f Merge 10.1 into 10.2 2019-06-12 16:28:45 +03:00
sjaakola
efc3cb9322 MDEV-19563 Removed references to deprecated option innodb_locks_unsafe_for_binlog
innodb_locks_unsafe_for_binlog variabe removed from wsrep_info test configuration and
recommendation to use this variable in README-wsrep was removed as well

Also relates to issue: MDEV-19544
2019-06-12 13:00:08 +03:00
Marko Mäkelä
2fd82471ab Merge 10.3 into 10.4 2019-06-12 08:37:27 +03:00
Marko Mäkelä
b42dbdbccd Merge 10.2 into 10.3 2019-06-11 13:00:18 +03:00
Vladislav Vaintroub
724aefa56d Fix linking error, for GNU linker. 2019-06-03 13:52:33 +02:00
Vladislav Vaintroub
e730ea1e3e Only link mysys_ssl when required.
Do not use TARGET_LINK_LIBRARIES(mysys mysys_ssl),
this means that mysys_ssl is linked to practically everything.
2019-06-03 09:55:59 +02:00
Marko Mäkelä
28fad39de7 Merge 10.4 into 10.5 2019-05-29 22:29:05 +03:00
Marko Mäkelä
f98bb23168 Merge 10.3 into 10.4 2019-05-29 22:17:00 +03:00
Marko Mäkelä
90a9193685 Merge 10.2 into 10.3 2019-05-29 11:32:46 +03:00
Marko Mäkelä
c0cd662b98 Merge 10.4 to 10.5 2019-05-27 11:08:51 +03:00
Alexander Barkov
9f23f8e598 MDEV-19599 Change db_name, table_name to LEX_CSTRING in Item_ident and Send_field 2019-05-26 09:49:13 +04:00
Marko Mäkelä
826f9d4f7e Merge 10.4 into 10.5 2019-05-23 10:32:21 +03:00
Marko Mäkelä
1a6f470464 MDEV-19544 Remove innodb_locks_unsafe_for_binlog
The transaction isolation levels READ COMMITTED and READ UNCOMMITTED
should behave similarly to the old deprecated setting
innodb_locks_unsafe_for_binlog=1, that is, avoid acquiring gap locks.

row_search_mvcc(): Reduce the scope of some variables, and clean up
the initialization and use of the variable set_also_gap_locks.
2019-05-23 10:25:12 +03:00
Vladislav Vaintroub
5e4b657dd4 MDEV-18531 : Use WolfSSL instead of YaSSL as "bundled" SSL/encryption library
- Add new submodule for WolfSSL
- Build and use wolfssl and wolfcrypt instead of yassl/taocrypt
- Use HAVE_WOLFSSL instead of HAVE_YASSL
- Increase MY_AES_CTX_SIZE, to avoid compile time asserts in my_crypt.cc
(sizeof(EVP_CIPHER_CTX) is larger on WolfSSL)
2019-05-22 13:48:25 +02:00
Alexey Botchkov
d4e9a50e88 MDEV-17456 Malicious SUPER user can possibly change audit log configuration without leaving traces.
Fix for the SET GLOBAL server_audit_loggin=on; added.
2019-05-19 23:50:23 +04:00
Oleksandr Byelkin
c07325f932 Merge branch '10.3' into 10.4 2019-05-19 20:55:37 +02:00
Marko Mäkelä
be85d3e61b Merge 10.2 into 10.3 2019-05-14 17:18:46 +03:00
Marko Mäkelä
26a14ee130 Merge 10.1 into 10.2 2019-05-13 17:54:04 +03:00
Oleksandr Byelkin
c51f85f882 Merge branch '10.2' into 10.3 2019-05-12 17:20:23 +02:00
Vicențiu Ciorbaru
cb248f8806 Merge branch '5.5' into 10.1 2019-05-11 22:19:05 +03:00
Vicențiu Ciorbaru
5543b75550 Update FSF Address
* Update wrong zip-code
2019-05-11 21:29:06 +03:00
Vicențiu Ciorbaru
c0ac0b8860 Update FSF address 2019-05-11 19:25:02 +03:00
Vicențiu Ciorbaru
f177f125d4 Merge branch '5.5' into 10.1 2019-05-11 19:15:57 +03:00
Michal Schorm
17b4f99928 Update FSF address
This commit is based on the work of Michal Schorm, rebased on the
earliest MariaDB version.

Th command line used to generate this diff was:

find ./ -type f \
  -exec sed -i -e 's/Foundation, Inc., 59 Temple Place, Suite 330, Boston, /Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, /g' {} \; \
  -exec sed -i -e 's/Foundation, Inc. 59 Temple Place.* Suite 330, Boston, /Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, /g' {} \; \
  -exec sed -i -e 's/MA.*.....-1307.*USA/MA 02110-1335 USA/g' {} \; \
  -exec sed -i -e 's/Foundation, Inc., 59 Temple/Foundation, Inc., 51 Franklin/g' {} \; \
  -exec sed -i -e 's/Place, Suite 330, Boston, MA.*02111-1307.*USA/Street, Fifth Floor, Boston, MA 02110-1335 USA/g' {} \; \
  -exec sed -i -e 's/MA.*.....-1307/MA 02110-1335/g' {} \;
2019-05-10 20:52:00 +03:00
Marko Mäkelä
d3dcec5d65 Merge 10.3 into 10.4 2019-05-05 15:06:44 +03:00
Oleksandr Byelkin
8cbb14ef5d Merge branch '10.1' into 10.2 2019-05-04 17:04:55 +02:00
Marko Mäkelä
447b8ba164 Merge 10.2 into 10.3 2019-04-29 17:54:10 +03:00
Marko Mäkelä
cc359eae3b Remove a type cast, and use correct format instead 2019-04-29 09:24:59 +03:00
Alexey Botchkov
bb4f4b3a1b Make Win compiler happy. 2019-04-29 02:32:13 +04:00
Alexey Botchkov
a529188e05 MDEV-17456 Malicious SUPER user can possibly change audit log configuration without leaving traces.
The 'SET server_audit_logging ' statements should be logged no matter
what.
2019-04-29 01:25:17 +04:00
Alexey Botchkov
cd26cdcd97 MDEV-19141 server_audit_excl_users accepts only values with less than 1024 chars.
Since this limit is imposed by the SHOW_VAR_FUNC_BUFF_SIZE, we just
launch the error message.
2019-04-29 00:11:48 +04:00
Sergei Golubchik
9ca3571cb8 MDEV-18686 Add option to PAM authentication plugin to allow case insensitive username matching
add a new option --pam-windbind-workaround for a pam plugin to
work around pam_winbind unconditional username lowercasing
2019-04-24 16:06:54 +02:00
Marko Mäkelä
c8f8d5ceb7 Merge 10.3 into 10.4 2019-04-03 11:43:39 +03:00
Marko Mäkelä
c6b8b05be4 Merge 10.2 into 10.3 2019-04-03 11:22:51 +03:00
Marko Mäkelä
dbc716675b Merge 10.1 into 10.2 2019-04-03 10:32:21 +03:00
Sergei Golubchik
7b527e6334 cmake: fix krb5 detection on SUSE
`zypper install krb5-devel` installs executables outside of $PATH.
It also installs /etc/profile.d/krb5.sh that is sourced by a new
shell to add the new location to the $PATH. But this doesn't affect
the current shell.

Now decent Linux distros remind the user to run `. /etc/profile`
to reload paths in such a case. SUSE doesn't and for a good reason -
it doesn't work there. Because SUSE sets PROFILEREAD=true in the
environment and /etc/profile does not do anything.

By this point, one should not really expect `unset PROFILEREAD` to help,
and it does not - PROFILEREAD is readonly, and cannot be unset.

Apparently SUSE really *really* wants you to re-login between installing
MariaDB build dependencies and actually running the rpmbuild.

Which we cannot do it buildbot. And it would look very user-un-friendly
in the Build Instructions section of the manual.

So, we work around it - by adding SUSE krb5 path to the search list.

THIS IS SUSEEEEEE!!!
2019-04-02 18:22:37 +02:00
Marko Mäkelä
f3adfcb523 After-merge fix: Initialize all fields 2019-04-02 11:59:55 +03:00
Marko Mäkelä
5c3ff5cb93 Merge 10.3 into 10.4 2019-04-02 11:04:54 +03:00
Sergei Golubchik
4e1d3f83b7 Merge branch '10.2' into 10.3 2019-03-29 19:41:41 +01:00
Sergei Golubchik
f2a0c758da Merge branch '10.1' into 10.2 2019-03-29 10:58:20 +01:00
Sergei Golubchik
d8084116b5 MDEV-7066 No Source RPMs ... (and so no "yum-builddep MariaDB-server" either)
special cases:

* change systemd detection to use CHECK_LIBRARY_EXISTS at least once,
  to have it detected by build_depends.cmake
* similarly, use find_library for pam
* unixODBC is weird, libodbc.so is in the unixODBC package, not
  in the unixODBC-devel, where normally all .so files belong.
  Packaging bug? As a workaround, use find_file(sql.h) instead of
  find_path(sql.h) to make sure that /usr/include/sql.h (not /usr/include)
  is cached by cmake, and later build_depends.cmake will select
  unixODBC-devel, as a package owning /usr/include/sql.h file.
2019-03-27 22:51:37 +01:00
Marko Mäkelä
ca80e14a88 Merge 10.3 into 10.4 2019-03-22 13:20:44 +02:00
Alexander Barkov
1c60f40868 Merge remote-tracking branch 'origin/10.2' into 10.3 2019-03-22 14:41:36 +04:00
Marko Mäkelä
031fa8f1d2 Merge 10.1 into 10.2 2019-03-22 11:15:21 +02:00
Marko Mäkelä
8c493a910f Merge 10.0 into 10.1 2019-03-21 21:06:01 +02:00
Marko Mäkelä
5d454181a8 MDEV-6262 follow-up: Ensure NUL termination on strncpy() 2019-03-21 10:29:59 +02:00
Sergei Golubchik
83de75d66d try harder to link unix_socket plugin statically
fix unix_socket tests to work if unix_socket is a built-in
2019-02-21 15:04:03 +01:00
Oleksandr Byelkin
93ac7ae70f Merge branch '10.3' into 10.4 2019-02-21 14:40:52 +01:00
Oleksandr Byelkin
00906719fe Merge branch '10.2' into bb-10.3-merge 2019-02-19 17:26:44 +01:00
Oleksandr Byelkin
91d506cf2d Merge branch '10.1' into 10.2 2019-02-19 16:47:45 +01:00
Sergei Golubchik
2de0b57dd1 Don't build aws_key_management plugin by default 2019-02-19 12:39:40 +01:00
Vladislav Vaintroub
3220227794 MDEV-18578 build aws sdk for all plugins to use 2019-02-18 07:52:13 +01:00
Oleksandr Byelkin
dcc838168f Merge branch '10.3' into bb-10.3-merge 2019-02-12 12:05:10 +01:00
Marko Mäkelä
9f56dd7382 Merge 10.3 into 10.4 2019-02-11 17:55:25 +02:00
Oleksandr Byelkin
65c5ef9b49 dirty merge 2019-02-07 13:59:31 +01:00
Monty
129b2dcef3 Changed user_variables and sql_sequence to maturity state stable 2019-02-06 22:18:20 +02:00
Sergei Golubchik
5b15cc613e MDEV-11340 Allow multiple alternative authentication methods for the same user
introduce the syntax

... IDENTIFIED { WITH | VIA }
      plugin [ { USING | AS } auth ]
 [ OR plugin [ { USING | AS } auth ]
 [ OR ... ]]

Server will try auth plugins in the specified order until the first
success. No protocol changes, server uses the existing "switch plugin"
packet.

The auth chain is stored in json as

  "auth_or":[{"plugin":"xxx","authentication_string":"yyy"},
             {},
             {"plugin":"foo","authentication_string":"bar"},
            ...],
  "plugin":"aaa", "authentication_string":"bbb"

Note:
* "auth_or" implies that there might be "auth_and" someday;
* one entry in the array is an empty object, meaning to take plugin/auth
  from the main json object. This preserves compatibility with
  the existing mysql.global_priv table and with the mysql.user view.
  This entry is preferrably a mysql_native_password plugin for a
  non-empty mysql.user.password column.

SET PASSWORD is supported and changes the password for the *first*
plugin in the chain that has a notion of a "password"
2019-02-04 16:06:57 +01:00
Sergei Golubchik
798d1a9ddf upgrade C/C to 3.1 2019-02-04 16:06:31 +01:00
Sergei Golubchik
103a32fdd3 ed25519: better error message for an incorrect password hash 2019-02-04 15:54:10 +01:00
Sergei Golubchik
c94ec9fc67 MDEV-17950 SHOW GRANTS FOR does not work for a user identified with non-existing plugin
Revert the side effect of 7c40996cc8.
Do not convert password hash to its binary representation when a user
entry is loaded. Do it lazily on the first authenticatation attempt.

As a collateral - force all authentication plugins to follow the
protocol and read_packet at least once before accessing info->username
(username is not available before first client handshake packet is read).

Fix PAM and GSSAPI plugins to behave.
2019-02-04 15:54:10 +01:00
Sergei Golubchik
3742f6f9aa cleanup: use only one callback in PAM plugin, not two 2019-02-04 15:54:10 +01:00
Marko Mäkelä
081fd8bfa2 Merge 10.1 into 10.2 2019-02-02 11:40:02 +02:00
Oleksandr Byelkin
a3a4ea9355 postmerge rollbacks and fixes 2019-01-31 19:28:38 +01:00
Sergey Vojtovich
8553525931 MDEV-18400 - Move shutdown handling to main thread
Signal handler is now respoinsible for setting abort_loop and breaking
poll() in main thread. The rest is handled by main thread itself.

Removed redundant LOCK_error_log init/destroy wrappers.
Removed redundant unireg_end(): it is trivial and it has only one caller.
Removed unused ready_to_exit from PFS.
Removed kill_in_progress: duplicates abort_loop.
Removed shutdown_in_progress: duplicates abort_loop.
Removed ready_to_exit: was used to make sure main thread waits for
cleanups, which are now done by main thread itself.
Removed SIGNALS_DONT_BREAK_READ, MAYBE_BROKEN_SYSCALL,
kill_broken_server: never defined/used.
Make clean_up() static.
2019-01-29 11:56:35 +04:00
Sergey Vojtovich
3503fbbebf Move THD list handling to THD_list
Implemented and integrated THD_list as a replacement for the global
thread list. It uses own mutex instead of LOCK_thread_count for THD
list protection.

Removed unused first_global_thread() and next_global_thread().

delayed_insert_threads is now protected by LOCK_delayed_insert. Although
this patch doesn't fix very wrong synchronization of this variable.

After this patch there are only 2 legitimate uses of LOCK_thread_count
left, both in mysqld.cc: thread_count and ready_to_exit.

Aim is to reduce usage of LOCK_thread_count and COND_thread_count.
Part of MDEV-15135.
2019-01-28 17:39:07 +04:00
Brave Galera Crew
36a2a185fe Galera4 2019-01-23 15:30:00 +04:00
Sergey Vojtovich
0f034e2e96 time_collector transition to std::atomic 2018-12-29 14:19:03 +04:00
Sergey Vojtovich
7a9dfdd8d9 Combine GLOBAL and COMMIT namespaces into BACKUP namespace.
Part of MDEV-5336 Implement LOCK FOR BACKUP

Other things:
- Added printing of MDL locks to DBUG.
2018-12-09 22:12:26 +02:00
Marko Mäkelä
074c684099 Merge 10.3 into 10.4 2018-11-06 16:24:16 +02:00
Marko Mäkelä
df563e0c03 Merge 10.2 into 10.3
main.derived_cond_pushdown: Move all 10.3 tests to the end,
trim trailing white space, and add an "End of 10.3 tests" marker.
Add --sorted_result to tests where the ordering is not deterministic.

main.win_percentile: Add --sorted_result to tests where the
ordering is no longer deterministic.
2018-11-06 09:40:39 +02:00
Marko Mäkelä
32062cc61c Merge 10.1 into 10.2 2018-11-06 08:41:48 +02:00
Sergei Golubchik
7c40996cc8 MDEV-12321 authentication plugin: SET PASSWORD support
Support SET PASSWORD for authentication plugins.

Authentication plugin API is extended with two optional methods:
* hash_password() is used to compute a password hash (or digest)
  from the plain-text password. This digest will be stored in mysql.user
  table
* preprocess_hash() is used to convert this digest into some memory
  representation that can be later used to authenticate a user.
  Build-in plugins convert the hash from hexadecimal or base64 to binary,
  to avoid doing it on every authentication attempt.

Note a change in behavior: when loading privileges (on startup or on
FLUSH PRIVILEGES) an account with an unknown plugin was loaded with a
warning (e.g. "Plugin 'foo' is not loaded"). But such an account could
not be used for authentication until the plugin is installed. Now an
account like that will not be loaded at all (with a warning, still).
Indeed, without plugin's preprocess_hash() method the server cannot know
how to load an account. Thus, if a new authentication plugin is
installed run-time, one might need FLUSH PRIVILEGES to activate all
existing accounts that were using this new plugin.
2018-10-31 16:06:16 +01:00
Sergei Golubchik
0e388d43a7 cleanup: add 'const' to password validation API 2018-10-31 16:06:16 +01:00
Daniel Black
3859273d04 MDEV-14267: correct FSF address 2018-10-30 19:45:09 +08:00
Vladislav Vaintroub
5a5bc21a65 auth_gssapi : Fix string formatting in my_printf_error() 2018-10-16 09:19:03 +01:00
Vladislav Vaintroub
952f394f8e remove MYF flags from plugin 2018-10-16 09:17:03 +01:00
Vladislav Vaintroub
ea9c407e0b Fix regular expression in replace_regex in auth_gssapi test. 2018-10-15 23:07:30 +01:00
Vladislav Vaintroub
64b48aebe4 make auth_gssapi_basic work, also in domain environment. 2018-10-15 22:57:15 +01:00
Vladislav Vaintroub
311126758e MDEV-17462 Heap corruption with auth_gssapi on Windows.
use FreeContextAttributes() on individual members of
SecPkgContext_NativeNames, not on the struct itself.
2018-10-15 22:11:14 +01:00
Marko Mäkelä
2a955c7a83 Merge 10.3 into 10.4 2018-10-10 10:36:51 +03:00
Vladislav Vaintroub
f4cdf90d73 MDEV-17279 Windows : link C runtime dynamically
Changed the build to use /MD flag so that DDL version of C runtime is used.

To make sure MariaDB is always runnable on target system, include
redistributable CRT libraries into installer.

For MSI package, use Microsoft's merge modules.
For ZIP  use "applocal" approach,i.e place redistributable dlls
into the bin directory of the package(via InstallRequiredSystemLibraries
cmake module) The space overhead of libraries in negligible, ~ 3MB unpacked.

There are 2 cases, where we still link C runtime statically

- Upgrade wizard, it uses MFC, and we link statically to avoid
redistribute also whole MFC (for this single application, does not
make much sense).

- MSI installer's custom action dll wixca.dll.Here, we need static link
so that MSI won't fail on a target system that does not have VC++2015
runtime already installed.
2018-10-09 08:42:48 +01:00
Marko Mäkelä
43ee6915fa Merge 10.2 into 10.3 2018-10-09 09:11:30 +03:00
Vladislav Vaintroub
753117fed0 AWS KMS plugin : more detailed message when API calls fail.
Output API function name, exception name, exception text
2018-10-03 23:59:08 +02:00
Marko Mäkelä
1bf3e8ab43 Merge 10.3 into 10.4 2018-09-11 21:31:03 +03:00
Marko Mäkelä
2f4c391958 Merge 10.2 into 10.3 2018-09-06 22:35:45 +03:00
Marko Mäkelä
206528f722 Merge 10.1 into 10.2 2018-08-31 15:10:02 +03:00
Alexey Botchkov
c933970974 MDEV-16665 ed25519 describes itself as 1.0-alpha even though it's not alpha.
Plugin version name fixed.
2018-08-30 15:57:22 +04:00
Alexey Botchkov
2ad51a0bd8 MDEV-17095 pam_user_map module throws syntax error if group name contains backslash.
Let '\\' and '/' symbols to be part of a group name.
2018-08-30 14:51:15 +04:00
Marko Mäkelä
734db318ac Merge 10.3 into 10.4 2018-08-16 10:08:30 +03:00
Sergei Golubchik
456517b88e compiler warnings 2018-08-12 11:37:43 +02:00
Sergei Golubchik
675e7e7dcc remove obsolete checks for -fno-implicit-templates
we stopped using -fno-implicit-templates many years ago
2018-08-12 11:37:43 +02:00
Alexey Botchkov
25410d448d MDEV-15473 Isolate/sandbox PAM modules, so that they can't crash the server.
mysql_install_db.sh script fixed.
2018-07-14 23:06:49 +04:00
Oleksandr Byelkin
aa01f51bde Fix of feedback plugin.
Assign "SELECT" to the table before it usage.
2018-07-06 16:26:19 +02:00
Alexey Botchkov
efba0b1df5 MDEV-15473 Isolate/sandbox PAM modules, so that they can't crash the server.
New version of PAM plugin (v2.0) added along with the old v1.0.
There the pam module is isolated in the auth_pam_tool application so
cannot crash the server.
2018-07-03 15:49:34 +04:00
Alexander Barkov
e61568ee93 Merge remote-tracking branch 'origin/10.3' into 10.4 2018-07-03 14:02:05 +04:00
Sergei Golubchik
36e59752e7 Merge branch '10.2' into 10.3 2018-06-30 16:39:20 +02:00
Sergei Golubchik
1dd3c8f8ba Merge branch '10.1' into 10.2 2018-06-28 22:46:12 +02:00
Sergei Golubchik
16c14d7ba0 mark ed25519 stable 2018-06-28 15:46:57 +02:00
Sergei Golubchik
df704b5a1b don't use my_error(0) or my_printf_error(0)
there's an assert that catches it
2018-06-21 10:15:27 +02:00
Sergei Golubchik
ced6638773 mysys: ME_ERROR_LOG_ONLY flag 2018-06-04 12:32:23 +02:00
Sergei Golubchik
c9061d1102 mysys: rename ME_xxx flags to match plugin api 2018-06-04 12:32:23 +02:00
Marko Mäkelä
15419a5583 Merge 10.2 into 10.3 2018-05-12 22:14:59 +03:00
Eugene Kosov
fe10bf870c MDEV-15893 Rename VTQ to TRT 2018-05-12 10:16:46 +02:00
Marko Mäkelä
82f0dc35aa Merge 10.1 into 10.2 2018-05-11 18:33:58 +03:00
Alexey Botchkov
dab4abbb09 MDEV-15480 Audit plugin does not respect QUERY_DML for audit plugin.
QUERY_DML_NO_SELECT flag added.
2018-05-10 19:23:35 +04:00
Alexey Botchkov
3cbfe8cc47 MDEV-15480 Audit plugin does not respect QUERY_DML for audit plugin.
QUERY_DML_NO_SELECT flag added.
2018-05-10 19:17:06 +04:00
Alexey Botchkov
318097bb8f MDEV-15480 Audit plugin does not respect QUERY_DML for audit plugin.
QUERY_DML_NO_SELECT flag added.
2018-05-10 19:00:54 +04:00
luz.paz
3dd01669b4 Misc. typos
Found via `codespell -i 3 -w --skip="./debian/po" -I ../mariadb-server-word-whitelist.txt  ./cmake/ ./debian/ ./Docs/ ./include/ ./man/ ./plugin/ ./strings/`
2018-04-05 15:26:57 +04:00
Sergei Golubchik
b1818dccf7 Merge branch '10.2' into 10.3 2018-03-28 17:31:57 +02:00
Sergei Golubchik
c764bc0a78 Merge branch '10.1' into 10.2 2018-03-25 13:02:52 +02:00
Alexey Botchkov
0b74a1fa64 MDEV-14533 Provide information_schema tables using which hardware
information can be obtained.

plugin only enabled for Linux, as it fails building on BSD/MacOSX.
disks.test fixed.
2018-03-24 00:37:38 +04:00
Alexey Botchkov
3b644ac1f7 MDEV-14533 Provide information_schema tables using which hardware
information can be obtained.

disks.test moved to plugin's directory.
2018-03-24 00:30:28 +04:00
Sergei Golubchik
b6e2973ee6 MDEV-14533 Provide information_schema tables using which hardware information can be obtained.
update README, use maria_declare_plugin(), specify the author.
2018-03-23 00:55:19 +01:00
Alexey Botchkov
f5b2761c70 MDEV-10871 Add logging capability to pam_user_map.c.
The 'debug' option implemented for the pam_user_map.so.
2018-03-23 00:18:21 +04:00
Marko Mäkelä
3d7915f000 Merge 10.1 into 10.2 2018-03-21 22:58:52 +02:00
Alexey Botchkov
9652038453 MDEV-14533 Provide information_schema tables using which hardware
information can be obtained.

        DISKS plugin implementation added to the tree.
2018-03-21 12:33:38 +04:00
Alexander Barkov
583eb96c24 MDEV-11952 Oracle-style packages: stage#5
- CREATE PACKAGE [BODY] statements are now
  entirely written to mysql.proc with type='PACKAGE' and type='PACKAGE BODY'.
- CREATE PACKAGE BODY now supports IF NOT EXISTS
- DROP PACKAGE BODY now supports IF EXISTS
- CREATE OR REPLACE PACKAGE [BODY] is now supported
- CREATE PACKAGE [BODY] now support the DEFINER clause:

    CREATE DEFINER user@host PACKAGE pkg ... END;
    CREATE DEFINER user@host PACKAGE BODY pkg ... END;

- CREATE PACKAGE [BODY] now supports SQL SECURITY and COMMENT clauses, e.g.:

    CREATE PACKAGE p1 SQL SECURITY INVOKER COMMENT "comment" AS ... END;

- Package routines are now created from the package CREATE PACKAGE BODY
  statement and don't produce individual records in mysql.proc.

- CREATE PACKAGE BODY now supports package-wide variables.
  Package variables can be read and set inside package routines.
  Package variables are stored in a separate sp_rcontext,
  which is cached in THD on the first packate routine call.

- CREATE PACKAGE BODY now supports the initialization section.

- All public routines (i.e. declared in CREATE PACKAGE)
  must have implementations in CREATE PACKAGE BODY

- Only public package routines are available outside of the package

- {CREATE|DROP} PACKAGE [BODY] now respects CREATE ROUTINE and ALTER ROUTINE
  privileges

- "GRANT EXECUTE ON PACKAGE BODY pkg" is now supported

- SHOW CREATE PACKAGE [BODY] is now supported

- SHOW PACKAGE [BODY] STATUS is now supported

- CREATE and DROP for PACKAGE [BODY] now works for non-current databases

- mysqldump now supports packages

- "SHOW {PROCEDURE|FUNCTION) CODE pkg.routine" now works for package routines

- "SHOW PACKAGE BODY CODE pkg" now works (the package initialization section)

- A new package body level MDL was added

- Recursive calls for package procedures are now possible

- Routine forward declarations in CREATE PACKATE BODY are now supported.

- Package body variables now work as SP OUT parameters

- Package body variables now work as SELECT INTO targets

- Package body variables now support ROW, %ROWTYPE, %TYPE
2018-02-25 21:08:19 +04:00
Vladislav Vaintroub
56e7b7eaed Make possible to use clang on Windows (clang-cl)
-DWITH_ASAN can be used as well now, on x64

Fix many clang-cl warnings.
2018-02-20 21:17:36 +00:00
Marko Mäkelä
b006d2ead4 Merge bb-10.2-ext into 10.3 2018-02-15 10:22:03 +02:00
Alexander Barkov
3cad31f2a7 Merge remote-tracking branch 'origin/10.2' into bb-10.2-ext 2018-02-08 19:06:25 +04:00
Vladislav Vaintroub
53476abce8 Windows, compiling : use /permissive- switch to improve conformance
fix a couple "initialization skipped by goto" and other new errors.
2018-02-07 20:22:30 +00:00
Vladislav Vaintroub
282b652028 Windows, compiling : reenable warning C4996 (deprecated functions)
But set _CRT_NONSTDC_NO_WARNINGS to silence silly warnings about
ANSI C function being non-standard

Remove now deprecated GetVersion()/GetVersionEx(),except single case
where where it is really needed, in feedback plugin. Remove checks for
Windows NT.

Avoid old IPv4-only inet_aton, which generated the warning.
2018-02-07 20:17:38 +00:00
Vladislav Vaintroub
d995dd2865 Windows : reenable warning C4805 (unsafe mix of types in bool operations) 2018-02-07 20:12:12 +00:00
Sergei Golubchik
4771ae4b22 Merge branch 'github/10.1' into 10.2 2018-02-06 14:50:50 +01:00
Vladislav Vaintroub
502e2445e6 Fix warnings 2018-02-06 14:22:15 +01:00
Vladislav Vaintroub
6c279ad6a7 MDEV-15091 : Windows, 64bit: reenable and fix warning C4267 (conversion from 'size_t' to 'type', possible loss of data)
Handle string length as size_t, consistently (almost always:))
Change function prototypes to accept size_t, where in the past
ulong or uint were used. change local/member variables to size_t
when appropriate.

This fix excludes rocksdb, spider,spider, sphinx and connect for now.
2018-02-06 12:55:58 +00:00
Vladislav Vaintroub
27733c8b12 auth_gssapi - fix test result and let the test run on Windows buildbot 2018-02-01 12:50:58 +00:00
Monty
a7e352b54d Changed database, tablename and alias to be LEX_CSTRING
This was done in, among other things:
- thd->db and thd->db_length
- TABLE_LIST tablename, db, alias and schema_name
- Audit plugin database name
- lex->db
- All db and table names in Alter_table_ctx
- st_select_lex db

Other things:
- Changed a lot of functions to take const LEX_CSTRING* as argument
  for db, table_name and alias. See init_one_table() as an example.
- Changed some function arguments from LEX_CSTRING to const LEX_CSTRING
- Changed some lists from LEX_STRING to LEX_CSTRING
- threads_mysql.result changed because process list_db wasn't always
  correctly updated
- New append_identifier() function that takes LEX_CSTRING* as arguments
- Added new element tmp_buff to Alter_table_ctx to separate temp name
  handling from temporary space
- Ensure we store the length after my_casedn_str() of table/db names
- Removed not used version of rename_table_in_stat_tables()
- Changed Natural_join_column::table_name and db_name() to never return
  NULL (used for print)
- thd->get_db() now returns db as a printable string (thd->db.str or "")
2018-01-30 21:33:55 +02:00
Alexander Barkov
c7a2f23a7b Merge remote-tracking branch 'origin/bb-10.2-ext' into 10.3 2018-01-29 12:44:20 +04:00
Monty
84514ec643 Merge remote-tracking branch 'origin/10.2' into bb-10.2-ext
Conflicts:
	sql/table.cc
2018-01-27 15:20:01 +02:00
Vladislav Vaintroub
9891ee5a2a Fix and reenable Windows compiler warning C4800 (size_t conversion). 2018-01-26 10:37:46 +00:00
Sergei Golubchik
d20d7a92c0 make versioning plugin more clearly a test-only thing
rename to test_versioning
set maturity to experimental
2018-01-09 15:29:43 +03:00
Aleksey Midenkov
5c0a19c873 System Versioning 1.0 pre7
Merge branch '10.3' into trunk
2017-12-21 11:16:42 +03:00
Monty
2e53b96a0a Moved semisync from a plugin to normal server
Part of MDEV-13073 AliSQL Optimize performance of semisync

Did the following renames to match other similar variables
key_ss_mutex_LOCK_binlog_       > key_LOCK_bing
key_ss_cond_COND_binlog_send_  -> key_COND_binlog_send
COND_binlog_send_              -> COND_binlog_send
LOCK_binlog_                   -> LOCK_binlog

debian/mariadb-server-10.2.install does not install semisync libs.
2017-12-18 13:43:36 +02:00
Aleksey Midenkov
1668efb722 MDEV-14645: AS OF TIMESTAMP is misused as TRX_ID [fixes #396] 2017-12-14 18:14:21 +03:00
Aleksey Midenkov
79dd77e6ae System Versioning 1.0 pre3
Merge branch '10.3' into trunk
2017-12-11 15:43:41 +03:00
Monty
68cd543539 Search for galera libraries also in /usr/lib64/galera-3
This is where Codership's offical rpm's puts them
2017-12-08 11:38:22 +02:00
Monty
60df17e95a Remove compiler warnings 2017-12-03 13:58:36 +02:00
Aleksey Midenkov
33085349e9 IB, SQL: removed VTQ, added TRT on SQL layer [closes #305] 2017-11-15 00:22:10 +03:00
Aleksey Midenkov
497c6add88 System Versioning pre1.0
Merge branch '10.3' into trunk
2017-11-13 19:09:46 +03:00
Marko Mäkelä
a48aa0cd56 Merge bb-10.2-ext into 10.3 2017-11-10 16:12:45 +02:00
Monty
0bb0d52221 Merge remote-tracking branch 'origin/10.2' into bb-10.2-ext
Conflicts:
	mysql-test/r/cte_recursive.result
	mysql-test/r/derived_cond_pushdown.result
	mysql-test/t/cte_recursive.test
	mysql-test/t/derived_cond_pushdown.test
	sql/datadict.cc
	sql/handler.cc
2017-11-09 23:21:41 +02:00
Marko Mäkelä
843e4508c0 Merge 10.1 into 10.2 2017-11-07 23:02:39 +02:00
Aleksey Midenkov
d8d7251019 System Versioning pre0.12
Merge remote-tracking branch 'origin/archive/2017-10-17' into 10.3
2017-11-07 00:37:49 +03:00
Alexey Botchkov
6ceb49a941 MDEV-13921 Audit log writes invalid SQL if single-line comments are
present.

        thread_pool_server_audit.test fixed.
        plugin version updated.
2017-11-03 22:43:51 +04:00
Alexey Botchkov
1394ea6965 MDEV-13921 Audit log writes invalid SQL if single-line comments are
present.

        thread_pool_server_audit.test fixed.
        plugin version updated.
2017-11-03 22:40:44 +04:00
Alexey Botchkov
c64a697bba MDEV-13921 Audit log writes invalid SQL if single-line comments are
present.

        thread_pool_server_audit.test fixed.
        plugin version updated.
2017-11-03 22:36:58 +04:00
Alexey Botchkov
3a3f1328fe MDEV-13921 Audit log writes invalid SQL if single-line comments are
present.

        Escape special characters (like \r \n \t) instead of
        replacing them with spaces.
2017-11-03 17:15:55 +04:00
Alexey Botchkov
04daf30e9b MDEV-13921 Audit log writes invalid SQL if single-line comments are
present.

        Escape special characters (like \r \n \t) instead of
        replacing them with spaces.
2017-11-03 17:10:36 +04:00
Alexey Botchkov
2e964b233b MDEV-13921 Audit log writes invalid SQL if single-line comments are
present.

        Escape special characters (like \r \n \t) instead of
        replacing them with spaces.
2017-11-03 17:05:41 +04:00
Alexander Barkov
835cbbcc7b Merge remote-tracking branch 'origin/bb-10.2-ext' into 10.3
TODO: enable MDEV-13049 optimization for 10.3
2017-10-30 20:47:39 +04:00
Alexander Barkov
003cb2f424 Merge remote-tracking branch 'origin/10.2' into bb-10.2-ext 2017-10-30 16:42:46 +04:00
Sergei Golubchik
e0a1c745ec Merge branch '10.1' into 10.2 2017-10-24 14:53:18 +02:00
Sergei Golubchik
9d2e2d7533 Merge branch '10.0' into 10.1 2017-10-22 13:03:41 +02:00
Sergei Golubchik
da4503e956 Merge branch '5.5' into 10.0 2017-10-18 15:14:39 +02:00
Alexander Barkov
30e7d6709f Merge remote-tracking branch 'origin/10.2' into bb-10.2-ext 2017-10-18 14:11:55 +04:00
Sergei Golubchik
d76f5774fe MDEV-13459 Warnings, when compiling with gcc-7.x
mostly caused by -Wimplicit-fallthrough
2017-10-17 07:37:39 +02:00
Vladislav Vaintroub
dd85ec6f28 Update AWS C++ SDK version
This fixes some truncation warnings on Win64
2017-10-11 08:45:59 +02:00
Marko Mäkelä
2c1067166d Merge bb-10.2-ext into 10.3 2017-10-04 08:24:06 +03:00
Marko Mäkelä
61b2618d3a Merge 10.2 into bb-10.2-ext 2017-10-04 08:10:03 +03:00
Marko Mäkelä
6ca35c1428 Replace a non-ASCII character in a comment 2017-10-04 08:07:41 +03:00
Vladislav Vaintroub
4732767981 Fix Windows warnings : fix server_audit not to use my_win_open and Co
functions.

There is no reason to export IO this functionality from server, if it can
be easily implemented with CRT.

Note: for the sake of compatibility, we do not use _open() on Windows,
but open file with CreateFile, with FILE_SHARE_DELETE flag,
so it can be renamed or deleted when open. Also atomic append flag is used.
2017-10-03 19:42:16 +00:00
Alexander Barkov
8ae8cd6348 Merge remote-tracking branch 'origin/10.2' into bb-10.2-ext 2017-10-02 22:35:13 +04:00
Vladislav Vaintroub
7354dc6773 MDEV-13384 - misc Windows warnings fixed 2017-09-28 17:20:46 +00:00
Sergei Golubchik
88adfd0cea compiler warning 2017-09-23 20:21:49 +02:00
Marko Mäkelä
e3d44f5d62 Merge bb-10.2-ext into 10.3 2017-09-21 08:12:19 +03:00
Marko Mäkelä
fc3b1a7d2f Merge 10.2 into bb-10.2-ext 2017-09-20 17:47:49 +03:00
Vicențiu Ciorbaru
2d9f5f69d4 Merge branch '10.1' into 10.2 2017-09-20 10:46:09 +03:00
Alexey Botchkov
99fbf3eb59 MDEV-13137 MySQL 5.6.23 Crashes when SET GLOBAL server_audit_logging=OFF;
The MySQL 5.6 doesn't always send the MYSQL_AUDIT_GENERAL_LOG
        notification. So we have to suppress the log_current_query()
        in this case.
2017-09-19 14:01:12 +04:00
Alexey Botchkov
389f7cdf3c MDEV-13137 MySQL 5.6.23 Crashes when SET GLOBAL server_audit_logging=OFF;
The MySQL 5.6 doesn't always send the MYSQL_AUDIT_GENERAL_LOG
        notification. So we have to suppress the log_current_query()
        in this case.
2017-09-19 13:43:36 +04:00
Alexey Botchkov
a47d16907d MDEV-13137 MySQL 5.6.23 Crashes when SET GLOBAL server_audit_logging=OFF;
The MySQL 5.6 doesn't always send the MYSQL_AUDIT_GENERAL_LOG
        notification. So we have to suppress the log_current_query()
        in this case.
2017-09-19 13:08:24 +04:00
Sergei Golubchik
7e56e9ea77 MDEV-13650 Backport fix for MDEV-13060 (crash when both AWS plugin and server_audit are loaded) to 10.1
MDEV-13060 Server Audit Plugin Crashes with AWS KMS plugin

don't do auditing if thd is NULL.

Collaterals:
* copy-paste bugs server_audit.c
2017-09-18 10:40:26 +02:00
Marko Mäkelä
ae02407ce3 Merge bb-10.2-ext into 10.3 2017-09-07 12:30:56 +03:00
Marko Mäkelä
a82ed92a6a Merge 10.2 into bb-10.2-ext 2017-09-07 12:23:58 +03:00
Marko Mäkelä
70db1e3b8a Merge 10.1 into 10.2 2017-09-06 19:28:51 +03:00
Marko Mäkelä
cd694d76ce Merge 10.0 into 10.1 2017-09-06 15:32:56 +03:00
Marko Mäkelä
7f99381288 Fix compiler warnings
metadata_lock_info_duration[]: Remove the unused variable.

Add some comments /* fall through */ to silence -Wimplicit-fallthrough
2017-09-01 15:40:49 +03:00
Marko Mäkelä
4e1fa7f63d Merge bb-10.2-ext into 10.3 2017-09-01 11:33:45 +03:00
Marko Mäkelä
6749d39a95 Merge 10.2 into bb-10.2-ext 2017-09-01 08:47:55 +03:00
Peter Shchuchkin
41d89b7da1 Added HITS column to QUERY_CACHE_INFO table
Updated qc_info tests, added new test that checks HITS is incremented.
2017-08-31 13:50:25 +04:00
Marko Mäkelä
a36c369bda Merge 10.1 into 10.2
For running the Galera tests, the variable my_disable_leak_check
was set to true in order to avoid assertions due to memory leaks
at shutdown.

Some adjustments due to MDEV-13625 (merge InnoDB tests from MySQL 5.6)
were performed. The most notable behaviour changes from 10.0 and 10.1
are the following:

* innodb.innodb-table-online: adjustments for the DROP COLUMN
behaviour change (MDEV-11114, MDEV-13613)

* innodb.innodb-index-online-fk: the removal of a (1,NULL) record
from the result; originally removed in MySQL 5.7 in the
Oracle Bug #16244691 fix
377774689b

* innodb.create-index-debug: disabled due to MDEV-13680
(the MySQL Bug #77497 fix was not merged from 5.6 to 5.7.10)

* innodb.innodb-alter-autoinc: MariaDB 10.2 behaves like MySQL 5.6/5.7,
while MariaDB 10.0 and 10.1 assign different values when
auto_increment_increment or auto_increment_offset are used.
Also MySQL 5.6/5.7 exhibit different behaviour between
LGORITHM=INPLACE and ALGORITHM=COPY, so something needs to be tested
and fixed in both MariaDB 10.0 and 10.2.

* innodb.innodb-wl5980-alter: disabled because it would trigger an
InnoDB assertion failure (MDEV-13668 may need additional effort in 10.2)
2017-08-31 09:30:40 +03:00
Eugene Kosov
b231a85200 Plugins: lost terminator in versioning plugin [fixes #248] 2017-08-30 13:43:04 +03:00
Jan Lindström
01209de763 Merge remote-tracking branch 'origin/bb-10.1-jplindst' into 10.1 2017-08-29 20:30:18 +03:00
Vladislav Vaintroub
dda40b9304 AWS Key Management : Introduce "mock" variable, available in debug build.
If this variable is set, skip actual AWS calls, and fake/mock
both generation and encryption of the keys.

The advantage of having a mock mode is that more aws_key_management tests
can be enabled on buildbot.
2017-08-28 18:28:07 +00:00
Sergei Golubchik
bb8e99fdc3 Merge branch 'bb-10.2-ext' into 10.3 2017-08-26 00:34:43 +02:00
Sergei Golubchik
27412877db Merge branch '10.2' into bb-10.2-ext 2017-08-25 10:25:48 +02:00
Michael Widenius
cc77f9882d Changed KEY names to use LEX_CSTRING 2017-08-24 01:05:53 +02:00