From f4eed82dddde0cf2360bc37df9c94ee9ce99d10a Mon Sep 17 00:00:00 2001 From: danielailie Date: Thu, 16 Mar 2023 13:35:07 +0200 Subject: [PATCH] Add origin to native auth quard --- package-lock.json | 8 ++++---- package.json | 2 +- src/modules/auth/native.auth-guard.ts | 1 + 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/package-lock.json b/package-lock.json index c2cf4a1b4..1f4eb34ad 100644 --- a/package-lock.json +++ b/package-lock.json @@ -12,7 +12,7 @@ "@elastic/elasticsearch": "7.12.0", "@golevelup/nestjs-rabbitmq": "3.4.0", "@multiversx/sdk-core": "11.2.0", - "@multiversx/sdk-native-auth-server": "1.0.5", + "@multiversx/sdk-native-auth-server": "1.0.6", "@multiversx/sdk-nestjs": "0.4.16", "@multiversx/sdk-network-providers": "^1.2.1", "@nestjs/apollo": "^10.1.7", @@ -3237,9 +3237,9 @@ } }, "node_modules/@multiversx/sdk-native-auth-server": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/@multiversx/sdk-native-auth-server/-/sdk-native-auth-server-1.0.5.tgz", - "integrity": "sha512-zbq7PoUha4P7WsSj7KFLFRoNe567R5Nrz77vHH0gqOCvRVZKg/kp9FKPdnRxopzSySPU/uRGNLzg5gqhTcA3Cw==", + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/@multiversx/sdk-native-auth-server/-/sdk-native-auth-server-1.0.6.tgz", + "integrity": "sha512-iUg7v2ETc7hjWuUDxr+1o3bhtwkZcUg5us0VBsnkYkR9De2rzy/jRFGzINT1+J1wnFImTm1TGFe7Wzu1mqbw/g==", "dependencies": { "@multiversx/sdk-core": "^11.2.0", "@multiversx/sdk-wallet": "^2.1.1", diff --git a/package.json b/package.json index 78510518e..b8c35a502 100644 --- a/package.json +++ b/package.json @@ -30,7 +30,7 @@ "@elastic/elasticsearch": "7.12.0", "@golevelup/nestjs-rabbitmq": "3.4.0", "@multiversx/sdk-core": "11.2.0", - "@multiversx/sdk-native-auth-server": "1.0.5", + "@multiversx/sdk-native-auth-server": "1.0.6", "@multiversx/sdk-nestjs": "0.4.16", "@multiversx/sdk-network-providers": "^1.2.1", "@nestjs/apollo": "^10.1.7", diff --git a/src/modules/auth/native.auth-guard.ts b/src/modules/auth/native.auth-guard.ts index b3b43d6bf..cb58be7f4 100644 --- a/src/modules/auth/native.auth-guard.ts +++ b/src/modules/auth/native.auth-guard.ts @@ -42,6 +42,7 @@ export class NativeAuthGuard implements CanActivate { await this.cachingService.setCache(key, value, ttl); }, }, + extraRequestHeaders: { origin: 'NftService' }, }); }