@itentialopensource/adapter-gcp_compute 1.3.1 → 1.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,4 +1,12 @@
1
1
 
2
+ ## 1.3.2 [06-22-2023]
3
+
4
+ * Remove any sensitive data logging
5
+
6
+ See merge request itentialopensource/adapters/cloud/adapter-gcp_compute!8
7
+
8
+ ---
9
+
2
10
  ## 1.3.1 [05-09-2023]
3
11
 
4
12
  * updated adapterBase.js with broker integration bug fixes
package/adapter.js CHANGED
@@ -923,14 +923,11 @@ class GcpCompute extends AdapterBaseCl {
923
923
  log.trace(origin);
924
924
  try {
925
925
  // const keyFile = this.getNested(this, 'allProps', 'authentication', 'configureGtoken', 'keyFile') || process.env.GOOGLE_APPLICATION_CREDENTIALS;
926
- // log.debug(`readPropsKeyFile keyFile is ${keyFile}`)
927
926
  if (!keyFile) {
928
927
  throw new Error('No keyFile specified in Service Config or GOOGLE_APPLICATION_CREDENTIALS');
929
928
  } else {
930
929
  const content = readFileSync(keyFile, 'utf8');
931
- // log.debug(`readPropsKeyFile content length is ${content.length}`);
932
930
  const keyObj = JSON.parse(content);
933
- // log.debug(`readPropsKeyFile keyObj is ${JSON.stringify(keyObj)}`);
934
931
  return keyObj;
935
932
  }
936
933
  } catch (ex) {
@@ -955,7 +952,6 @@ class GcpCompute extends AdapterBaseCl {
955
952
  delete configureGtoken.keyFile;
956
953
  }
957
954
  if (configureGtoken.key || configureGtoken.keyFile) {
958
- // log.debug(`${meth} configureGtoken is ${JSON.stringify(configureGtoken)}`);
959
955
  if (this.allProps.stub) {
960
956
  this.gtoken = this;
961
957
  } else {
@@ -1004,7 +1000,6 @@ class GcpCompute extends AdapterBaseCl {
1004
1000
  refreshAuthorizationHeader(token) {
1005
1001
  const ret = `${token.token_type} ${token.access_token}`;
1006
1002
  this.allProps.request.global_request.addlHeaders.Authorization = ret;
1007
- // log.debug(`refreshAuthorizationHeader ${JSON.stringify(this.allProps.request.global_request.addlHeaders)}`); // this will LEAK the token!
1008
1003
  return ret;
1009
1004
  }
1010
1005
 
@@ -1167,7 +1162,7 @@ class GcpCompute extends AdapterBaseCl {
1167
1162
  // Make the call -
1168
1163
  // identifyRequest(entity, action, requestObj, returnDataFlag, callback)
1169
1164
  return this.refreshAuthorizationAndIdentifyRequest('Projects', 'getProject', reqObj, true, (irReturnData, irReturnError) => {
1170
- // if we received an error or their is no response on the results
1165
+ // if we received an error or there is no response on the results
1171
1166
  // return an error
1172
1167
  if (irReturnError) {
1173
1168
  /* HERE IS WHERE YOU CAN ALTER THE ERROR MESSAGE */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@itentialopensource/adapter-gcp_compute",
3
- "version": "1.3.1",
3
+ "version": "1.3.2",
4
4
  "description": "This adapter integrates with system described as: computeEngineApi.",
5
5
  "main": "adapter.js",
6
6
  "systemName": "Google Cloud Compute",
Binary file