Doc #78628 [Com]: AES-256-XTS cipher method does not work

[email protected] ("paybyplatema at gmail dot com") Sat, 09 Sep 2023 07:42:35 +0000
Newsgroups php.doc.bugs
Message-ID <[email protected]>
Edit report at https://bugs.php.net/bug.php?id=78628&edit=1

 ID:                 78628
 Comment by:         paybyplatema at gmail dot com
 Reported by:        [email protected]
 Summary:            AES-256-XTS cipher method does not work
 Status:             Open
 Type:               Documentation Problem
 Package:            OpenSSL related
 Operating System:   Linux
 PHP Version:        7.3.10
 Block user comment: N
 Private report:     N

 New Comment:

The discussion seems to revolve around the support for XTS cipher mode in PHP's openssl_encrypt function. XTS is primarily used for disk encryption and might not have a strong use case within PHP applications. There's a debate about whether PHP should fully support it or throw a warning for cases where it might not work as expected. The final decision would depend on the community's needs and priorities.  (https://github.com.php)(https://paybyplatema.site//)


Previous Comments:
------------------------------------------------------------------------
[2023-07-31 09:22:39] nguyenhoangthanhd3325 at gmail dot com

Wow i found it really nice thanks for sharing such things with us. 

(https://github.com.php)(https://www.myaarpmedicare.dev/)

------------------------------------------------------------------------
[2023-01-23 08:30:00] alisauxbpdsn53 at gmail dot com

That was so amazing. 

(https://www.kohlsfeedback.org/)github.com

------------------------------------------------------------------------
[2019-12-08 18:47:11] [email protected]

Yeah I think this is more documentation issue. Some ciphers require different handling so we shouldn't state that "penssl_encrypt() accepts methods returned from openssl_get_cipher_methods()". In a similar way chacha20-poly1305 doesn't work as AEAD - requested in https://bugs.php.net/bug.php?id=76935 .

------------------------------------------------------------------------
[2019-12-02 09:07:02] [email protected]

I don't really have a use-case, but documentation says that openssl_encrypt() accepts methods returned from openssl_get_cipher_methods(). No mention about some being not implemented or buggy.

The function throws E_WARNING in some cases, maybe that's another case for E_WARNING. Or maybe you have to just make it working.

------------------------------------------------------------------------
[2019-12-01 19:44:59] [email protected]

I think XTS needs a bit more handling so it's not fully supported. We could change this to the request to add support for it but wondering what the actual use case for XTS is in PHP world? It's mainly meant for disk encryption from what I know about this mode.

------------------------------------------------------------------------


The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

    https://bugs.php.net/bug.php?id=78628


--
Edit this bug report at https://bugs.php.net/bug.php?id=78628&edit=1