Update dependencies

This commit is contained in:
AsamK 2022-10-02 17:24:20 +02:00
parent 6feff1e42b
commit de8ddb2a2b
4 changed files with 18 additions and 11 deletions

View file

@ -3,7 +3,7 @@ plugins {
application application
eclipse eclipse
`check-lib-versions` `check-lib-versions`
id("org.graalvm.buildtools.native") version "0.9.13" id("org.graalvm.buildtools.native") version "0.9.14"
} }
version = "0.10.11" version = "0.10.11"
@ -35,10 +35,10 @@ dependencies {
implementation("org.bouncycastle", "bcprov-jdk15on", "1.70") implementation("org.bouncycastle", "bcprov-jdk15on", "1.70")
implementation("com.fasterxml.jackson.core", "jackson-databind", "2.13.3") implementation("com.fasterxml.jackson.core", "jackson-databind", "2.13.3")
implementation("net.sourceforge.argparse4j", "argparse4j", "0.9.0") implementation("net.sourceforge.argparse4j", "argparse4j", "0.9.0")
implementation("com.github.hypfvieh", "dbus-java-transport-native-unixsocket", "4.1.0") implementation("com.github.hypfvieh", "dbus-java-transport-native-unixsocket", "4.2.1")
implementation("org.slf4j", "slf4j-api", "2.0.0") implementation("org.slf4j", "slf4j-api", "2.0.3")
implementation("ch.qos.logback", "logback-classic", "1.4.0") implementation("ch.qos.logback", "logback-classic", "1.4.1")
implementation("org.slf4j", "jul-to-slf4j", "2.0.0") implementation("org.slf4j", "jul-to-slf4j", "2.0.3")
implementation(project(":lib")) implementation(project(":lib"))
} }

View file

@ -2904,6 +2904,7 @@
{"name":"serverTimestamp_"}, {"name":"serverTimestamp_"},
{"name":"sourceDevice_"}, {"name":"sourceDevice_"},
{"name":"sourceUuid_"}, {"name":"sourceUuid_"},
{"name":"story_"},
{"name":"timestamp_"}, {"name":"timestamp_"},
{"name":"type_"}, {"name":"type_"},
{"name":"urgent_"} {"name":"urgent_"}

View file

@ -14,12 +14,12 @@ repositories {
} }
dependencies { dependencies {
implementation("com.github.turasa", "signal-service-java", "2.15.3_unofficial_57") implementation("com.github.turasa", "signal-service-java", "2.15.3_unofficial_58")
implementation("com.fasterxml.jackson.core", "jackson-databind", "2.13.3") implementation("com.fasterxml.jackson.core", "jackson-databind", "2.13.3")
implementation("com.google.protobuf", "protobuf-javalite", "3.11.4") implementation("com.google.protobuf", "protobuf-javalite", "3.11.4")
implementation("org.bouncycastle", "bcprov-jdk15on", "1.70") implementation("org.bouncycastle", "bcprov-jdk15on", "1.70")
implementation("org.slf4j", "slf4j-api", "2.0.0") implementation("org.slf4j", "slf4j-api", "2.0.3")
implementation("org.xerial", "sqlite-jdbc", "3.39.2.1") implementation("org.xerial", "sqlite-jdbc", "3.39.3.0")
implementation("com.zaxxer", "HikariCP", "5.0.1") implementation("com.zaxxer", "HikariCP", "5.0.1")
} }

View file

@ -19,7 +19,7 @@ public class MessageCacheUtils {
try (var f = new FileInputStream(file)) { try (var f = new FileInputStream(file)) {
var in = new DataInputStream(f); var in = new DataInputStream(f);
var version = in.readInt(); var version = in.readInt();
if (version > 6) { if (version > 7) {
// Unsupported envelope version // Unsupported envelope version
return null; return null;
} }
@ -67,6 +67,10 @@ public class MessageCacheUtils {
if (version >= 6) { if (version >= 6) {
isUrgent = in.readBoolean(); isUrgent = in.readBoolean();
} }
boolean isStory = true;
if (version >= 7) {
isStory = in.readBoolean();
}
Optional<SignalServiceAddress> addressOptional = sourceServiceId == null Optional<SignalServiceAddress> addressOptional = sourceServiceId == null
? Optional.empty() ? Optional.empty()
: Optional.of(new SignalServiceAddress(sourceServiceId, source)); : Optional.of(new SignalServiceAddress(sourceServiceId, source));
@ -79,14 +83,15 @@ public class MessageCacheUtils {
serverDeliveredTimestamp, serverDeliveredTimestamp,
uuid, uuid,
destinationUuid == null ? UuidUtil.UNKNOWN_UUID.toString() : destinationUuid, destinationUuid == null ? UuidUtil.UNKNOWN_UUID.toString() : destinationUuid,
isUrgent); isUrgent,
isStory);
} }
} }
public static void storeEnvelope(SignalServiceEnvelope envelope, File file) throws IOException { public static void storeEnvelope(SignalServiceEnvelope envelope, File file) throws IOException {
try (var f = new FileOutputStream(file)) { try (var f = new FileOutputStream(file)) {
try (var out = new DataOutputStream(f)) { try (var out = new DataOutputStream(f)) {
out.writeInt(6); // version out.writeInt(7); // version
out.writeInt(envelope.getType()); out.writeInt(envelope.getType());
out.writeUTF(""); // legacy number out.writeUTF(""); // legacy number
out.writeUTF(envelope.getSourceUuid().isPresent() ? envelope.getSourceUuid().get() : ""); out.writeUTF(envelope.getSourceUuid().isPresent() ? envelope.getSourceUuid().get() : "");
@ -105,6 +110,7 @@ public class MessageCacheUtils {
out.writeUTF(uuid == null ? "" : uuid); out.writeUTF(uuid == null ? "" : uuid);
out.writeLong(envelope.getServerDeliveredTimestamp()); out.writeLong(envelope.getServerDeliveredTimestamp());
out.writeBoolean(envelope.isUrgent()); out.writeBoolean(envelope.isUrgent());
out.writeBoolean(envelope.isStory());
} }
} }
} }