All Projects → opencap → protocol

opencap / protocol

Licence: other
OpenCAP: Making Crypto Convenient

Projects that are alternatives of or similar to protocol

Magento 2 Smtp
Magento 2 SMTP Extension helps the owner of store simply install SMTP (Simple Mail Transfer Protocol) server which transmits the messages into codes or numbers.
Stars: ✭ 228 (+612.5%)
Mutual labels:  email
Enmime
MIME mail encoding and decoding package for Go
Stars: ✭ 246 (+668.75%)
Mutual labels:  email
email
Aplus Framework Email Library
Stars: ✭ 127 (+296.88%)
Mutual labels:  email
Oblivion
Data leak checker & OSINT Tool
Stars: ✭ 237 (+640.63%)
Mutual labels:  email
Mailyak
An elegant MIME/SMTP email library with support for attachments
Stars: ✭ 244 (+662.5%)
Mutual labels:  email
Githubmonitor
根据关键字与 hosts 生成的关键词,利用 github 提供的 api,监控 git 泄漏。
Stars: ✭ 248 (+675%)
Mutual labels:  email
Wagonwheel
Offer an online version of your Laravel emails to users.
Stars: ✭ 224 (+600%)
Mutual labels:  email
terraform-aws-ses-dashboard
This module will create a Deliverability Dashboard that shows information about SES Email bounces and complaints.
Stars: ✭ 20 (-37.5%)
Mutual labels:  email
React Email Editor
Drag-n-Drop Email Editor Component for React.js
Stars: ✭ 3,131 (+9684.38%)
Mutual labels:  email
flutter mailer
A wrapper on top of MFMailComposeViewController from iOS and Mail Intent on android
Stars: ✭ 43 (+34.38%)
Mutual labels:  email
Mailu
Insular email distribution - mail server as Docker images
Stars: ✭ 3,151 (+9746.88%)
Mutual labels:  email
Email my pc
远程监控电脑,也许一切只需要一封邮件。
Stars: ✭ 240 (+650%)
Mutual labels:  email
Email Validation Tool
An easy to use, accurate-ish & extensible email validation library for PHP 7+ 📧
Stars: ✭ 250 (+681.25%)
Mutual labels:  email
Qtgate Desktop Client
A revolutionary internet infrastructure enabling a truly free Network, that offers Stability, Trust, Privacy, and Security
Stars: ✭ 232 (+625%)
Mutual labels:  email
nest-sendgrid
No description or website provided.
Stars: ✭ 24 (-25%)
Mutual labels:  email
Juice
Juice inlines CSS stylesheets into your HTML source.
Stars: ✭ 2,683 (+8284.38%)
Mutual labels:  email
Meli
🐝 experimental terminal mail client, mirror of https://git.meli.delivery/meli/meli.git https://crates.io/crates/meli
Stars: ✭ 242 (+656.25%)
Mutual labels:  email
emailpyspam
A python 3+ program to spam emails to a list of users repetitively
Stars: ✭ 63 (+96.88%)
Mutual labels:  email
laravel-postal
This library integrates Postal with the standard Laravel mail framework.
Stars: ✭ 20 (-37.5%)
Mutual labels:  email
mailbag
A tool for creating and managing Mailbags, a package for preserving email using multiple preservation formats
Stars: ✭ 29 (-9.37%)
Mutual labels:  email

OpenCAP

Inception: July 2018

Discord: https://discord.gg/FTMCBE8


Contents

Problem

Solution

Anatomy of an Alias

API

Text Standard

Attack Vectors

Justifications

Contribute

OpenCAP Compliant Applications

OpenCAP Development Tools


Problem

Sending cryptocurrency is not as easy as sending fiat currently. Centralized apps like Venmo, Swish, or Square Cash are more convenient and have less room for error in that they allow users to send money via usernames, emails, or phone numbers which are easy to remember and verify. Cryptocurrency addresses by nature are hard to remember, and when typed manually can easily contain errors.

Cryptocurrency addresses also change over time for a given user in some currencies (wallets use new addresses for each transaction, or users create new wallets). When posting addresses online, future payments will use the same address which defeats the purpose of the non-reuse feature. An alias relates to an address that can be updated, which solves this problem.


Solution

OpenCAP is a protocol that defines the standard by which cryptocurrency wallets can communicate with servers to relate aliases to cryptocurrency addresses. The protocol allows for the decentralization of the alias --> address relationship. Anyone can use the protocol to build/host their own server on their own domain. Servers can be majorly centralized, or individuals can run their own servers, much like SMTP (email).

OpenCAP is adhered to by both client (wallet) software and server (address storage) sofware. Wallets must know how to properly parse an alias and perform the proper API calls. Servers must know how to handle those requests in the proper manner and send back valid data. Any given wallet and server that adhere to the OpenCAP protocol will be able to communicate cryptocurrency address information seamlessly.

OpenCAP is a simple protocol that does one thing: relate aliases to addresses. Servers can of course add more features to their servers (profile pictures, address re-use and validation, etc.) but these features are not a part of the base protocol.


Anatomy of an Alias

{username}${domain name}

example: donate$ogdolo.com

The anatomy of an OpenCAP alias may remind you of an email address. The only difference being the seperator between username and domain. However it is very important to note that email addresses have nothing to do with OpenCAP aliases other than that they share a similar format.

The {username} section of the alias is only allowed to use:

  1. Lower-case letters
  2. Numbers
  3. The following punctuation:
    • "."
    • "-"
    • "_"
  4. And must be between 1 and 25 characters in length, inclusive

The {domain name} section of an alias may only use valid ASCII characters, which eliminates the use of some international domain names. This is intended to protect against an IDN Homograph Attack


API

The OpenCAP protocol at the end of the day is just a REST API specification. There are two tiers to the API, "Address Query" and "Alias Management". An OpenCAP server MUST support the "Address Query" endpoints and protocol, while the Alias Management endpoints are optional.

API Specification Server Wallet
Address Query Return addresses given an alias Support payments to aliases
Alias Management Allow RESTful updates to addresses and users Support RESTful API calls to update addresses and users

Domain Proxy

The main reason OpenCAP uses an SRV record to find the location of the host server (see Address Query) is because OpenCAP can support proxied domains. For more information on this see here.


Text Standard

All the text data transfer in the protocol can be assumed to be valid UTF-8 encoded.


Attack Vectors

Address Swaps

The most obvious way for a malicious party to use the alias system to steal funds would be to hack a OpenCAP server and secretly change out addresses so that their address is associated with someone else's alias.

Possible remedies:

  • Only allow address updates from verified IP addresses
  • Run a OpenCAP server yourself instead of using a third party (Using a third party isn't inherently insecure, and in the case of a non-programmer it is probably more secure)
  • Only allow address updates manually through a browser and 2FA/captcha. Some currencies may not update addresses often, if ever. (Nano for example)
  • Use 2 way encryption like AES-256 to cipher address and user data before storing it in a database so it can't easily be swapped out

Payment Tracking

It is fairly simple for a third party to constantly poll a given alias's endpoint and record all that alias's addresses over time. While the alias protocol isn't necessarily meant to have stringent privacy measures (the whole point of an alias is to relate a public account to an address) there are a couple things that can be done to increase privacy:

  • Coins that are able to implement features similar to BIP 47 should do so and use payment codes instead of regular addresses.
  • Servers can have sign-ups that don't require any personal information, so users can use an anonymous alias.

Cross-Site Scripting XSS

Like any javascript client, wallets and other client-side OpenCAP software can be vulnerable to XSS attacks. All OpenCAP software must take precautions to not allow any data returned by a potentially untrustworthy server to be injected in a script and ran.

Reference:

Wikipedia Cross-Site Scripting

DNS Poisoning and MITM attacks

Because we are using the DNS system for SRV record lookups and to make API calls, there is potential for some form of DNS attack. If not handled properly this kind of attack could result in stolen funds because a malicious user could redirect API calls to their own server with their own addresses. None of the following solutions are required by OpenCAP but are suggestions that individual software implementations can use to help mitigate attacks.

Servers

  • DNSSEC: Servers (both the actual host and the domain record host) can use DNSSEC to protect themselves

Wikipedia DNSSEC

Wallets (clients)

  • DNSSEC: verify that DNS responses use DNSSEC, and issue a warning to the user if they don't

  • DNS over HTTPS can be used to bypass local issues

  • Hostname caching. For instance, whenever a wallet makes a SRV lookup to "example.tld" it should receive the same domain name, let's say "opencap.example.tld". The wallet can cache this domain name and if it ever receives a new name, it can alert the sender and warn them that something may be wrong.

Individuals


Justifications

  • Squatting: OpenCAP is a REST protocol built on top of DNS to stop "squatters". Squatting is when users that are the first-adopters of the protocol come in and lock-down all the "valuable" aliases ("nike", "coke", "trump", "btc", etc). By requiring that the a domain name is part of an alias, users have to first own the domain, or have permission to use it from the owner. Because domain names are already fairly distributed this is a good compromise.

  • TXT Records: There is another protocol, OpenAlias, that proposes the usage of domain TXT Records for transmitting and storing alias/address combinations. We didn't go this route for several reasons:

  1. OpenCAP is a communication protocol only. Using TXT records couples the communication layer to the data store. We want developers to have the freedom to use whatever data store they choose.

  2. Certain features aren't possible using DNS lookups. One example is that an OpenCAP server has the potential to serve a new address for each incoming GET request, preserving privacy. There is no way to guarantee this using DNS records.

  3. For most web developers (especially newer web developers) it is simpler to work with a REST API than to create, update, delete, and query DNS records. This simplicity should help with adoption.

  • Why no blockchain?
  1. We didn't want to bloat an existing blockchain with superflous data that isn't directly related to transactions and balances.

  2. OpenCAP leaves the level of centralization up to the users. Some will use third-party OpenCAP providers. Others will run their own OpenCAP servers for complete control.

  3. In many cases it isn't desirable for an alias system to be immutable. OpenCAP leaves this up to the implementation.

  4. OpenCAP can achieve much faster create/update/delete operations than data stored on a blockchain, which means an alias can be changed quickly over time if desired.


Contribute

OpenCAP is an open-source protocol please feel free to submit change proposals via the "issues" tab on github, or by submitting a pull request.

Build software that supports the protocol! The more wallets and servers using OpenCAP, the more useful it will be. If you aren't a developer, reach out to your favorite project teams and let them know about aliases.


OpenCAP Compliant Applications

Link Type
Vola Nano wallet, Alias provider (Address Query)
Nanollet Nano wallet (Address Query)
Mynano.ninja Alias provider (Address Query)
OpenCAP Server (implemented in go) Self hostable open source server
OpenCAP Server (implemented in js) Self hostable open source server

OpenCAP Development Tools

Link Type
go-opencap Useful helper functions for Go developers
opencap-js Library for JS developers.
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].