Skip to content

RiffleScrambler - a memory-hard password storing function

Notifications You must be signed in to change notification settings

KonradSwierczynski/RiffleScrambler

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

47 Commits
 
 
 
 
 
 
 
 

Repository files navigation

RiffleScrambler

The project contains two versions (Python, C++) of RiffleScrambler - a memory-hard password storing function. Both versions slightly modify (optimize) original algorithms from the paper.

C++

rs

Command line interface for using RiffleScrambler.

Examples:

$ ./rs --help             
Password hashing memory-hard function
Usage:
RiffleScrambler  Password is read from stdin [OPTION...] [optional args]

-s, --salt arg   Salt for the given password
-w, --width arg  Width of the graph (default: 12)
-d, --depth arg  Number of stacks of the graph (default: 2)
-f, --func arg   Internal hash function (default: sha256)
-h, --help       Print help
$ echo -n "password" | ./rs somesalt -w 16 -d 2 -f sha224
Graph width:    16
Graph depth:    2
Hash:           166c88a5edfba7228fbf49a4bcd4cb2f01cc5fcdc850bf78c317a5c8
Encoded:        $g=16$d=2$s=c29tZXNhbHQ=$f=sha224$h=MTY2Yzg4YTVlZGZiYTcyM(...)

Tests

Using Catch2.

Benchmarks

Testing RiffleScrambler times and memory statistics for different parameters. Results of bencharks

Python

RiffleScrambler

Implementation in Python3.7.

rs

Simple CLI.

$ ./rs.py --help                 
usage: rs.py [-h] [--width WIDTH] [--depth DEPTH] Password Salt

Riffle Scrambler
positional arguments:
  Password              Password to hash
  Salt                  Salt for the given password
optional arguments:
  -h, --help            show this help message and exit
  --width WIDTH, -w WIDTH
                        Width of the graph
  --depth DEPTH, -d DEPTH
                        How many time graph should be stacked
$ ./rs.py passwd salt1 -w 12 -d 2
8d867f84b8ad158de4fbad8c0da5d66cba4ac207

About

RiffleScrambler - a memory-hard password storing function

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages