Skip to content
المشاريع

حول

A high-level Rust library to help write clients for the Signal Messenger.

أدوات التطوير

كيف تُقاس هذه الأرقام

النمو المقاس للنجوم

خلال 24 ساعة
٠
خلال 7 أيام
+١
خلال 15 يومًا
+٢
خلال شهر
جارٍ جمع السجل

تغيّر صافي النجوم خلال فترات متداخلة، وليس مجموعًا يوميًا. تبقى القياسات المفقودة فارغة. النجوم تقيس الاهتمام لا جودة البرمجيات.

README.md

الأصل

Presage

CI Build License API Docs

A Rust library that helps building clients for the Signal Messenger, using libsignal-service-rs. It is designed to provide everything you need to get started.

Features:

  • Local storage with sqlx and sqlite (see #287) with optional encryption with sqlcipher (fixed in #335)
  • Registration
    • SMS
    • Voice call
  • Link as secondary device from Android / iOS app (like Signal Desktop)
  • Contacts and groups (synchronized from the storage service) and profiles
  • Settings and blocked contacts (synchronized from the storage service)
  • Messages (incoming and outgoing), with edits, deletes and receipts
  • Fetch, decrypt and store attachments
  • Stickers
  • Stories

Instructions

Add the following to your Cargo.toml:

[dependencies]
presage = { git = "https://github.com/whisperfish/presage" }
presage-store-sqlite = { git = "https://github.com/whisperfish/presage" }

and look at the generated Rust documentation of the Manager struct to get started.

Enable CDSI (Contact Discovery)

The secure contact discovery (from phone numbers) feature depends on libsignal-net which chose to depend on boringSSL. Unfortunately, we rely on sqlcipher which is only compatible with OpenSSL > 3.x (their APIs are incompatible, but share names).

To use cdsi you can use our fork of libsqlite3-sys with a custom encryption provider written in Rust, like so in your Cargo.toml:

presage = { git = "https://github.com/whisperfish/presage" }
presage-sqlite = { git = "https://github.com/whisperfish/presage", default-features = false, features = ["cdsi"] }

[patch.crates-io]
libsqlite3-sys = { version = "0.36.0", git = "https://github.com/whisperfish/rusqlite", rev = '2a42b3354c9194700d08aa070f70a131a470e7dc' }

Demo CLI

Included in this repository is a nearly fully functional CLI that can serve as an example to build your client (you can also use it to query your presage database):

# print help section
cargo run -- --help

# link as secondary device, a PNG with a QR code to scan should open
cargo run -- link-device --device-name presage

# start receiving messages
cargo run -- receive

استكشف مشاريع مشابهة ومرتبطة

جارٍ التحميل…