manpagez: man pages & more
info bigloo
Home | html | info | man
[ << ] [ < ] [ Up ] [ > ] [ >> ]         [Top] [Contents] [Index] [ ? ]

15 Cryptography

Bigloo provides several functions for encrypting and decrypting documents. These are described in the chapter. Unless explicitly mentioned all functions presented in this document are accessible via the crypto library.

None of the cryptographic functions are protected against timing attacks. No effort has been spent on protecting used memory.

Here is an example of a module that uses this library:

;; Encrypt a string using AES.
(module aes-encrypt
   (library crypto)
   (main main))

(define (main argv)
   (when (and (pair? (cdr argv)) (pair? (cddr argv)))
      (let ((encrypt? (string=? "-e" (cadr argv)))
            (passwd (caddr argv))
            (input (read-string)))
         (if encrypt?
             (display (encrypt 'aes input passwd))
             (display (decrypt 'aes input passwd))))))

This document was generated on March 31, 2014 using texi2html 5.0.

© manpagez.com 2000-2024
Individual documents may contain additional copyright information.