Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
40dcc49
commit e6a0967
Showing
1 changed file
with
25 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,34 @@ | ||
# crypto-equality | ||
|
||
A Clojure library designed to ... well, that part is up to you. | ||
A very small Clojure library for protecting against | ||
[timing attacks][1] when comparing strings or sequences of bytes. | ||
|
||
[1]: https://en.wikipedia.org/wiki/Timing_attack | ||
|
||
## Installation | ||
|
||
Add the following dependency to your `project.clj` file: | ||
|
||
[crypto-equality "0.1.0-SNAPSHOT"] | ||
|
||
## Usage | ||
|
||
FIXME | ||
Require the `crypto.equality` namespace: | ||
|
||
```clojure | ||
(require '[crypto.equality :as crypto]) | ||
``` | ||
|
||
Then use the `eq?` function to compare strings, byte arrays, or any | ||
ordered sequence of integers. | ||
|
||
```clojure | ||
(crypto/eq? "foo" "foo") ;; => true | ||
(crypto/eq? "foo" "bar") ;; => false | ||
``` | ||
|
||
## License | ||
|
||
Copyright © 2013 FIXME | ||
Copyright © 2013 James Reeves | ||
|
||
Distributed under the Eclipse Public License either version 1.0 or (at | ||
your option) any later version. | ||
Distributed under the Eclipse Public License, the same as Clojure. |