You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+60-44Lines changed: 60 additions & 44 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -3,36 +3,51 @@
3
3
4
4
## About
5
5
6
-
WebCrypt is a serverless Web App that integrates with [OnlyKey](https://onlykey.io) to provide PGP encryption everywhere on-the-go. With OnlyKey and Keybase together you have offline cold storage of your OpenPGP keys and can still easily encrypt messages and files.
6
+
OnlyKey WebCrypt provides a way to securely use OnlyKey in the browser. The Webcrypt app loads everything necessary to encrypt messages and files directly in the local browser without the need to send messages or files over the Internet. Data between [OnlyKey](https://onlykey.io)and the local browser is end-to-end encrypted.
7
7
8
-
Supports Firefox, Google Chrome, Brave, and Edge (new) browsers!
8
+
WebCrypt integrates with services like [Keybase](https://keybase.io/)and [Protonmail](https://protonmail.com) to provide OpenPGP encryption and key management everywhere on-the-go. With OnlyKey you have offline cold storage of your OpenPGP keys and can still easily encrypt messages and files.
9
9
10
-
Supports macOS, Windows, Linux, Chrome OS, Android, and iPhone (Safari on iOS 13.3+)!
10
+
- Supports Firefox, Google Chrome, Brave, and Edge (new) browsers!
11
+
- Supports macOS, Windows, Linux, Chrome OS, Android, and iPhone (Safari on iOS 13.3+)
11
12
12
13
[Try it out here!](https://apps.crp.to)
13
14
14
15
[Encrypt Files](https://apps.crp.to/encrypt-file)
16
+
15
17
[Decrypt Files](https://apps.crp.to/decrypt-file)
18
+
16
19
[Encrypt Messages](https://apps.crp.to/encrypt)
20
+
17
21
[Decrypt Messages](https://apps.crp.to/decrypt)
18
22
19
23
## How it works
20
24
21
-
With Keybase user/key management is made easy and with OnlyKey private keys remain securely offline. Private keys are not accessible to the browser or even the local computer. By using FIDO2 as a secure communication channel the web application can send messages to OnlyKey that are decrypted and signed offline. This provides similar function to a token/smart card but no drivers or software required. All that is needed is a browser that supports FIDO2 and an OnlyKey to send secure messages and files.
25
+
With Keybase and/or Protonmail management of identify and keys is easy, these services allow storage and searching of public keys. These public keys can then be retrieved and used to encrypt or verify messages and files. OnlyKey WebCrypt allows composing encrypted messages and encrypting files similarly to composing an email. The recipient is either a user's Keybase username, Protonmail email, or a pasted public key. The sender can be anyone allowing OnlyKey user's to use WebCrypt to receive encrypted messages and files from anyone, even non-OnlyKey users.
26
+
27
+
With OnlyKey, private keys remain securely offline. Private keys are not accessible to the browser or even the local computer. This provides similar function to a token/smart card but no drivers or software required. All that is needed is a browser that supports FIDO2 and an OnlyKey to send secure messages and files.
28
+
29
+
## How to send an encrypted message
22
30
23
-
**Step 1. Find a Keybase User -** The first step in sending a secure message or file is to identify who to send it to. Browse to [https://apps.crp.to/search](https://apps.crp.to/search) to use our custom Keybase search tool to search Keybase users by:<br>
31
+
{% include callout.html content="**Find a recipient -** The first step in sending a secure message or file is to identify who to send it to. Browse to [https://apps.crp.to/search](https://apps.crp.to/search) to use our custom Keybase/Protonmail search tool to search for Keybase usernames and Protonmail email addresses.<br>
32
+
This search tool returns information that can be used to match users based on:<br>
24
33
- Twitter, Github, Reddit, or Hackernews Usernames<br>
25
34
- Web domains<br>
26
-
- PGP fingerprint<br>
27
-
- Or Automatically search for best match" type="default
35
+
- PGP fingerprint<br>" type="default" %}
28
36
37
+
{% include image.html file="user-search.jpg" %}
29
38
30
-
**Step 2. Send a user encrypted message or file -** Click the link in the search results to send the selected user encrypted message/file. You can also browse to [https://apps.crp.to/encrypt](https://apps.crp.to/encrypt) to send a secure message or browse to [https://apps.crp.to/encrypt-file](https://apps.crp.to/encrypt-file) to send a secure file if you already know the recipient. To encrypt files for yourself just use your Keybase username as the recipient.
39
+
{% include callout.html content="**Send a user encrypted message or file -** Click the link in the search results to send the selected user encrypted message/file. You can also browse to [https://apps.crp.to/encrypt](https://apps.crp.to/encrypt) to send a secure message or browse to [https://apps.crp.to/encrypt-file](https://apps.crp.to/encrypt-file) to send a secure file if you already know the recipient. To encrypt files for yourself just use your Keybase username or Protonmail email as the recipient. " type="default" %}
31
40
41
+
{% include image.html file="webcrypt1.png" %}
32
42
33
-
**Step 3. Receive an encrypted message or file -** To decrypt a message or file browse to [https://apps.crp.to/decrypt](https://apps.crp.to/decrypt) or [https://apps.crp.to/decrypt-file](https://apps.crp.to/decrypt-file).
43
+
## How to receive an encrypted message
34
44
35
-
You can receive encrypted messages and files from anyone, no tech skills are required!<br><br>
45
+
{% include callout.html content="**Receive an encrypted message or file -** To decrypt a message or file browse to [https://apps.crp.to/decrypt](https://apps.crp.to/decrypt) or [https://apps.crp.to/decrypt-file](https://apps.crp.to/decrypt-file). " type="default" %}
46
+
47
+
{% include image.html file="webcrypt2.png" %}
48
+
49
+
{% include tip.html content="
50
+
You can receive encrypted messages and files from anyone, no technical skills are required!<br><br>
36
51
Receiving encrypted files is as easy as putting a custom link in your email signature:<br><br>
37
52
**Bob Smith**<br>
38
53
**Email:**Bobsmith@bobsmith.com<br>
@@ -48,82 +63,81 @@ Receiving encrypted files is as easy as putting a custom link in your email sign
48
63
<br><br>
49
64
- Add a **'More info'** link to: https://onlykey.io/pages/webcrypt<br>
50
65
This link provides information to let your sender know what WebCrypt is, why it's secure, and includes a quick 30 second video that will shows how to use it.<br>
51
-
[](https://vimeo.com/374672956)
66
+
[](https://vimeo.com/374672956)" %}
52
67
53
68
### See WebCrypt in action {#openpgp-action}
54
69
55
-
After configuring your OnlyKey following [these instructions](https://docs.crp.to/usersguide.html#generating-keys) you can browse to the [Webcrypt app](https://apps.crp.to/encrypt) to send secure messages/files.
70
+
After configuring your OnlyKey following [these instructions](https://docs.crp.to/importpgp.html#generating-keys) you can browse to the [Webcrypt app](https://apps.crp.to/encrypt) to send secure messages/files.
56
71
57
-
Watch a video [here](https://vimeo.com/374653109) that demonstrates using OnlyKey WebCrypt for file encryption<br>[](https://vimeo.com/374653109)
72
+
{% include tip.html content="Watch a video [here](https://vimeo.com/374653109) that demonstrates using OnlyKey WebCrypt for file encryption<br>[](https://vimeo.com/374653109)" %}
58
73
59
-
#### Sending secure messages/files
74
+
#### Step-by-step sending your first message
60
75
61
76
To create encrypted PGP message or file just:
62
-
- Browse to https://apps.crp.to/encrypt or https://apps.crp.to/encrypt-file
63
-
- Enter the recipient's Keybase ID in the first box
64
-
- Enter your Keybase ID (for the key you loaded onto OnlyKey) in the second box
77
+
- Browse to [https://apps.crp.to/encrypt](https://apps.crp.to/encrypt)
78
+
- Enter the recipient's Keybase username or Protonmail email in the first box
79
+
- Enter your Keybase username or Protonmail email (for the key you loaded onto OnlyKey) in the second box.
80
+
81
+
{% include tip.html content="If you didn't load your key onto OnlyKey follow these [these instructions](https://docs.crp.to/importpgp.html#generating-keys)" %}
82
+
65
83
- Enter your secure message in the third box
66
84
- Click "Encrypt and Sign"
67
85
- When prompted enter the challenge code onto the OnlyKey
68
86
69
-
The encrypted message will be displayed and you can paste it into an email, IM, app or pretty much anything. The encrypted .gpg file will be downloaded to your computer.
87
+
The encrypted message will be displayed and you can paste it into an email, IM, app or pretty much anything.
70
88
71
-
*Alternatively, if you don't want to use Keybase you can paste a public key*
89
+
*Alternatively, if you don't want to use Keybase or Protonmail you can paste a public key*
72
90
73
-
#### Receiving secure messages/files
91
+
#### Step-by-step receiving encrypted files
74
92
75
-
To decrypt PGP message or file just:
76
-
- Browse to https://apps.crp.to/decrypt or https://apps.crp.to/decrypt-file
77
-
- If you know the Keybase ID of the sender enter this in the first box, if you don't know this click the "Decrypt Only" radio button.
78
-
-Paste your encrypted PGP message in the second box or choose encrypted file
93
+
To decrypt an OpenPGP encrypted file just:
94
+
- Browse to [https://apps.crp.to/decrypt-file](https://apps.crp.to/decrypt-file)
95
+
- If you know the Keybase username/Protonmail email of the sender enter this in the first box, if you don't know this click the "Decrypt Only" radio button.
96
+
-Choose encrypted file (should end in .gpg file extension)
79
97
- Click Decrypt
80
98
- When prompted enter the challenge code onto the OnlyKey
81
99
82
-
The decrypted message will be displayed or the decrypted zip file downloaded.
100
+
The decrypted zip file will be automatically downloaded.
83
101
84
-
Messages and files sent via Webcrypt are never sent over the internet. The way it works is the necessary files are downloaded to your browser and all processing is done in your browser. Read more about [Webcrypt security here](https://docs.crp.to/webcrypt.html#security-goals)
102
+
{% include note.html content="Messages and files encrypted via Webcrypt do not send your data over the internet. The way it works is the necessary files are downloaded to your browser and all processing is done in your browser. Read more about [Webcrypt security here](https://docs.crp.to/webcrypt.html#security-goals)" %}
85
103
86
104
## Benefits
87
105
88
106
### Universal Support
89
107
90
-
This is accomplished by using the FIDO2 communication channel to communicate with a USB hardware device. The universal support for FIDO2 allows the web application to be used anywhere FIDO2 is supported including browsers on Android, iPhone (iOS 13.3+), Windows, Mac OS, Linux, and Chromebook. The web app can also be released as a native app that does not require a web browser if this is preferred.
108
+
This is accomplished by using the FIDO2 communication channel to communicate with a USB hardware device. The universal support for FIDO2 allows the web application to be used anywhere FIDO2 is supported including browsers on Android, iPhone (iOS 13.3+), Windows, Mac OS, Linux, and Chromebook. The web app can also be released as a native app that does not require a web browser if this is preferred.[More information on Android/iOS support](https://docs.crp.to/mobile)
91
109
92
110
### Key Management
93
111
94
-
In addition to universal support, OnlyKey WebCrypt works with Keybase for easy user key management. Key management is one of the most difficult issues to solve when it comes to encrypting messages and files.
112
+
In addition to universal support, OnlyKey WebCrypt works with Keybase and Protonmail for easy user key management. Key management is one of the most difficult issues to solve when it comes to encrypting messages and files.
95
113
96
-
### User Search
114
+
### Better than a PGP key server
97
115
98
-
The first step in secure communication is often finding the person to communicate with and having assurance that it is them. With the OnlyKey WebCrypt Search its easy to find users on Keybase by:
99
-
- Twitter, Github, Reddit, or Hackernews Usernames
100
-
- Web domains
101
-
- PGP fingerprint
102
-
- Or Automatically search for best match
116
+
The first step in secure communication is often finding the person to communicate with and having assurance that it is them. By identifying users from their Keybase registered social media profiles, domains, PGP fingerprints, or known Protonmail email address, this provides higher assurance of user identity than use of traditional PGP key servers.
103
117
104
118
### Better than a Smart Card
105
119
106
-
Smart cards are a popular way for keeping keys offline but they are not exactly known for being easy to use and are definitely not universally supported. OnlyKey provides similar function to a token/smart card but no drivers or software is required. Additionally, physical user presence is required to process secure messages/files. This is in contrast to Smart cards which only require a PIN code that can be captured and replayed without physical user presence allowing malware to decrypt a user’s data.
120
+
Smart cards are a popular way for enterprises to keep cryptographic keys protected but they are not known for being easy to use and are definitely not universally supported. OnlyKey provides similar function to a token/smart card but no drivers or software is required. Additionally, physical user presence is required to process secure messages/files. This is in contrast to Smart cards which only require a PIN code that can in some cases be captured and replayed without physical user presence resulting in security compromise.
107
121
108
122
### Better than OpenPGP
109
123
110
-
OpenPGP is widely used but not exactly known for being easy to use. There have been efforts such as Keybase and Protonmail that make OpenPGP easier to use but require that private keys are accessible in software or the cloud. This means that in some cases user’s OpenPGP keys may be obtained by phishing attacks, malware, or software vulnerabilities. OnlyKey WebCrypt supports OpenPGP keys that are compatible with Protonmail, Keybase, Mailvelope, GPG, and others while allowing users to securely keep their keys offline.
124
+
OpenPGP is widely used but not known for being easy to use. There have been efforts such as Keybase and Protonmail that make OpenPGP easier to use but require that private keys are accessible in software or the cloud. This means that in some cases user’s OpenPGP keys may be compromised by phishing attacks, malware, or software vulnerabilities. OnlyKey WebCrypt supports OpenPGP keys that are compatible with Protonmail, Keybase, Mailvelope, GPG, and others while allowing users to securely keep their keys offline and protected.
111
125
112
126
## Security Goals {#security-goals}
113
127
114
-
**Make PGP easy**: Traditional PGP makes journalists angry, we think you shouldn't have to be technologically savvy to use PGP so we built WebCrypt.
128
+
**Make PGP easier**: Traditional PGP makes journalists angry, we think you shouldn't have to be technologically savvy to use PGP or worry that a software vulnerability could compromise your PGP keys, so we built WebCrypt.
115
129
116
130
**Empower the people**: Give people the ability to securely send and receive messages using any computer or Android/iOS device with no complicated software/drivers required and no worrying about compromise of user's private identity.
117
131
118
-
**Serverless**: All processing done via javascript in users own browser locally (no server to hack).
132
+
**Serverless**: All encryption/decryption done via javascript in users own browser locally (no server to hack).
119
133
120
134
**Private**: No logins required. No data retention. No tracking!!! No emails. No ads. No demographics. Retain no metadata, or other tracking information.
121
135
122
-
**Strong crypto** - Everything should be sent via HTTPS to/from the web application. Data between local browser and OnlyKey should be encrypted using AES/ECDH shared secret (NaCl + AES-256-GCM). This means on the local computer data is end-to-end encrypted and even if a malicious applications were to intercept communication it would be encrypted and unreadable without the key.
136
+
**Strong crypto** - Everything is sent via HTTPS to/from the web application. Data between local browser and OnlyKey is encrypted using AES/ECDH shared secret (NaCl + AES-256-GCM). This means on the local computer data is end-to-end encrypted and even if a malicious applications were to intercept communication it would be encrypted and unreadable without the key.
123
137
124
138
**Phishing prevention** - The OnlyKey currently only works with apps.crp.to. Other domains are ignored, domains are enforced by origin.
125
139
126
-
**Open source & audit-able** - What you see is what you get this repository is a Github page hosted directly on Github.
140
+
**Open source & audit-able** - What you see is what you get this repository is available on Github.
127
141
128
142
We are always working to make WebCrypt better, pull requests welcome!
129
143
@@ -143,13 +157,13 @@ Human rights activists and journalists may reside in or travel to countries with
143
157
144
158
## Technical Specs
145
159
146
-
The protocol outlined below utilizes existing communication channel via FIDO2.
160
+
The protocol outlined below utilizes existing communication channel via FIDO2. Currently, FIDO2 does not provide end-to-end encryption between the web and security keys. Meaning that USB data is not encrypted and any application with USB read access is able to view FIDO2 data in transit. For our application, a custom extra layer of data in transit encryption was built to ensure that even if there is a local application with access to read USB data the data would be encrypted and unreadable. Only the security key (OnlyKey) and the initiating web application are able to read the encrypted data in our implementation.
147
161
148
162
### Communication Channel Overview (Advanced)
149
163
150
-
FIDO2 utilizes registration and authentication message types. To send data to the OnlyKey, messages are encoded in the Key Handle of the authentication message type. To receive data back, messages are encoded in the signature of the authentication response. This method provides a reliable form of communication that is supported anywhere U2F is supported including Firefox, Chrome, Chromium, Opera, Brave, and Edge (new).
164
+
FIDO2 utilizes registration and authentication message types. To send data to the OnlyKey, messages are encoded in the Key Handle of the authentication message type. To receive data back, messages are encoded in the signature of the authentication response. This method provides a reliable form of communication that is supported anywhere FIDO2 / U2F is supported including Firefox, Chrome, Chromium, Opera, Brave, and Edge (new).
151
165
152
-
The outline below visualizes the use of onlykey-api.js and FIDO2 to communicate via browser to OnlyKey over USB.
166
+
The outline below visualizes the use of FIDO2 to communicate via browser to OnlyKey over USB.
153
167
154
168
```
155
169
┌──────────────┐ ┌─────────┐
@@ -219,6 +233,8 @@ Thanks to http://tilomitra.github.io/prettypages/
219
233
220
234
Copyright 2012 Yahoo! Inc. All rights reserved. Licensed under the BSD License. http://yuilibrary.com/license/
221
235
236
+
Thanks to Ron Garret for originally posting a serverless implementation of U2F here - https://github.com/rongarret/u2f-test
237
+
222
238
The MIT License (MIT)
223
239
Copyright (c) 2019 CryptoTrust LLC.
224
240
@@ -260,4 +276,4 @@ For more information on export restrictions see: http://www.apache.org/licenses/
260
276
261
277
## Source
262
278
263
-
[OnlyKey WebCrypt on Github](https://github.com/onlykey/onlykey.github.io)
279
+
[OnlyKey WebCrypt on Github](https://github.com/onlykey/onlykey.github.io)
0 commit comments