guix-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Using G-Expressions for public keys (substitutes and possibly more)


From: Ludovic Courtès
Subject: Re: Using G-Expressions for public keys (substitutes and possibly more)
Date: Tue, 23 Nov 2021 18:14:01 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux)

Liliana Marie Prikler <liliana.prikler@gmail.com> skribis:

> Am Montag, den 22.11.2021, 14:27 +0100 schrieb Ludovic Courtès:

[...]

> sexp->canonical-sexp is from the comment surrounding it a rather hacky
> beast.  I think (guile-)gcrypt could very well benefit from having a
> better sexp construction API, but again that's outside the scope of
> Guix.
>
> But since you're asking, I do feel there's a lot guile-gcrypt could
> borrow from Guix, just not right now in an efficient manner thanks to
> needing to jump through the sexp->canonical-sexp hoops.  It could have
> semantic constructors and field sanitization à la (guix records) for
> example.  WDYT?

Fundamentally, Guile-Gcrypt is just bindings to libgcrypt.  As such, it
tries hard to remain close to libgcrypt’s API, and I think that’s a safe
approach for bindings in general.

Libgcrypt internally uses canonical sexps for key material,
configuration options, etc. (an illustration of Greenspun’s Tenth Rule
:-)), so that’s what Guile-Gcrypt exposes, and I think it’s fine.

Thanks,
Ludo’.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]