summaryrefslogtreecommitdiffstats
path: root/mysql-test/suite/encryption/r/encrypt_and_grep.result
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-04 18:00:34 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-04 18:00:34 +0000
commit3f619478f796eddbba6e39502fe941b285dd97b1 (patch)
treee2c7b5777f728320e5b5542b6213fd3591ba51e2 /mysql-test/suite/encryption/r/encrypt_and_grep.result
parentInitial commit. (diff)
downloadmariadb-upstream.tar.xz
mariadb-upstream.zip
Adding upstream version 1:10.11.6.upstream/1%10.11.6upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'mysql-test/suite/encryption/r/encrypt_and_grep.result')
-rw-r--r--mysql-test/suite/encryption/r/encrypt_and_grep.result80
1 files changed, 80 insertions, 0 deletions
diff --git a/mysql-test/suite/encryption/r/encrypt_and_grep.result b/mysql-test/suite/encryption/r/encrypt_and_grep.result
new file mode 100644
index 00000000..72d612ee
--- /dev/null
+++ b/mysql-test/suite/encryption/r/encrypt_and_grep.result
@@ -0,0 +1,80 @@
+SET GLOBAL innodb_file_per_table = ON;
+create table t1 (a varchar(255)) engine=innodb encrypted=yes;
+create table t2 (a varchar(255)) engine=innodb;
+show warnings;
+Level Code Message
+create table t3 (a varchar(255)) engine=innodb encrypted=no;
+insert t1 values (repeat('foobarsecret', 12));
+insert t2 values (repeat('tempsecret', 12));
+insert t3 values (repeat('dummysecret', 12));
+# Wait max 10 min for key encryption threads to encrypt all spaces
+SELECT NAME FROM INFORMATION_SCHEMA.INNODB_TABLESPACES_ENCRYPTION WHERE MIN_KEY_VERSION = 0;
+NAME
+test/t3
+SELECT NAME FROM INFORMATION_SCHEMA.INNODB_TABLESPACES_ENCRYPTION WHERE MIN_KEY_VERSION <> 0;
+NAME
+innodb_system
+mysql/innodb_index_stats
+mysql/innodb_table_stats
+mysql/transaction_registry
+test/t1
+test/t2
+FLUSH TABLES t1,t2,t3 FOR EXPORT;
+# t1 yes on expecting NOT FOUND
+NOT FOUND /foobarsecret/ in t1.ibd
+# t2 ... on expecting NOT FOUND
+NOT FOUND /tempsecret/ in t2.ibd
+# t3 no on expecting FOUND
+FOUND 12 /dummysecret/ in t3.ibd
+# ibdata1 expecting NOT FOUND
+NOT FOUND /foobarsecret/ in ibdata1
+UNLOCK TABLES;
+# Now turn off encryption and wait for threads to decrypt everything
+SET GLOBAL innodb_encrypt_tables = off;
+# Wait max 10 min for key encryption threads to decrypt all spaces
+SELECT NAME FROM INFORMATION_SCHEMA.INNODB_TABLESPACES_ENCRYPTION WHERE MIN_KEY_VERSION = 0;
+NAME
+innodb_system
+mysql/innodb_index_stats
+mysql/innodb_table_stats
+mysql/transaction_registry
+test/t2
+test/t3
+SELECT NAME FROM INFORMATION_SCHEMA.INNODB_TABLESPACES_ENCRYPTION WHERE MIN_KEY_VERSION <> 0;
+NAME
+test/t1
+FLUSH TABLES t1,t2,t3 FOR EXPORT;
+# t1 yes on expecting NOT FOUND
+NOT FOUND /foobarsecret/ in t1.ibd
+# t2 ... default expecting FOUND
+FOUND 12 /tempsecret/ in t2.ibd
+# t3 no on expecting FOUND
+FOUND 12 /dummysecret/ in t3.ibd
+# ibdata1 expecting NOT FOUND
+NOT FOUND /foobarsecret/ in ibdata1
+UNLOCK TABLES;
+# Now turn on encryption and wait for threads to encrypt all spaces
+SET GLOBAL innodb_encrypt_tables = on;
+# Wait max 10 min for key encryption threads to encrypt all spaces
+SELECT NAME FROM INFORMATION_SCHEMA.INNODB_TABLESPACES_ENCRYPTION WHERE MIN_KEY_VERSION = 0;
+NAME
+test/t3
+SELECT NAME FROM INFORMATION_SCHEMA.INNODB_TABLESPACES_ENCRYPTION WHERE MIN_KEY_VERSION <> 0;
+NAME
+innodb_system
+mysql/innodb_index_stats
+mysql/innodb_table_stats
+mysql/transaction_registry
+test/t1
+test/t2
+FLUSH TABLES t1,t2,t3 FOR EXPORT;
+# t1 yes on expecting NOT FOUND
+NOT FOUND /foobarsecret/ in t1.ibd
+# t2 ... on expecting NOT FOUND
+NOT FOUND /tempsecret/ in t2.ibd
+# t3 no on expecting FOUND
+FOUND 12 /dummysecret/ in t3.ibd
+# ibdata1 expecting NOT FOUND
+NOT FOUND /foobarsecret/ in ibdata1
+UNLOCK TABLES;
+drop table t1, t2, t3;