Giter Site home page Giter Site logo

rpgp's Introduction

rPGP


OpenPGP implemented in pure Rust, permissively licensed

rPGP is the only pure Rust implementation of OpenPGP, following the main RFCs

See IMPL_STATUS.md for more details on the implemented PGP features.

It offers a flexible low-level API and gives users the ability to build higher level PGP tooling in the most compatible way possible. Additionally it fully supports all functionality required by the Autocrypt 1.1 e-mail encryption specification.

Usage

> cargo add pgp

Load a key and verify a message

use std::fs;
use pgp::{SignedSecretKey, Message, Deserializable};

let key_file = "key.sec.asc";
let msg_file = "msg.asc";

let key_string = fs::read_to_string("key.sec.asc").unwrap(),
let (secret_key, _headers) = SignedSecretKey::from_string(&key_string).unwrap();
let public_key = skey.public_key();

let msg_string = fs::read_to_string("msg.asc").unwrap();
let (msg, _headres) = Message::from_string(msg_string).unwrap();

// Verify this message
msg.verify(&pkey).unwrap();

let msg_content = msg.get_content().unwrap(); // actual message content

Current Status

Last updated April 2024

Users & Libraries built using rPGP

  • Delta Chat: Cross-platform messaging app that works over e-mail
  • rpm: A pure rust library for parsing and creating RPM files
  • rpgpie: An experimental high level OpenPGP API
  • rsop: A SOP CLI tool based on rPGP and rpgpie
  • debian-packaging: a library crate for dealing with Debian packages

Don't see your project here? Please send a PR :)

FAQs

Checkout FAQ.md.

Minimum Supported Rust Version (MSRV)

All crates in this repository support Rust 1.74 or higher. In future minimally supported version of Rust can be changed, but it will be done with a minor version bump.

License

This project is licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in this project by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

rpgp's People

Contributors

dignifiedquire avatar hko-s avatar link2xt avatar fmckeogh avatar wiktor-k avatar hpk42 avatar sebastinas avatar rvolgers avatar lumag avatar drahnr avatar reyk avatar r10s avatar flub avatar dadleyy avatar bcmyers avatar skgland avatar jeamland avatar cjrh avatar echedellelr avatar indygreg avatar haraldh avatar jeffreybolle avatar jikstra avatar rudxain avatar roblabla avatar sergey-kitov avatar sorairolake avatar vincentwo avatar xynnn007 avatar

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.