@abtnode/auth 1.16.27 → 1.16.28-beta-23b06b63

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.
@@ -59,7 +59,7 @@ const getApplicationInfo = async ({ type, node, req, baseUrl = '' }) => {
59
59
  dataDir = path.join(node.dataDirs.data, NODE_DATA_DIR_NAME);
60
60
  issuerLogo = getServerAvatarUrl(baseUrl, info);
61
61
  } else if (TEAM_TYPES.BLOCKLET) {
62
- teamDid = req.headers['x-blocklet-did'];
62
+ teamDid = req.get('x-blocklet-did');
63
63
  const blocklet = await node.getBlocklet({ did: teamDid });
64
64
  const blockletInfo = getBlockletInfo(blocklet, info.sk);
65
65
  issuerDid = blockletInfo.wallet.address;
@@ -326,8 +326,10 @@ const createLostPassportIssueRoute = ({ node, type, authServicePrefix, createTok
326
326
 
327
327
  if (isFunction(createToken)) {
328
328
  if (type === TEAM_TYPES.BLOCKLET) {
329
- const lastLoginIp = request.headers['x-real-ip'];
330
- const ua = request.headers['user-agent'];
329
+ const lastLoginIp = request.get('x-real-ip');
330
+ const walletDeviceMessageToken = request.get('wallet-device-message-token');
331
+ const walletDeviceId = request.get('wallet-device-id');
332
+ const ua = request.get('user-agent');
331
333
  const walletOS = request.context.didwallet.os;
332
334
  const sourceAppPid = getSourceAppPid(request);
333
335
  const provider = getLoginProvider(request);
@@ -370,6 +372,8 @@ const createLostPassportIssueRoute = ({ node, type, authServicePrefix, createTok
370
372
  lastLoginIp,
371
373
  extra: {
372
374
  walletOS,
375
+ walletDeviceMessageToken,
376
+ walletDeviceId,
373
377
  },
374
378
  });
375
379
 
@@ -404,6 +408,8 @@ const createLostPassportIssueRoute = ({ node, type, authServicePrefix, createTok
404
408
  lastLoginIp,
405
409
  extra: {
406
410
  walletOS,
411
+ walletDeviceMessageToken,
412
+ walletDeviceId,
407
413
  },
408
414
  });
409
415
  });
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "publishConfig": {
4
4
  "access": "public"
5
5
  },
6
- "version": "1.16.27",
6
+ "version": "1.16.28-beta-23b06b63",
7
7
  "description": "Simple lib to manage auth in ABT Node",
8
8
  "main": "lib/index.js",
9
9
  "files": [
@@ -20,17 +20,17 @@
20
20
  "author": "linchen <linchen1987@foxmail.com> (http://github.com/linchen1987)",
21
21
  "license": "Apache-2.0",
22
22
  "dependencies": {
23
- "@abtnode/constant": "1.16.27",
24
- "@abtnode/logger": "1.16.27",
25
- "@abtnode/util": "1.16.27",
23
+ "@abtnode/constant": "1.16.28-beta-23b06b63",
24
+ "@abtnode/logger": "1.16.28-beta-23b06b63",
25
+ "@abtnode/util": "1.16.28-beta-23b06b63",
26
26
  "@arcblock/did": "1.18.123",
27
27
  "@arcblock/jwt": "^1.18.123",
28
28
  "@arcblock/nft-display": "^2.9.90",
29
29
  "@arcblock/validator": "^1.18.123",
30
30
  "@arcblock/vc": "1.18.123",
31
- "@blocklet/constant": "1.16.27",
32
- "@blocklet/meta": "1.16.27",
33
- "@blocklet/sdk": "1.16.27",
31
+ "@blocklet/constant": "1.16.28-beta-23b06b63",
32
+ "@blocklet/meta": "1.16.28-beta-23b06b63",
33
+ "@blocklet/sdk": "1.16.28-beta-23b06b63",
34
34
  "@ocap/client": "^1.18.123",
35
35
  "@ocap/mcrypto": "1.18.123",
36
36
  "@ocap/util": "1.18.123",
@@ -51,5 +51,5 @@
51
51
  "devDependencies": {
52
52
  "jest": "^29.7.0"
53
53
  },
54
- "gitHead": "b7dcd46b040c5ad3a273b14b1a411fafc1390828"
54
+ "gitHead": "4e16d8cb992139e25f6702268895917561a1d2f1"
55
55
  }