Scrypt

A Clojure library for the scrypt key derivation function. Use it to encrypt passwords and other sensitive data.
Alternatives To Scrypt
Project NameStarsDownloadsRepos Using ThisPackages Using ThisMost Recent CommitTotal ReleasesLatest ReleaseOpen IssuesLicenseLanguage
Staticrypt5,58816a month ago37June 13, 20238mitHTML
Password protect a static HTML page, decrypted in-browser
Node Argon21,67327329012 days ago69September 01, 202319mitJavaScript
Node.js bindings for Argon2 hashing algorithm
Pwd.sh1,495
9 months ago1mitShell
GPG symmetric password manager
Picocrypt1,441
2 months agogpl-3.0Go
A very small, very simple, yet very secure encryption tool.
Yopass1,365
a day ago62April 23, 202128apache-2.0TypeScript
Secure sharing of secrets, passwords and files
Bkcrack1,099
a month ago18zlibC++
Crack legacy zip encryption with Biham and Kocher's known plaintext attack.
Hexo Blog Encrypt9041523 days ago65March 17, 2021mitCSS
Yet, just another hexo plugin for security.
Swifty845
15 days ago48gpl-3.0JavaScript
🔑 Free Offline-first Password Manager
Redditstorage783
6 years ago3Python
Store files onto reddit subreddits.
Link Lock763
20 days ago6mitJavaScript
Password-protect URLs using AES in the browser; create hidden bookmarks without a browser extension
Alternatives To Scrypt
Select To Compare


Alternative Project Comparisons
Readme

Clojure Scrypt Library

scrypt is a tiny Clojure library for the scrypt key derivation function.

Why Use Scrypt

Scrypt has a significantly higher cost of carrying out brute force attacks on hashed values:

Key derivation function comparison

For more details, see the Scrypt paper.

Community

To subscribe for announcements of releases, important changes and so on, please follow @ClojureWerkz on Twitter.

Project Maturity

ClojureWerkz Scrypt is a fairly young project built on top of a Java implementation of Scrypt that has been around for a couple of years.

Artifacts

Scrypt artifacts are released to Clojars. If you are using Maven, add the following repository definition to your pom.xml:

<repository>
  <id>clojars.org</id>
  <url>http://clojars.org/repo</url>
</repository>

The Most Recent Release

With Leiningen:

[clojurewerkz/scrypt "1.2.0"]

With Maven:

<dependency>
  <groupId>clojurewerkz</groupId>
  <artifactId>scrypt</artifactId>
  <version>1.2.0</version>
</dependency>

Documentation

Scrypt has a single namespace: clojurewerkz.scrypt.core, and two functions:

  • clojurewerkz.scrypt.core/encrypt encrypts a string using Scrypt
  • clojurewerkz.scrypt.core/verify verifies a string against a hash produced by encrypt

An example to demonstrate them:

(require '[clojurewerkz.scrypt.core :as sc])

(let [h (sc/encrypt "secret" 16384 8 1)]
        (sc/verify "secret" h))
;= true

(let [h (sc/encrypt "secret" 16384 8 1)]
        (sc/verify "another value" h))
;= false

Arguments that clojurewerkz.scrypt.core/encrypt takes control CPU, RAM and parallelization cost. The values in the example above are optimal starting points for many applications.

See the Scrypt paper for a detailed information.

Native Scrypt Implementation

It is possible to use a native implementation as of ClojureWerkz Scrypt 1.1.0. From Lambdaworks Scrypt documentation:

  When the native library can be loaded it will be used instead of the pure
  Java implementation. On a J2SE compliant JVM the native library will be
  extracted from the jar and loaded, and on other VMs System.loadLibrary will
  be called.

  The system property "com.lambdaworks.jni.loader" may be set to override
  the default native library loader with one of the following values:

   * nil: refuse to load native libraries and revert to pure Java implementation
   * jar: extract native library from jar and load with System.load
   * sys: use System.loadLibrary, which may require java.library.path to be set

Supported Clojure Versions

scrypt requires Clojure 1.4+.

Continuous Integration Status

Continuous Integration status

Scrypt Is a ClojureWerkz Project

This library is part of the group of Clojure libraries known as ClojureWerkz, together with

Development

scrypt uses Leiningen 2. Make sure you have it installed and then run tests against supported Clojure versions using

lein all test

Then create a branch and make your changes on it. Once you are done with your changes and all tests pass, submit a pull request on GitHub.

License

Copyright (C) 2013-2016 Michael S. Klishin, Alex Petrov.

Double licensed under the Eclipse Public License (the same as Clojure) or the Apache Public License 2.0.

Popular Password Projects
Popular Encryption Projects
Popular Security Categories

Get A Weekly Email With Trending Projects For These Categories
No Spam. Unsubscribe easily at any time.
Password
Clojure
Encrypt
Leiningen
Scrypt
Clojure Library