From steven.k.shea at lmco.com Tue Sep 21 11:22:43 2021 From: steven.k.shea at lmco.com (Shea, Steven K) Date: Tue, 21 Sep 2021 15:22:43 +0000 Subject: [reportlab-users] fips compliant Message-ID: <17ec8b7d370140b3b9db5071dee4d286@lmco.com> Report Lab is using mds to create hashes. Mds is not fips compatible. We had to change that code to use sha1. It's a simple change. Steven Shea Staff Software Engineer -------------- next part -------------- An HTML attachment was scrubbed... URL: From JSSATCHELL at qinetiq.com Tue Sep 21 11:46:37 2021 From: JSSATCHELL at qinetiq.com (Satchell Julian) Date: Tue, 21 Sep 2021 15:46:37 +0000 Subject: [reportlab-users] UC fips compliant Message-ID: <3b7g6h84j6-1@m0121188.ppops.net> SHA-1 is no longer recommended, as collision attacks on it are well known. Minimum is something in the SHA2 family, depending on strength / length requirement. Julian Satchell From: reportlab-users On Behalf Of Shea, Steven K Sent: 21 September 2021 16:23 To: reportlab-users at lists2.reportlab.com Subject: [reportlab-users] fips compliant Report Lab is using mds to create hashes. Mds is not fips compatible. We had to change that code to use sha1. It's a simple change. Steven Shea Staff Software Engineer This email and any attachments to it may be confidential and are intended solely for the use of the individual to whom it is addressed. If you are not the intended recipient of this email, you must neither take any action based upon its contents, nor copy or show it to anyone. Please contact the sender if you believe you have received this email in error. QinetiQ retains personal data relating to our customers and partners for the purposes of conducting a business relationship, communicating and marketing to them as well as to providing invitations to upcoming events. Please see our Privacy Notice ( https://www.qinetiq.com/Privacy-Policy ) for further information. In accordance with our Privacy Notice, you have the right to withdraw your consent at any time. QinetiQ may monitor email traffic data and also the content of email for the purposes of security. QinetiQ Limited (Registered in England & Wales: Company Number: 3796233) Registered office: Cody Technology Park, Ively Road, Farnborough, Hampshire, GU14 0LX https://www.qinetiq.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: From timr at probo.com Tue Sep 21 12:13:17 2021 From: timr at probo.com (Tim Roberts) Date: Tue, 21 Sep 2021 09:13:17 -0700 Subject: [reportlab-users] UC fips compliant In-Reply-To: <3b7g6h84j6-1@m0121188.ppops.net> References: <3b7g6h84j6-1@m0121188.ppops.net> Message-ID: <733949de-1e96-93df-dd6f-912623492cd5@probo.com> Satchell Julian via reportlab-users wrote: > > > SHA-1 is no longer recommended, as collision attacks on it are well > known. Minimum is something in the SHA2 family, depending on strength > / length requirement. > Well, you have to balance the cost against the risk.? With one exception, MD5 is not used in a security context within ReportLab.? It's just a hash algorithm.? There is no "attack vector", and there are no secrets being protected.? For those uses, even SHA1 is overkill, and SHA2 is vast overkill. The one exception is creating a key for PDF encryption, and here they are restricted to the standard.? They can't arbitrarily change the algorithm. -- Tim Roberts, timr at probo.com Providenza & Boekelheide, Inc. -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 3389 bytes Desc: S/MIME Cryptographic Signature URL: From claude at 2xlibre.net Tue Sep 21 12:34:09 2021 From: claude at 2xlibre.net (Claude Paroz) Date: Tue, 21 Sep 2021 18:34:09 +0200 Subject: [reportlab-users] UC fips compliant In-Reply-To: <733949de-1e96-93df-dd6f-912623492cd5@probo.com> References: <3b7g6h84j6-1@m0121188.ppops.net> <733949de-1e96-93df-dd6f-912623492cd5@probo.com> Message-ID: <43aa4672-d942-30cf-2dbe-2e5eacf650f7@2xlibre.net> Le 21.09.21 ? 18:13, Tim Roberts a ?crit?: > Satchell Julian via reportlab-users wrote: >> >> >> SHA-1 is no longer recommended, as collision attacks on it are well >> known. Minimum is something in the SHA2 family, depending on strength >> / length requirement. >> > Well, you have to balance the cost against the risk.? With one > exception, MD5 is not used in a security context within ReportLab.? It's > just a hash algorithm.? There is no "attack vector", and there are no > secrets being protected.? For those uses, even SHA1 is overkill, and > SHA2 is vast overkill. Also note the new usedforsecurity argument added in Python 3.9: https://docs.python.org/3/library/hashlib.html#hashlib-usedforsecurity That could help for FIPS compliance. See also the ticket and patch discussing the same topic for Django: https://code.djangoproject.com/ticket/28401 https://github.com/django/django/pull/14763/ Claude From steven.k.shea at lmco.com Tue Sep 21 12:38:43 2021 From: steven.k.shea at lmco.com (Shea, Steven K) Date: Tue, 21 Sep 2021 16:38:43 +0000 Subject: [reportlab-users] md5 in reportlab Message-ID: ReportLab uses md5 to create hashes for internal use in pdfs. It is not being used for security purposes. So using something like sha1 can be overkill if all you need is a hash. HOWEVER, on a fips compliant system like RedHat, the python md5 does not work and causes errors in the ReportLab code. Here is the error we are seeing: reportlab/pdfbase/pdfdoc.py\", line 150, in __init__ sig = self.signature = md5() ValueError: [digital envelope routines: EVP_DigestInit_ex] disabled for fips We change the md5 calls to sha1 calls in the ReportLab code and all is good. ReportLab needs to address this if they want their library to gain use in certain sectors. Steven Shea Staff Software Engineer -------------- next part -------------- An HTML attachment was scrubbed... URL: