]> nmode's Git Repositories - signal-cli/blob - README.md
Print quotes from messages
[signal-cli] / README.md
1 # signal-cli
2
3 signal-cli is a commandline interface for [libsignal-service-java](https://github.com/WhisperSystems/libsignal-service-java). It supports registering, verifying, sending and receiving messages.
4 To be able to link to an existing Signal-Android/signal-cli instance, signal-cli uses a [patched libsignal-service-java](https://github.com/AsamK/libsignal-service-java), because libsignal-service-java does not yet support [provisioning as a slave device](https://github.com/WhisperSystems/libsignal-service-java/pull/21).
5 For registering you need a phone number where you can receive SMS or incoming calls.
6 signal-cli is primarily intended to be used on servers to notify admins of important events. For this use-case, it has a dbus interface, that can be used to send messages from any programming language that has dbus bindings.
7
8 ## Installation
9
10 You can [build signal-cli](#building) yourself, or use the [provided binary files](https://github.com/AsamK/signal-cli/releases/latest), which should work on Linux, macOS and Windows. For Arch Linux there is also a [package in AUR](https://aur.archlinux.org/packages/signal-cli/). You need to have at least JRE 7 installed, to run signal-cli.
11
12 ### Install system-wide on Linux
13 See [latest version](https://github.com/AsamK/signal-cli/releases).
14 ```sh
15 export VERSION=<latest version, format "x.y.z">
16 wget https://github.com/AsamK/signal-cli/releases/download/v"${VERSION}"/signal-cli-"${VERSION}".tar.gz
17 sudo tar xf signal-cli-"${VERSION}".tar.gz -C /opt
18 sudo ln -sf /opt/signal-cli-"${VERSION}"/bin/signal-cli /usr/local/bin/
19 ```
20
21 ## Usage
22
23 Important: The USERNAME (your phone number) must include the country calling code, i.e. the number must start with a "+" sign. (See [Wikipedia](https://en.wikipedia.org/wiki/List_of_country_calling_codes) for a list of all country codes.
24
25 * Register a number (with SMS verification)
26
27 signal-cli -u USERNAME register
28
29 * Verify the number using the code received via SMS or voice
30
31 signal-cli -u USERNAME verify CODE
32
33 * Send a message
34
35 signal-cli -u USERNAME send -m "This is a message" RECIPIENT
36
37 * Pipe the message content from another process.
38
39 uname -a | signal-cli -u USERNAME send RECIPIENT
40
41 * Receive messages
42
43 signal-cli -u USERNAME receive
44
45 For more information read the [man page](https://github.com/AsamK/signal-cli/blob/master/man/signal-cli.1.adoc) and the [wiki](https://github.com/AsamK/signal-cli/wiki).
46
47 ## Storage
48
49 The password and cryptographic keys are created when registering and stored in the current users home directory:
50
51 $HOME/.config/signal/data/
52
53 For legacy users, the old config directory is used as a fallback:
54
55 $HOME/.config/textsecure/data/
56
57 ## Building
58
59 This project uses [Gradle](http://gradle.org) for building and maintaining
60 dependencies. If you have a recent gradle version installed, you can replace `./gradlew` with `gradle` in the following steps.
61
62 1. Checkout the source somewhere on your filesystem with
63
64 git clone https://github.com/AsamK/signal-cli.git
65
66 2. Execute Gradle:
67
68 ./gradlew build
69
70 3. Create shell wrapper in *build/install/signal-cli/bin*:
71
72 ./gradlew installDist
73
74 4. Create tar file in *build/distributions*:
75
76 ./gradlew distTar
77
78 ## Troubleshooting
79 If you use a version of the Oracle JRE and get an InvalidKeyException you need to enable unlimited strength crypto. See https://stackoverflow.com/questions/6481627/java-security-illegal-key-size-or-default-parameters for instructions.
80
81 ## License
82
83 This project uses libsignal-service-java from Open Whisper Systems:
84
85 https://github.com/WhisperSystems/libsignal-service-java
86
87 Licensed under the GPLv3: http://www.gnu.org/licenses/gpl-3.0.html