Seafile Server CE 9.0.10 - Error creating password protected download links

Hi,

I just discovered that it’s not possible to create a password protected download link. Download links without a password or with a time restriction can be created.

seahub.log contains this messages:

2022-12-13 12:46:25,901 [ERROR] django.request:224 log_response Internal Server Error: /api/v2.1/share-links/
Traceback (most recent call last):
File “/usr/local/seafile/seafile-server-9.0.10/seahub/thirdpart/django/core/handlers/exception.py”, line 47, in inn
er
response = get_response(request)
File “/usr/local/seafile/seafile-server-9.0.10/seahub/thirdpart/django/core/handlers/base.py”, line 181, in _get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
File “/usr/local/seafile/seafile-server-9.0.10/seahub/thirdpart/django/views/decorators/csrf.py”, line 54, in wrapped_view
return view_func(*args, **kwargs)
File “/usr/local/seafile/seafile-server-9.0.10/seahub/thirdpart/django/views/generic/base.py”, line 70, in view
return self.dispatch(request, *args, **kwargs)
File “/usr/local/seafile/seafile-server-9.0.10/seahub/thirdpart/rest_framework/views.py”, line 505, in dispatch
response = self.handle_exception(exc)
File “/usr/local/seafile/seafile-server-9.0.10/seahub/thirdpart/rest_framework/views.py”, line 465, in handle_exception
self.raise_uncaught_exception(exc)
File “/usr/local/seafile/seafile-server-9.0.10/seahub/thirdpart/rest_framework/views.py”, line 476, in raise_uncaught_exception
raise exc
File “/usr/local/seafile/seafile-server-9.0.10/seahub/thirdpart/rest_framework/views.py”, line 502, in dispatch
response = handler(request, *args, **kwargs)
File “/usr/local/seafile/seafile-server-9.0.10/seahub/seahub/api2/endpoints/share_links.py”, line 418, in post
fs = FileShare.objects.create_file_link(username, repo_id, path,
File “/usr/local/seafile/seafile-server-9.0.10/seahub/seahub/share/models.py”, line 157, in create_file_link
return self._add_file_share(username, repo_id, path, ‘f’, password,
File “/usr/local/seafile/seafile-server-9.0.10/seahub/seahub/share/models.py”, line 110, in _add_file_share
password_enc = make_password(password)
File “/usr/local/seafile/seafile-server-9.0.10/seahub/seahub/share/models.py”, line 31, in make_password
aes = AESPasswordHasher()
File “/usr/local/seafile/seafile-server-9.0.10/seahub/seahub/utils/hasher.py”, line 39, in init
self.cipher = AES.new(secret.encode(‘utf-8’), AES.MODE_ECB)
AttributeError: ‘NoneType’ object has no attribute ‘new’

Any idea what might cause this error?

TIA

Thomas