[IntelMQ-users] Installation problems intelmq and manager

Sebix sebix at sebix.at
Fri Mar 25 15:05:45 CET 2022


Dear Christian,

Can you please check if hug-middleware-cors is installed and if not, if
installing https://pypi.org/project/hug-middleware-cors/ via apt or pip
solves your issue?

Regarding the (solved) wsgi problem: intelmq-api actually recommends the
libapache2-mod-wsgi-py3 package, see:
https://github.com/certtools/intelmq-api/blob/9f8513bb0268144b62522e67bee3c290eb6eac8a/debian/control#L27

kind regards
Sebastian

On 3/25/22 2:49 PM, Harbich, Christian wrote:
> Hi,  I got one step further. Now I get the following error:
>
> [Fri Mar 25 14:45:25.398585 2022] [wsgi:error] [pid 12422] [client 127.0.0.1:48246] Loading config from /etc/intelmq/api-config.json
> [Fri Mar 25 14:45:25.398851 2022] [wsgi:error] [pid 12422] [client 127.0.0.1:48246] mod_wsgi (pid=12422): Exception occurred processing WSGI script '/usr/lib/python3/dist-packages/intelmq_api/intelmq-api.wsgi'.
> [Fri Mar 25 14:45:25.399160 2022] [wsgi:error] [pid 12422] [client 127.0.0.1:48246] Traceback (most recent call last):
> [Fri Mar 25 14:45:25.399196 2022] [wsgi:error] [pid 12422] [client 127.0.0.1:48246]   File "/usr/lib/python3/dist-packages/intelmq_api/intelmq-api.wsgi", line 11, in application
> [Fri Mar 25 14:45:25.399205 2022] [wsgi:error] [pid 12422] [client 127.0.0.1:48246]     from intelmq_api.serve import __hug_wsgi__
> [Fri Mar 25 14:45:25.399218 2022] [wsgi:error] [pid 12422] [client 127.0.0.1:48246]   File "/usr/lib/python3/dist-packages/intelmq_api/serve.py", line 31, in <module>
> [Fri Mar 25 14:45:25.399225 2022] [wsgi:error] [pid 12422] [client 127.0.0.1:48246]     api.http.add_middleware(hug.middleware.CORSMiddleware(api, allow_origins=api_config.allow_origins))
> [Fri Mar 25 14:45:25.399254 2022] [wsgi:error] [pid 12422] [client 127.0.0.1:48246] AttributeError: module 'hug.middleware' has no attribute 'CORSMiddleware'
>
> I found this post: https://github.com/certtools/intelmq-api/issues/28 and tried 
> apt update && apt upgrade && systemctl restart apache2 
> but that didn't work for me. The problem is, that we use our own repo which is managed by our linux administrators. Can I apply the fix manually? Otherwise wich package has to be updated in our repo to get it working?
>
> Cheers
> Christian
>
> -----Ursprüngliche Nachricht-----
> Von: IntelMQ-users <intelmq-users-bounces at lists.cert.at> Im Auftrag von Bernhard Reiter
> Gesendet: Freitag, 25. März 2022 13:42
> An: intelmq-users at lists.cert.at
> Betreff: Re: [IntelMQ-users] Installation problems intelmq and manager
>
> Hi Christian,
>
> Am Freitag, 25. März 2022, 08:20:17 CET schrieb Harbich, Christian:
>> root at server:~# dpkg -L intelmq-api
>> The file /usr/lib/python3/dist-packages/intelmq_api/serve.py is listed 
>> but the error message said "No module named intelmq_api.serve"
> which means that the python version called by this Apache module does not find it.
>
> Try installing
>   https://packages.ubuntu.com/bionic/libapache2-mod-wsgi-py3
> and removing libapache2-mod-wsgi
> as this version is still be compiled with python2. ;) Bernhard
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cert.at/pipermail/intelmq-users/attachments/20220325/f4be30be/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <http://lists.cert.at/pipermail/intelmq-users/attachments/20220325/f4be30be/attachment.sig>


More information about the IntelMQ-users mailing list