Update SQLCipher to 4.13.0

This commit is contained in:
Greyson Parrelli
2026-03-09 10:27:51 -04:00
committed by jeffrey-signal
parent 94e28eddd0
commit bdc90f3c02
6 changed files with 96 additions and 8 deletions

View File

@@ -0,0 +1,30 @@
/*
* Copyright 2026 Signal Messenger, LLC
* SPDX-License-Identifier: AGPL-3.0-only
*/
package org.thoughtcrime.securesms.util
import net.zetetic.database.LogTarget
import net.zetetic.database.Logger
import org.signal.core.util.logging.Log
object SqlCipherLogTarget : LogTarget {
override fun isLoggable(tag: String?, priority: Int): Boolean {
// Logger.DEBUG logs are extremely verbose, and include things like status updates on cursors being filled
return priority >= Logger.INFO
}
override fun log(priority: Int, tag: String?, message: String?, throwable: Throwable?) {
val tag = tag ?: "SqlCipher"
when (priority) {
Logger.VERBOSE -> Log.v(tag, message, throwable)
Logger.DEBUG -> Log.d(tag, message, throwable)
Logger.INFO -> Log.i(tag, message, throwable)
Logger.WARN -> Log.w(tag, message, throwable)
Logger.ERROR -> Log.e(tag, message, throwable)
Logger.ASSERT -> Log.e(tag, message, throwable)
else -> Log.d(tag, message, throwable)
}
}
}