· 4 years ago · Jun 17, 2021, 07:04 PM
1INFO:root:Starting automation BYOK function.
2INFO:root: - Create a coneccion.
3INFO:root:Checking if connection exists for account id.
4refresh token auth...
5DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): dev.cm.pwcglb.com:443
6/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py:1013: InsecureRequestWarning: Unverified HTTPS request is being made to host 'dev.cm.pwcglb.com'. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings
7 warnings.warn(
8DEBUG:urllib3.connectionpool:https://dev.cm.pwcglb.com:443 "POST /api/v1/auth/tokens HTTP/1.1" 200 681
9acc_id 533689996463
10INFO:root:Attempting to connect to thales connectionmgmt...
11DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): dev.cm.pwcglb.com:443
12/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py:1013: InsecureRequestWarning: Unverified HTTPS request is being made to host 'dev.cm.pwcglb.com'. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings
13 warnings.warn(
14DEBUG:urllib3.connectionpool:https://dev.cm.pwcglb.com:443 "GET /api/v1/connectionmgmt/services/aws/connections?name=AWS-dev-533689996463 HTTP/1.1" 200 47
15INFO:root:Request made to Thales to check connection name existence:
16DEBUG:root:<Response [200]>
17INFO:root:No AWS connection found on Thales, creating connection
18INFO:root:Attempting to connect to thales connectionmgmt...
19{'name': 'AWS-dev-533689996463', 'products': ['cckm'], 'meta': {'color': 'blue'}, 'access_key_id': 'AKIAXYQTHCSXTK7U6CJ6', 'secret_access_key': '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', 'cloud_name': 'aws'}
20DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): dev.cm.pwcglb.com:443
21/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py:1013: InsecureRequestWarning: Unverified HTTPS request is being made to host 'dev.cm.pwcglb.com'. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings
22 warnings.warn(
23DEBUG:urllib3.connectionpool:https://dev.cm.pwcglb.com:443 "POST /api/v1/connectionmgmt/services/aws/connections HTTP/1.1" 201 514
24INFO:root:Request made to Thales to create connection
25DEBUG:root:<Response [201]>
26INFO:root:Connection created by connection module
27DEBUG:root:{'id': '3493b215-35b6-4fa1-98a7-f37329dd0eab', 'uri': 'kylo:kylo:connectionmgmt:connections:aws-dev-533689996463-3493b215-35b6-4fa1-98a7-f37329dd0eab', 'account': 'kylo:kylo:admin:accounts:kylo', 'createdAt': '2021-06-17T18:47:03.7840335Z', 'updatedAt': '2021-06-17T18:47:03.7817137Z', 'service': 'aws', 'category': 'cloud', 'last_connection_ok': None, 'last_connection_at': '0001-01-01T00:00:00Z', 'name': 'AWS-dev-533689996463', 'products': ['cckm'], 'meta': {'color': 'blue'}, 'access_key_id': 'AKIAXYQTHCSXTK7U6CJ6', 'cloud_name': 'aws', 'account_id': '533689996463'}
28INFO:root: - Create kms key.
29INFO:root:Checking if KMS container exists for account id.
30refresh token auth...
31DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): dev.cm.pwcglb.com:443
32/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py:1013: InsecureRequestWarning: Unverified HTTPS request is being made to host 'dev.cm.pwcglb.com'. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings
33 warnings.warn(
34DEBUG:urllib3.connectionpool:https://dev.cm.pwcglb.com:443 "POST /api/v1/auth/tokens HTTP/1.1" 200 681
35REQ ON ADD KMS {'id': '3493b215-35b6-4fa1-98a7-f37329dd0eab', 'uri': 'kylo:kylo:connectionmgmt:connections:aws-dev-533689996463-3493b215-35b6-4fa1-98a7-f37329dd0eab', 'account': 'kylo:kylo:admin:accounts:kylo', 'createdAt': '2021-06-17T18:47:03.7840335Z', 'updatedAt': '2021-06-17T18:47:03.7817137Z', 'service': 'aws', 'category': 'cloud', 'last_connection_ok': None, 'last_connection_at': '0001-01-01T00:00:00Z', 'name': 'AWS-dev-533689996463', 'products': ['cckm'], 'meta': {'color': 'blue'}, 'access_key_id': 'AKIAXYQTHCSXTK7U6CJ6', 'cloud_name': 'aws', 'account_id': '533689996463'}
36INFO:root:Attempting to connect to thales cckm...
37DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): dev.cm.pwcglb.com:443
38/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py:1013: InsecureRequestWarning: Unverified HTTPS request is being made to host 'dev.cm.pwcglb.com'. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings
39 warnings.warn(
40DEBUG:urllib3.connectionpool:https://dev.cm.pwcglb.com:443 "GET /api/v1/cckm/aws/kms?account_id=533689996463 HTTP/1.1" 200 860
41INFO:root:Request made to Thales to check container associated with account_id
42DEBUG:root:<Response [200]>
43INFO:root:Container found associated with account_id
44INFO:root: - Create kms without CTM.
45INFO:root:Calling to generate key without CTM.
46refresh token auth...
47DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): dev.cm.pwcglb.com:443
48/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py:1013: InsecureRequestWarning: Unverified HTTPS request is being made to host 'dev.cm.pwcglb.com'. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings
49 warnings.warn(
50DEBUG:urllib3.connectionpool:https://dev.cm.pwcglb.com:443 "POST /api/v1/auth/tokens HTTP/1.1" 200 681
51INFO:root:Call Step 4 Service
52refresh token auth...
53DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): dev.cm.pwcglb.com:443
54/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py:1013: InsecureRequestWarning: Unverified HTTPS request is being made to host 'dev.cm.pwcglb.com'. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings
55 warnings.warn(
56DEBUG:urllib3.connectionpool:https://dev.cm.pwcglb.com:443 "POST /api/v1/auth/tokens HTTP/1.1" 200 681
57DEBUG:root:Call external api url /vault/keys2 - Request name='pwc-explorer' usageMask=12 algorithm='aes' aliases=[{'alias': 'pwc-explorer', 'type': 'string'}] size=256
58DEBUG:root:Transform data {'name': 'pwc-explorer', 'usageMask': 12, 'algorithm': 'aes', 'aliases': [{'alias': 'pwc-explorer', 'type': 'string'}], 'size': 256}
59DEBUG:root:Call Method:POST - URL:https://dev.cm.pwcglb.com/api/v1/vault/keys2 - JSON: {'name': 'pwc-explorer', 'usageMask': 12, 'algorithm': 'aes', 'aliases': [{'alias': 'pwc-explorer', 'type': 'string'}], 'size': 256} - verify: False
60DEBUG:urllib3.connectionpool:Starting new HTTPS connection (1): dev.cm.pwcglb.com:443
61/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py:1013: InsecureRequestWarning: Unverified HTTPS request is being made to host 'dev.cm.pwcglb.com'. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings
62 warnings.warn(
63DEBUG:urllib3.connectionpool:https://dev.cm.pwcglb.com:443 "POST /api/v1/vault/keys2 HTTP/1.1" 201 1019
64DEBUG:root:success to calling external api - response.status_code 201 - response <Response [201]>
65DEBUG:root:Fail to calling external api - Status code: 201 - Response: <Response [201]>
66INFO:root:End Call Step 4 Service - Payload: [<app.model.ErrorService object at 0x7f99e72f1940>]
67INFO:root: - CALL step 5.
68automation {'id': '8efe0181-7871-435f-a0f7-dbf6600467ee', 'uri': 'kylo:kylo:cckm:kms:pwc-explorer', 'account': 'kylo:kylo:admin:accounts:kylo', 'application': 'ncryptify:gemalto:admin:apps:kylo', 'devAccount': 'ncryptify:gemalto:admin:accounts:gemalto', 'createdAt': '2021-06-01T16:20:57.771994Z', 'name': 'pwc-explorer', 'updatedAt': '2021-06-14T19:05:28.485226Z', 'account_id': '533689996463', 'arn': 'arn:aws:sts::533689996463:assumed-role/thales-kms-specific/cckm-3e068121-760f-45e6-b323-369e5d89283f', 'connection': 'PwC AWS POC', 'regions': ['ap-northeast-1', 'ap-northeast-2', 'ap-northeast-3', 'ap-south-1', 'ap-southeast-1', 'ap-southeast-2', 'ca-central-1', 'eu-central-1', 'eu-north-1', 'eu-west-1', 'eu-west-2', 'eu-west-3', 'sa-east-1', 'us-east-1', 'us-east-2', 'us-west-1', 'us-west-2'], 'cloud_name': 'aws', 'synced_at': '2021-06-14T19:05:28.485055Z'}
69INFO: 172.17.0.1:59074 - "POST /v1/aws/kms/ HTTP/1.1" 201 Created