fofapro / vulfocus

🚀Vulfocus 是一个漏洞集成平台,将漏洞环境 docker 镜像,放入即可使用,开箱即用。
Apache License 2.0
3.21k stars 509 forks source link

启动不了vulhub的docker环境 #140

Closed refengs closed 3 years ago

refengs commented 3 years ago

报错信息启动不了vulhub的docker环境

操作系统: centos7

内核版本:Linux iZuf6an 4.18.0-240.1.1.el8_3.x86_64 #1 SMP Thu Nov 19 17:20:08 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux

Python 环境版本:Python 2.7.17 (default, Aug 31 2020, 21:02:14)

Vulfocus 版本:0.3.2.1

详细报错信息或堆栈报错信息: 这是进入vulfocus里面的的celery.log 文件信息 root@5d10d7b11ce9:/vulfocus-api# cat celery.log [2021-01-06 19:51:21,524: INFO/MainProcess] Connected to redis://127.0.0.1:6379/0 [2021-01-06 19:51:21,542: INFO/MainProcess] mingle: searching for neighbors [2021-01-06 19:51:22,577: INFO/MainProcess] mingle: all alone [2021-01-06 19:51:22,585: WARNING/MainProcess] /usr/local/lib/python3.9/site-packages/celery/fixups/django.py:202: UserWarning: Using settings.DEBUG leads to a memory leak, never use this setting in production environments! warnings.warn('''Using settings.DEBUG leads to a memory [2021-01-06 19:51:22,585: INFO/MainProcess] celery@5d10d7b11ce9 ready. [2021-01-06 19:51:38,735: INFO/MainProcess] Received task: tasks.create_image[901093e9-bd93-4b6b-8204-550c9e71d558]
[2021-01-06 19:51:38,781: INFO/MainProcess] Received task: tasks.create_image[972cfdb6-dbe8-429d-8678-da5c6e475b5b]
[2021-01-06 19:51:38,798: INFO/ForkPoolWorker-1] Task tasks.create_image[901093e9-bd93-4b6b-8204-550c9e71d558] succeeded in 0.060795475999839255s: None [2021-01-06 19:51:38,814: INFO/MainProcess] Received task: tasks.create_image[9ef4fc14-78f5-433f-9bc5-3c858a327aa5]
[2021-01-06 19:51:38,887: INFO/ForkPoolWorker-1] Task tasks.create_image[972cfdb6-dbe8-429d-8678-da5c6e475b5b] succeeded in 0.08666778400015573s: None [2021-01-06 19:51:38,967: INFO/ForkPoolWorker-1] Task tasks.create_image[9ef4fc14-78f5-433f-9bc5-3c858a327aa5] succeeded in 0.07816681099984635s: None [2021-01-06 19:51:42,865: INFO/MainProcess] Received task: tasks.run_container[23a14cb2-d962-4ad7-80b8-16c5583e0099]
[2021-01-06 19:51:44,755: WARNING/ForkPoolWorker-1] 启动漏洞容器成功,任务ID:50ea7274-5850-4fc2-8847-20de15e9f953 [2021-01-06 19:51:44,783: INFO/MainProcess] Received task: tasks.stop_container[5443bcfa-27e1-4560-83c0-1e7281e818fa] ETA:[2021-01-06 12:21:44.760077+00:00] [2021-01-06 19:51:44,785: INFO/ForkPoolWorker-1] Task tasks.run_container[23a14cb2-d962-4ad7-80b8-16c5583e0099] succeeded in 1.9188701049999963s: 'dc4c0d65-808a-4de5-8033-7e0c0c0b769a' [2021-01-06 19:51:49,554: INFO/MainProcess] Received task: tasks.run_container[9ae7dc2f-c713-4263-be1f-f4090359f271]
[2021-01-06 19:51:49,896: ERROR/ForkPoolWorker-1] Task tasks.run_container[9ae7dc2f-c713-4263-be1f-f4090359f271] raised unexpected: APIError(HTTPError('500 Server Error: Internal Server Error for url: http+docker://localhost/v1.35/containers/f7555632a276f37ce9856745a2b22423646ef0cfd962360421449d567c632abc/start')) Traceback (most recent call last): File "/usr/local/lib/python3.9/site-packages/docker/api/client.py", line 261, in _raise_for_status response.raise_for_status() File "/usr/local/lib/python3.9/site-packages/requests/models.py", line 943, in raise_for_status raise HTTPError(http_error_msg, response=self) requests.exceptions.HTTPError: 500 Server Error: Internal Server Error for url: http+docker://localhost/v1.35/containers/f7555632a276f37ce9856745a2b22423646ef0cfd962360421449d567c632abc/start

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "/usr/local/lib/python3.9/site-packages/celery/app/trace.py", line 385, in trace_task R = retval = fun(*args, kwargs) File "/usr/local/lib/python3.9/site-packages/celery/app/trace.py", line 650, in __protected_call__ return self.run(args, kwargs) File "/vulfocus-api/tasks/tasks.py", line 308, in run_container docker_container = client.containers.run(image_name, ports=port_dict, detach=True) File "/usr/local/lib/python3.9/site-packages/docker/models/containers.py", line 791, in run container.start() File "/usr/local/lib/python3.9/site-packages/docker/models/containers.py", line 392, in start return self.client.api.start(self.id, kwargs) File "/usr/local/lib/python3.9/site-packages/docker/utils/decorators.py", line 19, in wrapped return f(self, resource_id, args, kwargs) File "/usr/local/lib/python3.9/site-packages/docker/api/container.py", line 1091, in start self._raise_for_status(res) File "/usr/local/lib/python3.9/site-packages/docker/api/client.py", line 263, in _raise_for_status raise create_api_error_from_http_exception(e) File "/usr/local/lib/python3.9/site-packages/docker/errors.py", line 31, in create_api_error_from_http_exception raise cls(e, response=response, explanation=explanation) docker.errors.APIError: 500 Server Error: Internal Server Error ("driver failed programming external connectivity on endpoint crazy_northcutt (87a8f419dcf1e633dae79fefa595107e6a870e0214ac65223dbe4ee75f25ad35): invalid transport protocol: 0")

xxxxbxxxxx commented 3 years ago

其他的镜像也会出现这个问题吗?

refengs commented 3 years ago

非vulfocus的镜像就会,vulfocus的就没事,可以正常启动

xxxxbxxxxx commented 3 years ago

可以联系微信号:psponge 将镜像提交给他

refengs commented 3 years ago

不用吧,就https://github.com/vulhub/vulhub的环境……我云服务器的不能启动……我虚拟机的就没问题……

xxxxbxxxxx commented 3 years ago

因为vulhub启动镜像环境大部分都是通过 docker-compose 来启动的,目前容器的启动方式比较依赖镜像所以在启动时可能有些问题,不过后续可以通过系统中的场景模式来处理。

Yxuan18 commented 3 years ago

期待场景模式的使用教程

xxxxbxxxxx commented 3 years ago

期待场景模式的使用教程

可以参考一下:

https://nosec.org/home/detail/4628.html

Liiuliu commented 3 years ago

已经兼容