sha1
(setq SHA1 (import "libssl.so.4" "SHA1")) (join (map (lambda (x) (format "%02x" (& x 0xff))) (unpack (dup "c" 20) (get-string (SHA1 "abc" 3 0))))) ;; produces "a9993e364706816aba3e25717850c26c9cd0d89d"
DZone Snippets > frontera000 > sha1
12158 users tagging and storing useful source code snippets
Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world
(setq SHA1 (import "libssl.so.4" "SHA1")) (join (map (lambda (x) (format "%02x" (& x 0xff))) (unpack (dup "c" 20) (get-string (SHA1 "abc" 3 0))))) ;; produces "a9993e364706816aba3e25717850c26c9cd0d89d"