From: Sascha Hauer <s.hauer@pengutronix.de>
To: Gerd Pauli <gp@high-consulting.de>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH v1] Crypt and decrypt files using password in keystore.
Date: Mon, 23 Apr 2018 10:39:26 +0200 [thread overview]
Message-ID: <20180423083926.cemu3wzcosahvm4f@pengutronix.de> (raw)
In-Reply-To: <20180420080114.9148-1-gp@high-consulting.de>
Hi Gerd,
On Fri, Apr 20, 2018 at 10:01:14AM +0200, Gerd Pauli wrote:
> Adds ccryptlib library in crypto which implements a
> stream cipher based on the block cipher Rijndael,
> the candidate for the AES standard.
> Compatible with the ccrypt tool in linux
> from Peter Selinger.
>
> +BAREBOX_CMD_START(ccrypt)
> +.cmd = do_ccrypt,
> + BAREBOX_CMD_DESC("Crypt and Decrypt Files")
> + BAREBOX_CMD_OPTS("[-e|-d] -k NAME SRC DST")
> + BAREBOX_CMD_GROUP(CMD_GRP_MISC)
> + BAREBOX_CMD_HELP(cmd_ccrypt_help)
> + BAREBOX_CMD_END
> diff --git a/crypto/Kconfig b/crypto/Kconfig
> index 6d65c24d4..08669a2de 100644
> --- a/crypto/Kconfig
> +++ b/crypto/Kconfig
> @@ -101,4 +101,11 @@ config CRYPTO_KEYSTORE
> This is a simple keystore, which can be used to pass keys
> between several components via simple interface.
>
> +config CRYPTO_CCRYPTLIB
> + bool "ccryptlib"
> + help
> + This option provides functions implementing a stream cipher based
> + on the block cipher rijandel.
> + The cipher is based on Peter Selingers ccrypt implementation.
> +
> endmenu
> diff --git a/crypto/Makefile b/crypto/Makefile
> index a7240d1d6..1231bc76d 100644
> --- a/crypto/Makefile
> +++ b/crypto/Makefile
> @@ -14,3 +14,4 @@ obj-$(CONFIG_DIGEST_SHA512_GENERIC) += sha4.o
> obj-$(CONFIG_CRYPTO_PBKDF2) += pbkdf2.o
> obj-$(CONFIG_CRYPTO_RSA) += rsa.o
> obj-$(CONFIG_CRYPTO_KEYSTORE) += keystore.o
> +obj-$(CONFIG_CRYPTO_CCRYPTLIB) += ccryptlib.o
> diff --git a/crypto/ccryptlib.c b/crypto/ccryptlib.c
> new file mode 100644
> index 000000000..78f0ac843
> --- /dev/null
> +++ b/crypto/ccryptlib.c
Is this the same as the Linux Kernel has in crypto/aes_generic.c? If
yes, then please use it. If no, then why not? ;)
Generally any crypto code should integrate into the barebox crypto API
(which is basically the same as the Linux crypto API). This is the main
road blocker that must be removed before we can merge this into barebox.
Sascha
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
next prev parent reply other threads:[~2018-04-23 8:39 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-04-20 8:01 Gerd Pauli
2018-04-22 8:27 ` Oleksij Rempel
2018-04-23 8:13 ` Sascha Hauer
2018-04-23 8:33 ` Oleksij Rempel
2018-04-23 8:39 ` Sascha Hauer [this message]
2018-04-23 12:52 ` Gerd Pauli
2018-04-25 8:23 ` Sascha Hauer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180423083926.cemu3wzcosahvm4f@pengutronix.de \
--to=s.hauer@pengutronix.de \
--cc=barebox@lists.infradead.org \
--cc=gp@high-consulting.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox