Skip to content

Commit

Permalink
Merge branch 'electron-app' of https://github.com/alichtman/macOS-qui…
Browse files Browse the repository at this point in the history
…ck-lock into electron-app
  • Loading branch information
shobrook committed Mar 19, 2020
2 parents a2587ac + 814e819 commit 6b88112
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 44 deletions.
36 changes: 22 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@
`deadbolt` removes all of the complication of encrypting and decrypting files. Select a file you'd like to encrypt, enter a password and... that's it. Decrypting the file is as easy as entering the password.

`deadbolt` is built to work on `Linux`, `macOS`, and `Windows`, making it incredibly easy to share encrypted files across different platforms.
`deadbolt` is built to work on `Linux`, `macOS`, and `Windows`, meaning that you can share encrypted files across platforms.

This script can encrypt any file. To encrypt directories, compress them beforehand (`.zip`, `.tar.gz`, etc.)
`deadbolt` can encrypt any file. To encrypt directories, compress them beforehand (`.zip`, `.tar.gz`, etc.)

## Installation

Expand All @@ -35,10 +35,16 @@ $ git clone https://github.com/alichtman/deadbolt.git
$ cd deadbolt
$ npm run preelectron-pack && npm run dist
# macOS installation
$ mv dist/mac/deadbolt.app /Applications/deadbolt.app
$ mv dist/mac/Deadbolt.app /Applications/Deadbolt.app
```

## Setting `deadbolt` as Default App for `.dbolt` Files on macOS
## FAQ

### Showing Extensions on `macOS`

By default, `macOS` hides file extensions. To reduce confusion about what type each file is, I recommend configuring `macOS` to show file extensions. You can do that with the following command: `$ defaults write NSGlobalDomain AppleShowAllExtensions -bool true && killall Finder`.

### Setting `deadbolt` as Default App for `.dbolt` Files on macOS

You can set this app as the default app for `.dbolt` files, which means you'll be able to double-click on `.dbolt` files to open them with `deadbolt` for decryption.

Expand All @@ -47,17 +53,19 @@ You can set this up the first time you double-click on a `.dbolt` file, or by ri
To do this programmatically, run the following snippet:

```bash
# Set deadbolt as default app for .dbolt files
$ defaults write com.apple.LaunchServices LSHandlers -array-add \
"<dict><key>LSHandlerContentTag</key>
<string>dbolt</string><key>LSHandlerContentTagClass</key>
<string>public.filename-extension</string><key>LSHandlerRoleAll</key>
<string>org.alichtman.deadbolt</string></dict>"

# Restart LaunchServices
$ /System/Library/Frameworks/CoreServices.framework/Versions/A/Framework/LaunchServices.framework/Versions/A/Support/lsregister -kill -domain local -domain system -domain user
$ brew install duti
$ duti -s org.alichtman.deadbolt dyn.ah62d4rv4ge80k2xtrv4a all
```

The output of `$ duti -x dbolt` should then be:

```bash
$ duti -x dbolt
Deadbolt.app
/Applications/Deadbolt.app
org.alichtman.deadbolt
```

## Technical Details

`deadbolt` uses `crypto.js` from the `node.js` standard library for all cryptographic operations. The `AES-256-GCM` cipher. The derived key for the cipher is created using `pbkdf2Sync`, taking in a 64B randomly generated salt and the user generated password, with 10,000 iterations, a 32B key length and `SHA512` digest. The authenticity of the data is verified with the authentication tag provided by using `GCM`.
`deadbolt` uses `crypto.js` from the `node.js` standard library for all cryptographic operations. `AES-256-GCM` is the default encryption algorithm used. The derived key for the cipher is created using `pbkdf2Sync`, taking in a 64B randomly generated salt and the user generated password, with 10,000 iterations, a 32B key length and `SHA512` digest. The authenticity of the data is verified with the authentication tag provided by using `GCM`.
Binary file modified img/deadbolt-header.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "deadbolt",
"version": "0.1.0",
"version": "2.0.0",
"description": "An open source encryption app that even your mom can use.",
"license": "MIT",
"author": "Aaron Lichtman <aaronlichtman@gmail.com>",
Expand Down
27 changes: 0 additions & 27 deletions scripts/create-icns-file.sh

This file was deleted.

2 changes: 0 additions & 2 deletions scripts/release.sh
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
#!/bin/bash
# deadbolt release process

# Increment version

echo "Version increment?"
echo " 1) Major"
echo " 2) Minor"
Expand Down

0 comments on commit 6b88112

Please sign in to comment.