Skip to content

Commit a7593ff

Browse files
committed
fix: sqlite mysql auth patch
1 parent 7b908bb commit a7593ff

File tree

2 files changed

+6
-7
lines changed

2 files changed

+6
-7
lines changed

Diff for: deps/Makefile

+4-5
Original file line numberDiff line numberDiff line change
@@ -239,17 +239,16 @@ endif
239239
mariadb_client: mariadb-client-library/mariadb_client/libmariadb/libmariadbclient.a
240240

241241

242-
sqlite3/sqlite3/sqlite3.o:
242+
sqlite3/sqlite3/libsqlite3.so:
243243
cd sqlite3 && rm -rf sqlite-amalgamation-*/ || true
244244
cd sqlite3 && tar -zxf sqlite-amalgamation-*.tar.gz
245245
cd sqlite3/sqlite3 && patch -p1 < ../from_unixtime.patch
246246
cd sqlite3/sqlite3 && patch sqlite3.c < ../sqlite3.c-multiplication-overflow.patch
247-
# FIX ME
248-
# cd sqlite3/sqlite3 && patch -p0 < ../sqlite3_pass_exts.patch
247+
cd sqlite3/sqlite3 && patch -p0 < ../sqlite3_pass_exts.patch
249248
cd sqlite3/sqlite3 && ${CC} ${MYCFLAGS} -fPIC -c -o sqlite3.o sqlite3.c -DSQLITE_ENABLE_MEMORY_MANAGEMENT -DSQLITE_ENABLE_JSON1 -DSQLITE_DLL=1
250-
cd sqlite3/sqlite3 && ${CC} -shared -o libsqlite3.so sqlite3.o
249+
cd sqlite3/sqlite3 && ${CC} -shared -Wl,-U,_ERR_error_string -Wl,-U,_RAND_bytes -Wl,-U,_SHA1 -Wl,-U,_sha256_crypt_r -Wl,-U,_ERR_get_error -o libsqlite3.so sqlite3.o
251250

252-
sqlite3: sqlite3/sqlite3/sqlite3.o
251+
sqlite3: sqlite3/sqlite3/libsqlite3.so
253252

254253

255254
libconfig/libconfig/lib/.libs/libconfig++.a:

Diff for: deps/sqlite3/sqlite3_pass_exts.patch

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,15 @@
33
@@ -25168,6 +25168,183 @@
44
sqlite3ResultStrAccum(context, &sRes);
55
}
6-
6+
77
+#define DEF_SALT_SIZE 20
88
+#define SHA_DIGEST_LENGTH 20
99
+
1010
+/// Forward declarations
1111
+////////////////////////////////////////////////////////////////////////////////
1212
+
1313
+// ctype.h
14-
+extern int toupper (int __c) __THROW;
14+
+extern int toupper (int __c);
1515
+
1616
+// SHA256_crypt
1717
+char * sha256_crypt_r (const char *key, const char *salt, char *buffer, int buflen);

0 commit comments

Comments
 (0)