10000 Add test for commoncrypto default cipher · magic-coder/sqlcipher@5b639be · GitHub
[go: up one dir, main page]

Skip to content

Commit 5b639be

Browse files
Add test for commoncrypto default cipher
1 parent ee14e0f commit 5b639be

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

test/crypto.test

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,12 @@ proc if_built_with_libtomcrypt {name cmd expected} {
8282
}
8383
}
8484

85+
proc if_built_with_commoncrypto {name cmd expected} {
86+
if {[get_cipher_provider] == "commoncrypto"} {
87+
do_test $name $cmd $expected
88+
}
89+
}
90+
8591
# The database is initially empty.
8692
# set an hex key create some basic data
8793
# create table and insert operations should work
@@ -1886,4 +1892,14 @@ if_built_with_libtomcrypt verify-default-cipher {
18861892
db close
18871893
file delete -force test.db
18881894

1895+
if_built_with_commoncrypto verify-default-cipher {
1896+
sqlite_orig db test.db
1897+
execsql {
1898+
PRAGMA key='test';
1899+
PRAGMA cipher;
1900+
}
1901+
} {aes-256-cbc}
1902+
db close
1903+
file delete -force test.db
1904+
18891905
finish_test

0 commit comments

Comments
 (0)
0