GithubHelp home page GithubHelp logo

libomemo's Introduction

libomemo 0.7.1

Implements OMEMO (XEP-0384) in C.

Input and output are XML strings, so it does not force you to use a certain XML lib. While the actual protocol functions do not depend on any kind of storage, it comes with a basic implementation in SQLite.

It deals with devicelists and bundles as well as encrypting the payload, but does not handle the double ratchet sessions for encrypting the key to the payload. However, you can use my axc lib for that and easily combine it with this one (or write all the libsignal client code yourself if that is better suited to your needs).

Dependencies

  • Mini-XML (libmxml-dev)
  • gcrypt (libgcrypt20-dev)
  • glib (libglib2.0-dev)
  • SQLite (libsqlite3-dev)

Optional:

  • For testing: cmocka (make test)
  • For the coverage report: gcovr (make coverage)

I recommend to simply link it statically - the standard target is a is a static lib (containing PIC) which uses the compatible namespace (i.e. not the one in the XEP).

Usage

Basically, there are three data types: messages, devicelists, and bundles. You can import received the received XML data to work with it, or create them empty. When done with them, they can be exported back to XML for displaying or sending.

The test cases should demonstrate the general usage.

If a different namespace than the one specified in the XEP is to be used, you can use specify it at compile time. See the makefile for an example.

libomemo's People

Contributors

aluaces avatar fortysixandtwo avatar gkdr avatar hasufell avatar msantos avatar neustradamus avatar rmader avatar shtrom avatar

Stargazers

 avatar  avatar

Watchers

 avatar

Forkers

sahwar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.