[bug#77203,4/4] gnu: Add fscryptctl.

Message ID 94217c998d82635f75c7061d5d7a39b16729e3a3.1742726021.git.45mg.writes@gmail.com
State New
Headers
Series gnu: Add fscrypt. |

Commit Message

45mg March 23, 2025, 10:34 a.m. UTC
  * gnu/packages/crypto.scm (fscryptctl): New variable.

Change-Id: I98b0100402307d0f3e0af6d46e0d1abbf7cd59d5
---
 gnu/packages/crypto.scm | 33 +++++++++++++++++++++++++++++++++
 1 file changed, 33 insertions(+)
  

Patch

diff --git a/gnu/packages/crypto.scm b/gnu/packages/crypto.scm
index bbbe4a1ba0..cdc8513050 100644
--- a/gnu/packages/crypto.scm
+++ b/gnu/packages/crypto.scm
@@ -28,6 +28,7 @@ 
 ;;; Copyright © 2023 Ivan Vilata-i-Balaguer <ivan@selidor.net>
 ;;; Copyright © 2023 Foundation Devices, Inc. <hello@foundationdevices.com>
 ;;; Copyright © 2024 Janneke Nieuwenhuizen <janneke@gnu.org>
+;;; Copyright © 2025 45mg <45mg.writes@gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -65,6 +66,7 @@  (define-module (gnu packages crypto)
   #:use-module (gnu packages golang-crypto)
   #:use-module (gnu packages golang-build)
   #:use-module (gnu packages graphviz)
+  #:use-module (gnu packages haskell-xyz)
   #:use-module (gnu packages image)
   #:use-module (gnu packages kerberos)
   #:use-module (gnu packages libbsd)
@@ -407,6 +409,37 @@  (define-public keyutils
     (license (list license:lgpl2.1+             ; the files keyutils.*
                    license:gpl2+))))            ; the rest
 
+(define-public fscryptctl
+  (package
+    (name "fscryptctl")
+    (version "1.2.0")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/google/fscryptctl")
+             (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32 "15zbmh9jlhqbai7lcaqyvymrjjcdi0l9zli9j51skwap59sq9jz6"))))
+    (build-system gnu-build-system)
+    (arguments
+     (list
+      #:make-flags #~(list (string-append "PREFIX=" #$output)
+                           (string-append "CC=" #$(cc-for-target)))
+      #:tests? #f  ;Test setup requires root
+      #:phases
+      #~(modify-phases %standard-phases
+          (delete 'configure))))
+    (native-inputs (list pandoc))
+    (home-page "https://github.com/google/fscryptctl")
+    (synopsis "Small C tool for Linux filesystem encryption")
+    (description "@command{fscryptctl} is a low-level tool written in C that
+handles raw keys and manages policies for Linux filesystem encryption,
+specifically the @code{fscrypt} kernel interface which is supported by the
+ext4, f2fs, UBIFS, and CephFS filesystems.")
+    (license license:asl2.0)))
+
 (define-public ssss
   (package
     (name "ssss")