Splunk Phantom

Phantom unable to install phantom app digitalshadows and fails with connection to pypi.org timeout?

Splunk Employee
Splunk Employee

I am trying to install Phantom app: install digitalshadows-1.0.1 published in Phantom Marketplace (https://my.phantom.us/media/apps/10-12-2017-23-16-36/digitalshadows-1.0.1.tgz)

Error :
Collecting httplib2 WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ConnectTimeoutError(, 'Connection to pypi.org timed out. (connect timeout=15)')': /simple/httplib2/

fyi : checked and found httplib2 python package is already installed.

Labels (2)
Tags (1)
0 Karma

Splunk Employee
Splunk Employee
  1. You are getting the error message as Digital Shadows app has dependency defined in digital_shadows.json.

cat -n digital_shadows.json | more

1 {
2 "appid": "8cebdfd7-afe9-48eb-b840-2d98f860ed79",
3 "name": "Digital Shadows",
4 "description": "This app integrates with Digital Shadows SearchLight to ingest and investigate credentials found in data breaches",
5 "type": "information",
6 "main_module": "digital_shadows_connector.pyc",
7 "app_version": "1.0.1",
8 "min_phantom_version": "3.0.251",
9 "product_vendor": "Digital Shadows",
10 "product_name": "Digital Shadows SearchLight",
11 "product_version_regex": ".*",
12 "publisher": "Digital Shadows Ltd.",
13 "package_name": "phantom_digital_shadows",
14 "license": "Copyright (c) 2017 Digital Shadows Ltd.",
15 "pip_dependencies": {
16 "pypi": [
17 {"module": "httplib2"}
18 ]
19 },

Problem: Your Phantom server is unable to connect to pypi.org and connection times out while installing the dependent python package.

How to fix?
1. You can manually download and install the package and remove the below dependencies code from digital_shadows.json.

Remove : line numbers starting from 15-19
15 "pip_dependencies": {
16 "pypi": [
17 {"module": "httplib2"}
18 ]
19 },
And then try installing app via phenv python2.7 /opt/phantom/bin/compile_app.pyc -i.

  1. Or fix the connection issues ie see why pypi.org is not accessible.