md5 in reportlab

"Shea, Steven K" <[email protected]> Tue, 21 Sep 2021 16:38:43 +0000
Newsgroups gmane.comp.python.reportlab.user
Message-ID <[email protected]>
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