Skip to content

Latest commit

 

History

History
25 lines (17 loc) · 765 Bytes

README.md

File metadata and controls

25 lines (17 loc) · 765 Bytes

SecureCompare for Elixir

hex.pm version Build Status

A simple constant-time comparison algorithm for Elixir based on the Devise.secure_compare method found here.

Installation

The package can be installed by adding secure_compare to your list of dependencies in mix.exs:

def deps do
  [{:secure_compare, "~> 0.1.0"}]
end

Usage

a = "123"
b = "456"

SecureCompare.compare(a, b) # => false