mina-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (Jira)" <j...@apache.org>
Subject [jira] [Work logged] (SSHD-1017) Add support for chacha20-poly1305@openssh.com
Date Sun, 25 Oct 2020 20:27:00 GMT

     [ https://issues.apache.org/jira/browse/SSHD-1017?focusedWorklogId=504599&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-504599
]

ASF GitHub Bot logged work on SSHD-1017:
----------------------------------------

                Author: ASF GitHub Bot
            Created on: 25/Oct/20 20:26
            Start Date: 25/Oct/20 20:26
    Worklog Time Spent: 10m 
      Work Description: jvz commented on a change in pull request #176:
URL: https://github.com/apache/mina-sshd/pull/176#discussion_r511644242



##########
File path: sshd-common/src/main/java/org/apache/sshd/common/cipher/BuiltinCiphers.java
##########
@@ -102,6 +104,31 @@ public Cipher create() {
      */
     @Deprecated
     blowfishcbc(Constants.BLOWFISH_CBC, 8, 0, 16, "Blowfish", 128, "Blowfish/CBC/NoPadding",
8),
+    cc20p1305_openssh(Constants.CC20P1305_OPENSSH, 8, 16, 64, "ChaCha", 256, "ChaCha", 8)
{
+        private volatile Boolean supported;
+
+        @Override
+        public boolean isSupported() {
+            if (supported == null) {
+                synchronized (this) {
+                    if (supported == null) {
+                        try {
+                            SecurityUtils.getCipher("ChaCha");
+                            supported = true;
+                        } catch (GeneralSecurityException ignored) {
+                            supported = false;
+                        }
+                    }
+                }
+            }
+            return supported;
+        }

Review comment:
       I just came across that method today as well. This could technically be supported by
just copying the source code for ChaCha20 and Poly1305 since I had to combine them into the
OpenSSH-specific AEAD form.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Issue Time Tracking
-------------------

    Worklog Id:     (was: 504599)
    Time Spent: 40m  (was: 0.5h)

> Add support for chacha20-poly1305@openssh.com
> ---------------------------------------------
>
>                 Key: SSHD-1017
>                 URL: https://issues.apache.org/jira/browse/SSHD-1017
>             Project: MINA SSHD
>          Issue Type: New Feature
>            Reporter: Matt Sicker
>            Priority: Major
>          Time Spent: 40m
>  Remaining Estimate: 0h
>
> See [protocol details|https://github.com/openbsd/src/blob/master/usr.bin/ssh/PROTOCOL.chacha20poly1305].
> * [RFC 7539|https://tools.ietf.org/html/rfc7539] describes the ChaCha20-Poly1305 algorithm.
> * [Dropbear implementation|https://github.com/mkj/dropbear/blob/master/chachapoly.c]
> * [OpenSSH implementation|https://github.com/openbsd/src/blob/master/usr.bin/ssh/cipher-chachapoly-libcrypto.c]
> The cipher is provided by Bouncycastle.
> As a bonus, this could potentially be adapted to propose an equivalent AES/GCM cipher
encoding to how OpenSSH implements this ChaCha20-Poly1305 cipher.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@mina.apache.org
For additional commands, e-mail: dev-help@mina.apache.org


Mime
View raw message