diff options
author | Nicolas Goaziou <mail@nicolasgoaziou.fr> | 2022-01-18 10:55:29 +0100 |
---|---|---|
committer | Nicolas Goaziou <mail@nicolasgoaziou.fr> | 2022-01-18 10:55:29 +0100 |
commit | f73c2aba1cd73073bc774127d29f5f6bbc3107c8 (patch) | |
tree | a2c20fa8c9643c20b843b1950eb89ea2fa161c11 /gnu/packages/tls.scm | |
parent | 61482a473a4006538463dd8cd28690e47a3f42a7 (diff) | |
download | guix-f73c2aba1cd73073bc774127d29f5f6bbc3107c8.tar.gz |
gnu: Add bearssl.
* gnu/packages/tls.scm (bearssl): New variable.
Diffstat (limited to 'gnu/packages/tls.scm')
-rw-r--r-- | gnu/packages/tls.scm | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/gnu/packages/tls.scm b/gnu/packages/tls.scm index 6bf9c05c39..b0950ec2e5 100644 --- a/gnu/packages/tls.scm +++ b/gnu/packages/tls.scm @@ -616,6 +616,57 @@ OpenSSL for TARGET." #$version "/misc")) #t)))))))))) +(define-public bearssl + (package + (name "bearssl") + (version "0.6") + (source (origin + (method url-fetch) + (uri (string-append "https://www.bearssl.org/" + "bearssl-" version ".tar.gz")) + (sha256 + (base32 + "057zhgy9w4y8z2996r0pq5k2k39lpvmmvz4df8db8qa9f6hvn1b7")))) + (build-system gnu-build-system) + (arguments + (list + #:make-flags + #~(list #$(string-append "CC=" (cc-for-target)) + #$(string-append "LD=" (cc-for-target)) + #$(string-append "LDDLL=" (cc-for-target))) + #:phases + #~(modify-phases %standard-phases + (delete 'configure) ;no configure script + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (with-directory-excursion "build" + (invoke "./testcrypto" "all") + (invoke "./testx509"))))) + (replace 'install ;no install rule + (lambda _ + (let* ((out #$output) + (bin (string-append out "/bin")) + (doc (string-append out "/share/doc/" #$name "-" #$version)) + (lib (string-append out "/lib")) + (include (string-append out "/include"))) + (install-file "build/brssl" bin) + (for-each (lambda (f) (install-file f include)) + (find-files "inc" "\\.h$")) + (install-file "LICENSE.txt" doc) + (install-file "build/libbearssl.so" lib))))))) + (home-page "https://bearssl.org/") + (synopsis "Small SSL/TLS library") + (description "BearSSL is an implementation of the SSL/TLS +protocol (RFC 5246) written in C. It aims at being correct and +secure. In particular, insecure protocol versions and choices of +algorithms are not supported, by design; cryptographic algorithm +implementations are constant-time by default. It should also be +small, both in RAM and code footprint. For instance, a minimal server +implementation may fit in about 20 kilobytes of compiled code and 25 +kilobytes of RAM.") + (license license:expat))) + (define-public libressl (package (name "libressl") |