Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
6
Task/SHA-1/Common-Lisp/sha-1.lisp
Normal file
6
Task/SHA-1/Common-Lisp/sha-1.lisp
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
;;; in addition to sha1, ironclad provides sha224, sha256, sha384, and sha512.
|
||||
(defun sha1-hash (data)
|
||||
(let ((sha1 (ironclad:make-digest 'ironclad:sha1))
|
||||
(bin-data (ironclad:ascii-string-to-byte-array data)))
|
||||
(ironclad:update-digest sha1 bin-data)
|
||||
(ironclad:byte-array-to-hex-string (ironclad:produce-digest sha1))))
|
||||
Loading…
Add table
Add a link
Reference in a new issue