diff --git a/DBus-service.md b/DBus-service.md index bcfe3b9..527e7c8 100644 --- a/DBus-service.md +++ b/DBus-service.md @@ -131,14 +131,14 @@ Keep in mind that if you use DBus as a system service and want to send a message The groupId is handled as an array of bytes rather than a Base64 string. (See [#272](https://github.com/AsamK/signal-cli/issues/272).) -The byte array can be obtained from a base64-encoded string (which looks like ixZI93QgqmjNpM8V+E25== and can be found in signal-cli's config file, by default in ~/.local/share/signal-cli/data/). To decode it to byte array, you can use python: +The byte array can be obtained from a base64-encoded string (which looks like ixZI93QgqmjNpM8V+E0= and can be found in signal-cli's config file, by default in ~/.local/share/signal-cli/data/.d/group-cache/). Note that any underscore must be converted into a slash (/) character to provide a valid base64-encoded string. To decode it to byte array, you can use python: ``` -python3 -c 'import base64; print(",".join(str(i) for i in base64.b64decode(b"ixZI93QgqmjNpM8V+E25==")))' +python3 -c 'import base64; print(",".join(str(i) for i in base64.b64decode(b"ixZI93QgqmjNpM8V+E0=")))' ``` or, using Bash shell syntax: ``` -echo "ixZI93QgqmjNpM8V+E25==" | base64 -d |xxd -p -c1|while read i; do printf "%d " $((16#${i})); done|sed 's/ /,/g'|sed 's/,$/\n/g' +echo "ixZI93QgqmjNpM8V+E0="|sed 's/_/\//g' | base64 -d |xxd -p -c1|while read i; do printf "%d " $((16#${i})); done|sed 's/ /,/g'|sed 's/,$/\n/g' ``` In the examples above, attachments are identified by the first `array:string:` argument (`dbus-send` arguments must be in the correct order). The last argument can either be a single `string:RECIPIENT` (as in the examples above) or an `array:string:RECIPIENT1,RECIPIENT2,...` (for `dbus-send`, an array argument consists of a comma-separated list).