@owlnext/heimdall-js
Advanced tools
Comparing version 1.0.18 to 1.0.19
@@ -75,2 +75,3 @@ "use strict"; | ||
return new Promise((resolve, reject) => __awaiter(this, void 0, void 0, function* () { | ||
this._http_client.setServerEnvironment(payload.server_environment); | ||
this._jwt_token = payload.token; | ||
@@ -77,0 +78,0 @@ this._jwt_refresh_token = null; |
@@ -63,2 +63,4 @@ "use strict"; | ||
return this.generateSecurityHeader().then(secHeader => { | ||
console.log("--- complete security header ---"); | ||
console.log(secHeader); | ||
payload.headers = { | ||
@@ -74,2 +76,4 @@ 'Content-Type': 'application/json', | ||
} | ||
console.log("--- request payload ---"); | ||
console.log(payload); | ||
return axios_1.default.request(payload) | ||
@@ -91,2 +95,4 @@ .then(res => { | ||
return this._fingerprintUtils.getFingerprint().then(fingerprint => { | ||
console.log("--- request fingerprint ---"); | ||
console.log(fingerprint); | ||
this._fingerprint = fingerprint; | ||
@@ -97,2 +103,4 @@ return Promise.resolve(this.makeHeimdallHeader(fingerprint)); | ||
this.makeHeimdallHeader = (fingerprint) => { | ||
console.log("--- heimdall header fingerprint ---"); | ||
console.log(fingerprint); | ||
const nonce = (0, uuid_1.v4)(); | ||
@@ -99,0 +107,0 @@ const cipher = (0, js_sha512_1.sha512)(fingerprint + '' + nonce); |
@@ -64,2 +64,4 @@ "use strict"; | ||
return this.api.authenticate_by_token(props).then((result) => { | ||
console.log("--- auth result ---"); | ||
console.log(result); | ||
resolve(result); | ||
@@ -216,3 +218,6 @@ }); | ||
return __awaiter(this, void 0, void 0, function* () { | ||
return yield this.api.httpClient.fingerprintUtils.getFingerprint(); | ||
let fingerprint = yield this.api.httpClient.fingerprintUtils.getFingerprint(); | ||
console.log("--- generated fingerprint ---"); | ||
console.log(fingerprint); | ||
return Promise.resolve(fingerprint); | ||
}); | ||
@@ -219,0 +224,0 @@ } |
{ | ||
"name": "@owlnext/heimdall-js", | ||
"version": "1.0.18", | ||
"version": "1.0.19", | ||
"description": "Heimdall API client & utils for javascript technologies", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
90404
1224