diff options
author | Jakob Unterwurzacher | 2017-02-22 23:55:43 +0100 |
---|---|---|
committer | Jakob Unterwurzacher | 2017-02-22 23:56:34 +0100 |
commit | 1e03e059fa0980db8d527f1c01094999d8813b95 (patch) | |
tree | 950f537f1fa58e9f0506a540b31d790030e69a1d /main.go | |
parent | b056776a013813e251aa37027c3aaa3f1e22d7c8 (diff) |
Implement "gocryptfs -speed"
A crypto benchmark mode like "openssl speed".
Example run:
$ ./gocryptfs -speed
AES-GCM-256-OpenSSL 180.89 MB/s (selected in auto mode)
AES-GCM-256-Go 48.19 MB/s
AES-SIV-512-Go 37.40 MB/s
Diffstat (limited to 'main.go')
-rw-r--r-- | main.go | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -13,6 +13,7 @@ import ( "github.com/rfjakob/gocryptfs/internal/configfile" "github.com/rfjakob/gocryptfs/internal/contentenc" "github.com/rfjakob/gocryptfs/internal/readpassword" + "github.com/rfjakob/gocryptfs/internal/speed" "github.com/rfjakob/gocryptfs/internal/stupidgcm" "github.com/rfjakob/gocryptfs/internal/tlog" ) @@ -149,6 +150,11 @@ func main() { printVersion() os.Exit(0) } + // "-speed" + if args.speed { + speed.Run() + os.Exit(0) + } if args.wpanic { tlog.Warn.Wpanic = true tlog.Debug.Printf("Panicing on warnings") |