Update libsignal-service-java

This commit is contained in:
AsamK 2023-08-09 20:47:26 +02:00
parent ca088bcc33
commit 934697af28
6 changed files with 8 additions and 9 deletions

View file

@ -2610,7 +2610,7 @@
}, },
{ {
"name":"org.whispersystems.signalservice.internal.push.SignalServiceProtos$DataMessage$StoryContext", "name":"org.whispersystems.signalservice.internal.push.SignalServiceProtos$DataMessage$StoryContext",
"fields":[{"name":"bitField0_"}, {"name":"sentTimestamp_"}] "fields":[{"name":"authorAci_"}, {"name":"bitField0_"}, {"name":"sentTimestamp_"}]
}, },
{ {
"name":"org.whispersystems.signalservice.internal.push.SignalServiceProtos$EditMessage", "name":"org.whispersystems.signalservice.internal.push.SignalServiceProtos$EditMessage",

View file

@ -29,7 +29,6 @@ import org.whispersystems.signalservice.api.push.exceptions.AlreadyVerifiedExcep
import org.whispersystems.signalservice.api.push.exceptions.AuthorizationFailedException; import org.whispersystems.signalservice.api.push.exceptions.AuthorizationFailedException;
import org.whispersystems.signalservice.api.push.exceptions.DeprecatedVersionException; import org.whispersystems.signalservice.api.push.exceptions.DeprecatedVersionException;
import org.whispersystems.signalservice.api.util.DeviceNameUtil; import org.whispersystems.signalservice.api.util.DeviceNameUtil;
import org.whispersystems.signalservice.api.util.UuidUtil;
import org.whispersystems.signalservice.internal.push.KyberPreKeyEntity; import org.whispersystems.signalservice.internal.push.KyberPreKeyEntity;
import org.whispersystems.signalservice.internal.push.OutgoingPushMessage; import org.whispersystems.signalservice.internal.push.OutgoingPushMessage;
import org.whispersystems.util.Base64UrlSafe; import org.whispersystems.util.Base64UrlSafe;
@ -103,7 +102,7 @@ public class AccountHelper {
final var whoAmI = dependencies.getAccountManager().getWhoAmI(); final var whoAmI = dependencies.getAccountManager().getWhoAmI();
final var number = whoAmI.getNumber(); final var number = whoAmI.getNumber();
final var aci = ACI.parseOrThrow(whoAmI.getAci()); final var aci = ACI.parseOrThrow(whoAmI.getAci());
final var pni = PNI.from(UuidUtil.parseOrThrow(whoAmI.getPni())); final var pni = PNI.parseUnPrefixedOrThrow(whoAmI.getPni());
if (number.equals(account.getNumber()) && aci.equals(account.getAci()) && pni.equals(account.getPni())) { if (number.equals(account.getNumber()) && aci.equals(account.getAci()) && pni.equals(account.getPni())) {
return; return;
} }

View file

@ -45,7 +45,6 @@ import org.whispersystems.signalservice.api.push.ServiceIdType;
import org.whispersystems.signalservice.api.push.SignalServiceAddress; import org.whispersystems.signalservice.api.push.SignalServiceAddress;
import org.whispersystems.signalservice.api.push.exceptions.AlreadyVerifiedException; import org.whispersystems.signalservice.api.push.exceptions.AlreadyVerifiedException;
import org.whispersystems.signalservice.api.push.exceptions.DeprecatedVersionException; import org.whispersystems.signalservice.api.push.exceptions.DeprecatedVersionException;
import org.whispersystems.signalservice.api.util.UuidUtil;
import org.whispersystems.signalservice.internal.push.VerifyAccountResponse; import org.whispersystems.signalservice.internal.push.VerifyAccountResponse;
import org.whispersystems.signalservice.internal.util.DynamicCredentialsProvider; import org.whispersystems.signalservice.internal.util.DynamicCredentialsProvider;
@ -166,7 +165,7 @@ public class RegistrationManagerImpl implements RegistrationManager {
//accountManager.setGcmId(Optional.of(GoogleCloudMessaging.getInstance(this).register(REGISTRATION_ID))); //accountManager.setGcmId(Optional.of(GoogleCloudMessaging.getInstance(this).register(REGISTRATION_ID)));
final var aci = ACI.parseOrThrow(response.getUuid()); final var aci = ACI.parseOrThrow(response.getUuid());
final var pni = PNI.from(UuidUtil.parseOrThrow(response.getPni())); final var pni = PNI.parseUnPrefixedOrThrow(response.getPni());
account.finishRegistration(aci, pni, masterKey, pin, aciPreKeys, pniPreKeys); account.finishRegistration(aci, pni, masterKey, pin, aciPreKeys, pniPreKeys);
accountFileUpdater.updateAccountIdentifiers(account.getNumber(), aci); accountFileUpdater.updateAccountIdentifiers(account.getNumber(), aci);

View file

@ -558,7 +558,7 @@ public class SignalAccount implements Closeable {
} }
if (rootNode.hasNonNull("pni")) { if (rootNode.hasNonNull("pni")) {
try { try {
pni = PNI.from(UuidUtil.parseOrThrow(rootNode.get("pni").asText())); pni = PNI.parseUnPrefixedOrThrow(rootNode.get("pni").asText());
} catch (IllegalArgumentException e) { } catch (IllegalArgumentException e) {
throw new IOException("Config file contains an invalid pni, needs to be a valid UUID", e); throw new IOException("Config file contains an invalid pni, needs to be a valid UUID", e);
} }
@ -967,7 +967,7 @@ public class SignalAccount implements Closeable {
.put("serviceEnvironment", serviceEnvironment == null ? null : serviceEnvironment.name()) .put("serviceEnvironment", serviceEnvironment == null ? null : serviceEnvironment.name())
.put("usernameIdentifier", username) .put("usernameIdentifier", username)
.put("uuid", aci == null ? null : aci.toString()) .put("uuid", aci == null ? null : aci.toString())
.put("pni", pni == null ? null : pni.getRawUuid().toString()) .put("pni", pni == null ? null : pni.toStringWithoutPrefix())
.put("sessionId", sessionId) .put("sessionId", sessionId)
.put("sessionNumber", sessionNumber) .put("sessionNumber", sessionNumber)
.put("deviceName", encryptedDeviceName) .put("deviceName", encryptedDeviceName)

View file

@ -57,6 +57,7 @@ public class AttachmentUtils {
blurHash, blurHash,
null, null,
null, null,
resumableUploadSpec); resumableUploadSpec,
false);
} }
} }

View file

@ -16,7 +16,7 @@ dependencyResolutionManagement {
library("logback", "ch.qos.logback", "logback-classic").version("1.4.8") library("logback", "ch.qos.logback", "logback-classic").version("1.4.8")
library("signalservice", "com.github.turasa", "signal-service-java").version("2.15.3_unofficial_77") library("signalservice", "com.github.turasa", "signal-service-java").version("2.15.3_unofficial_78")
library("protobuf", "com.google.protobuf", "protobuf-javalite").version("3.23.0") library("protobuf", "com.google.protobuf", "protobuf-javalite").version("3.23.0")
library("sqlite", "org.xerial", "sqlite-jdbc").version("3.42.0.0") library("sqlite", "org.xerial", "sqlite-jdbc").version("3.42.0.0")
library("hikari", "com.zaxxer", "HikariCP").version("5.0.1") library("hikari", "com.zaxxer", "HikariCP").version("5.0.1")