Giter VIP home page Giter VIP logo

treehole_shamir_client's Introduction

Treehole_shamir_client

解密用户邮箱的客户端,opentreehole密钥管理员使用。

使用步骤

必要:准备 pgp 私钥。

如果使用 gnupg 生成密钥,请从 gnupg 导出私钥文本文件,并放置到程序同一目录下。

gpg -a -o private.key --export-private-keys <your_uid>

如果使用其他工具生成密钥,请自行处理

解密 shamir 信息

# 解密全部用户信息,并且上传到后端等待解密。此命令会把处理好的全部用户信息文件存到当前目录下,文件名形如 share_data_xxx.json
shamir_client decrypt -k <your_private_key_file> -p <your_password> [-a <server_url>]

# 解密单用户的信息
shamir_client decrypt -k <your_private_key_file> -p <your_password> -u <user_id> [-a <server_url>]

# 如果有已经解密的全部用户信息文件 share_data_xxx.json,可以不用重新解密,直接上传
shamir_client decrypt [-a <server_url>] -f <share_data_xxx.json>

默认 server_url 为 https://auth.fduhole.com

生成公私钥文件

仅用于管理员生成新的密钥,与解密的密钥无关

shamir_client generate <your_name> <your_email> <your_password>

解密用户邮箱

准备 shares.json 文件,放置到程序同一目录下,格式为

[
  "123123123\n456456456",
  "345345345\n678678678"
]

执行

shamir_client email [-f <your_share_file>]

上传新管理员公钥

准备好7个分开的公钥文件

shamir_client upload <file1> <file2> <file3> <file4> <file5> <file6> <file7> [-a <server_url>]

treehole_shamir_client's People

Contributors

jingyijun avatar

Stargazers

Dest1n1 avatar Cheung Man-Yee avatar w568w avatar

Watchers

w568w avatar  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.