-
-
Notifications
You must be signed in to change notification settings - Fork 309
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
adding signal-android devices #20
Comments
It's possible, if you implement it yourself. You need to build Signal-Android with a libsignal-service-java version, that contains the following PR: signalapp/libsignal-service-java#21 . So I guess it's a lot of work and I'm not sure if it's going to be merged upstream. |
Would you be willing to help, though? I have managed to make Signal-Android produce tsdevice links, finish the device link, and append its received deviceid to all requests so far. sending and receiving personal and group messages is working fine, but the initial group and contact synchronization is troubling me. When i send a sync-request like you did here, the api throws a MismatchedDevicesException:
could you give me a hint what a MismatchedDevicesException is supposed to indicate? I cannot catch it, since jobs run in different threads, i suppose. |
Nice work! |
I cleaned up the source code as much as i could, here is the commit: Trolldemorted/Signal-Android@8ac7f52 Don't forget to build against signalapp/libsignal-service-java#21 - i did not want to waste time on figuring how gradle/maven work, so i dropped my compiled jars manually into my gradle cache. If you know an easy and better solution, please elaborate :) |
The exception is raised because Signal-Android creates a session for its own deviceId, and the server doesn't like that. You can use |
Thanks a lot for your quick help! Since i use your libsignal-service no more MismatchedDevicesExceptions are popping up - you might want to overload setAccountAttributes and verifyAccountWithCode though, since the RegistrationService, RegistrationProgressActivity and RefreshAttributesJob classes won't compile due to calls with missing parameters. Do you think you will manage to convice OWS to merge your fixes into their master branch? As for signal-cli:
Naturally it would be great if it would respond to it (either automatically or by explicit command - i guess calling pushContacts after loading the config still works, so at least i got a workaround for now). when receiving a group sync request, signal-cli prints a NullPointerException:
but i cannot yet tell whether my request is malformed or signal-cli is crashing on a correct request. |
Probably not, so far none of my libsignal-service-java PRs have been merged or even been comment on. signal-cli should already send the sync contacts after receiving a contact sync request. |
[here was nuisance] Unfortunately signal-cli deleted my contactstore and some point (don't know when and which version, just noticed the fact). After linking a new Signal-Desktop device, responding to the sync requests with an empty contactstore, adding myself and one other old contact to the contact list, and performing a manually sync, signal-cli crashed while decrypting the sync requests:
Now i reinstalled S-D again, and noticed that if the contactstore is not empty when syncing while linking, the next manually requested sync works. Groups are still not synchronized though, neither while linking, nor by a manually requested sync. Edit: looks like i have to correct myself: S-D apparently DID receive and parse the group, but did just not display them until the next received group message. Sorry for bothering you, i assumed S-D's import works flawlessly -.- The InvalidMessageException issues and the disappearing contactstore problem is still valid though. |
is it possible to add signal for android as a non-master device?
i know that the android devices cannot display a tsdevice link, but since it is nothing but an encoded public key (?) i guess i can construct it manually with a self-compiled signal android.
did you try it yet and do you know any imminent problems?
The text was updated successfully, but these errors were encountered: