stackless python 2.7.9 and openssl-1.1.1g

bhashkar prakash Singh singh.bhashkar at gmail.com
Thu Sep 24 14:21:12 EDT 2020


Hi,

I am using stackless Python 2.7.9 in my project and openssl-1.0.2q.
I just upgraded the Openssl  version to 1.1.1g, due to which python
compilation started failing. So, I patched  _hashopenssl.c and _ssl.c file
in Python Modules as per new openssl  to make compilation successful.
But when I run my image on  target HW,  I am getting below errors.  It
looks like Openssl 1.1.1g libraries are not linked to Python.
 I am struggling with this issue since many days. Looks like something I
missed in my patching. Could someone please help on this.

ERROR:root:code for hash md5 was not found.
Traceback (most recent call last):
  File "/usr/lib/python2.7/hashlib.py", line 147, in <module>
    globals()[__func_name] = __get_hash(__func_name)
  File "/usr/lib/python2.7/hashlib.py", line 109, in
__get_openssl_constructor
    return __get_builtin_constructor(name)
  File "/usr/lib/python2.7/hashlib.py", line 97, in
__get_builtin_constructor
    raise ValueError('unsupported hash type ' + name)
ValueError: unsupported hash type md5
ERROR:root:code for hash sha1 was not found.
Traceback (most recent call last):
  File "/usr/lib/python2.7/hashlib.py", line 147, in <module>
    globals()[__func_name] = __get_hash(__func_name)
  File "/usr/lib/python2.7/hashlib.py", line 109, in
__get_openssl_constructor
    return __get_builtin_constructor(name)
  File "/usr/lib/python2.7/hashlib.py", line 97, in
__get_builtin_constructor
    raise ValueError('unsupported hash type ' + name)
ValueError: unsupported hash type sha1
ERROR:root:code for hash sha224 was not found.
Traceback (most recent call last):
  File "/usr/lib/python2.7/hashlib.py", line 147, in <module>
    globals()[__func_name] = __get_hash(__func_name)
  File "/usr/lib/python2.7/hashlib.py", line 109, in
__get_openssl_constructor
    return __get_builtin_constructor(name)
  File "/usr/lib/python2.7/hashlib.py", line 97, in
__get_builtin_constructor
    raise ValueError('unsupported hash type ' + name)
ValueError: unsupported hash type sha224
ERROR:root:code for hash sha256 was not found.
Traceback (most recent call last):
  File "/usr/lib/python2.7/hashlib.py", line 147, in <module>
    globals()[__func_name] = __get_hash(__func_name)
  File "/usr/lib/python2.7/hashlib.py", line 109, in
__get_openssl_constructor
    return __get_builtin_constructor(name)
  File "/usr/lib/python2.7/hashlib.py", line 97, in
__get_builtin_constructor
    raise ValueError('unsupported hash type ' + name)
ValueError: unsupported hash type sha256
ERROR:root:code for hash sha384 was not found.
Traceback (most recent call last):
  File "/usr/lib/python2.7/hashlib.py", line 147, in <module>
    globals()[__func_name] = __get_hash(__func_name)
  File "/usr/lib/python2.7/hashlib.py", line 109, in
__get_openssl_constructor
    return __get_builtin_constructor(name)
  File "/usr/lib/python2.7/hashlib.py", line 97, in
__get_builtin_constructor
    raise ValueError('unsupported hash type ' + name)
ValueError: unsupported hash type sha384
ERROR:root:code for hash sha512 was not found.
Traceback (most recent call last):
  File "/usr/lib/python2.7/hashlib.py", line 147, in <module>
    globals()[__func_name] = __get_hash(__func_name)
  File "/usr/lib/python2.7/hashlib.py", line 109, in
__get_openssl_constructor
    return __get_builtin_constructor(name)
  File "/usr/lib/python2.7/hashlib.py", line 97, in
__get_builtin_constructor
    raise ValueError('unsupported hash type ' + name)
ValueError: unsupported hash type sha512

Thanks & Regards,
Bhashkar


More information about the Python-list mailing list