jwt-license-verifier 0.1.7 → 0.1.9
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/index.es.js +1 -1
- package/dist/index.js +1 -1
- package/dist/index.umd.js +2 -2
- package/dist/types/index.d.ts +3 -3
- package/package.json +83 -80
package/dist/types/index.d.ts
CHANGED
@@ -20,20 +20,20 @@ export declare const getNodeInfo: (app: string) => Promise<string>;
|
|
20
20
|
* @function
|
21
21
|
* @param {string} appOrLibName - The application or library name that token should be verified against.
|
22
22
|
* @param {string} token - The license token to be verified.
|
23
|
-
* @param {string}
|
23
|
+
* @param {string} altPublicKey - The alternative public key.
|
24
24
|
* @returns {Promise<object>} A Promise that resolves to the decoded license information if verification is successful.
|
25
25
|
* @throws {Error} If there is an error during token verification, if the NodeInfo does not match,
|
26
26
|
* or if appOrLibName is null, undefined, or empty or not present in the decoded data.
|
27
27
|
*
|
28
28
|
* @example
|
29
29
|
* try {
|
30
|
-
* const decodedLicense = await verifyLicense('Recaster', 'tokenString'
|
30
|
+
* const decodedLicense = await verifyLicense('Recaster', 'tokenString');
|
31
31
|
* console.log(decodedLicense);
|
32
32
|
* } catch (error) {
|
33
33
|
* console.error(error.message);
|
34
34
|
* }
|
35
35
|
*/
|
36
|
-
export declare function verifyLicense(appOrLibName: string, token: string,
|
36
|
+
export declare function verifyLicense(appOrLibName: string, token: string, altPublicKey?: string): Promise<object>;
|
37
37
|
/**
|
38
38
|
* Decodes a license token without performing verification.
|
39
39
|
*
|
package/package.json
CHANGED
@@ -1,83 +1,86 @@
|
|
1
1
|
{
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
],
|
25
|
-
"scripts": {
|
26
|
-
"build": "rimraf dist && npm run build:types && npm run build:js",
|
27
|
-
"build:js": "rollup -c",
|
28
|
-
"build:types": "tsc --emitDeclarationOnly",
|
29
|
-
"test": "jest",
|
30
|
-
"prepare": "husky install"
|
31
|
-
},
|
32
|
-
"lint-staged": {
|
33
|
-
"*.{js,jsx,ts,tsx}": [
|
34
|
-
"prettier --write",
|
35
|
-
"git add"
|
2
|
+
"name": "jwt-license-verifier",
|
3
|
+
"version": "0.1.9",
|
4
|
+
"description": "Impleo Jwt license verifier",
|
5
|
+
"author": "IMPLEOTV SYSTEMS LTD",
|
6
|
+
"license": "Proprietary",
|
7
|
+
"homepage": "https://www.impleotv.com",
|
8
|
+
"keywords": [
|
9
|
+
"license"
|
10
|
+
],
|
11
|
+
"exports": {
|
12
|
+
".": {
|
13
|
+
"types": "./dist/types",
|
14
|
+
"import": "./dist/index.es.js",
|
15
|
+
"require": "./dist/index.js"
|
16
|
+
}
|
17
|
+
},
|
18
|
+
"main": "./dist/index.js",
|
19
|
+
"module": "./dist/index.es.js",
|
20
|
+
"browser": "./dist/index.umd.js",
|
21
|
+
"types": "./dist/types",
|
22
|
+
"files": [
|
23
|
+
"dist"
|
36
24
|
],
|
37
|
-
"
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
"
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
"
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
"
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
25
|
+
"scripts": {
|
26
|
+
"build": "rimraf dist && npm run build:types && npm run build:js",
|
27
|
+
"build:js": "rollup -c",
|
28
|
+
"build:types": "tsc --emitDeclarationOnly",
|
29
|
+
"test": "jest",
|
30
|
+
"lint": "eslint . --ext js --report-unused-disable-directives --max-warnings 0",
|
31
|
+
"format:check": "prettier --check .",
|
32
|
+
"format:write": "prettier --write ."
|
33
|
+
},
|
34
|
+
"lint-staged": {
|
35
|
+
"*.{js,jsx,ts,tsx}": [
|
36
|
+
"prettier --write",
|
37
|
+
"git add"
|
38
|
+
],
|
39
|
+
"*.{json,md,yml}": [
|
40
|
+
"prettier --write",
|
41
|
+
"git add"
|
42
|
+
]
|
43
|
+
},
|
44
|
+
"repository": {
|
45
|
+
"type": "git",
|
46
|
+
"url": "git+https://github.com/impleotv/jwt-license-verifier.git"
|
47
|
+
},
|
48
|
+
"dependencies": {
|
49
|
+
"@types/systeminformation": "^3.54.1",
|
50
|
+
"jsonwebtoken": "^9.0.2",
|
51
|
+
"systeminformation": "^5.21.20"
|
52
|
+
},
|
53
|
+
"devDependencies": {
|
54
|
+
"@babel/core": "^7.18.2",
|
55
|
+
"@babel/preset-env": "^7.18.2",
|
56
|
+
"@babel/preset-typescript": "^7.17.12",
|
57
|
+
"@commitlint/cli": "^18.4.3",
|
58
|
+
"@commitlint/config-conventional": "^18.4.3",
|
59
|
+
"@rollup/plugin-babel": "5.3.1",
|
60
|
+
"@rollup/plugin-commonjs": "^22.0.0",
|
61
|
+
"@rollup/plugin-json": "^4.1.0",
|
62
|
+
"@rollup/plugin-node-resolve": "^13.3.0",
|
63
|
+
"@rollup/plugin-terser": "^0.4.4",
|
64
|
+
"@semantic-release/changelog": "^6.0.3",
|
65
|
+
"@semantic-release/commit-analyzer": "^11.1.0",
|
66
|
+
"@semantic-release/git": "10.0.1",
|
67
|
+
"@semantic-release/github": "^9.2.5",
|
68
|
+
"@semantic-release/npm": "^11.0.2",
|
69
|
+
"@semantic-release/release-notes-generator": "^12.1.0",
|
70
|
+
"@types/jest": "^29.5.11",
|
71
|
+
"@types/jsonwebtoken": "^9.0.5",
|
72
|
+
"eslint-config-prettier": "^9.1.0",
|
73
|
+
"husky": "^8.0.0",
|
74
|
+
"jest": "^29.7.0",
|
75
|
+
"lint-staged": "^15.2.0",
|
76
|
+
"prettier": "^3.1.1",
|
77
|
+
"rimraf": "^5.0.5",
|
78
|
+
"rollup": "^2.74.1",
|
79
|
+
"semantic-release": "^22.0.12",
|
80
|
+
"ts-jest": "^29.1.1",
|
81
|
+
"typescript": "^4.7.2"
|
82
|
+
},
|
83
|
+
"publishConfig": {
|
84
|
+
"access": "public"
|
85
|
+
}
|
83
86
|
}
|