unpeek 2.0.0 → 4.0.0
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/README.md +57 -21
- package/README.tr.md +65 -29
- package/dist/adapters/esbuild.cjs +13 -0
- package/dist/adapters/esbuild.d.cts +13 -0
- package/dist/adapters/esbuild.d.ts +11 -0
- package/dist/adapters/esbuild.js +13 -0
- package/dist/adapters/next/adapter.cjs +43 -0
- package/dist/{next → adapters/next}/adapter.d.cts +4 -4
- package/dist/{next → adapters/next}/adapter.d.ts +4 -4
- package/dist/adapters/next/adapter.js +43 -0
- package/dist/adapters/next/index.cjs +16 -0
- package/dist/adapters/next/index.d.cts +53 -0
- package/dist/adapters/next/index.d.ts +53 -0
- package/dist/adapters/next/index.js +16 -0
- package/dist/adapters/rollup.cjs +13 -0
- package/dist/adapters/rollup.d.cts +13 -0
- package/dist/adapters/rollup.d.ts +11 -0
- package/dist/adapters/rollup.js +13 -0
- package/dist/adapters/rspack.cjs +13 -0
- package/dist/adapters/rspack.d.cts +13 -0
- package/dist/adapters/rspack.d.ts +11 -0
- package/dist/adapters/rspack.js +13 -0
- package/dist/adapters/vite.cjs +13 -0
- package/dist/adapters/vite.d.cts +13 -0
- package/dist/adapters/vite.d.ts +11 -0
- package/dist/adapters/vite.js +13 -0
- package/dist/adapters/webpack.cjs +13 -0
- package/dist/adapters/webpack.d.cts +13 -0
- package/dist/adapters/webpack.d.ts +11 -0
- package/dist/adapters/webpack.js +13 -0
- package/dist/browser.cjs +8 -5
- package/dist/browser.d.cts +44 -3
- package/dist/browser.d.ts +44 -3
- package/dist/browser.js +10 -7
- package/dist/{chunk-5QD6FZPB.js → chunk-2JU3V7HW.js} +75 -43
- package/dist/chunk-3LWXEJU6.cjs +1054 -0
- package/dist/chunk-4FNZNIBW.js +7391 -0
- package/dist/chunk-7HXLHLLQ.cjs +503 -0
- package/dist/chunk-ADKRENAP.js +1054 -0
- package/dist/chunk-EN6QVR6P.js +89 -0
- package/dist/chunk-HHC7BUCK.js +503 -0
- package/dist/chunk-KLYFNMKS.cjs +7391 -0
- package/dist/chunk-L6BOM5VS.cjs +40 -0
- package/dist/{chunk-OOXSZTRV.js → chunk-LA6J3BT3.js} +26 -1
- package/dist/chunk-URPPSTHZ.cjs +89 -0
- package/dist/chunk-VG4Y26ZN.cjs +429 -0
- package/dist/{chunk-GZB7PFLY.js → chunk-W77DAC3H.js} +46 -64
- package/dist/chunk-X6EETCO6.cjs +352 -0
- package/dist/chunk-YCRMTXOE.js +429 -0
- package/dist/{chunk-GAVI2C44.cjs → chunk-ZG7BIAUI.cjs} +80 -48
- package/dist/cli/index.js +9861 -32
- package/dist/{types-BBSRUEab.d.cts → config-Y6JwVGwX.d.cts} +58 -86
- package/dist/{types-BBSRUEab.d.ts → config-Y6JwVGwX.d.ts} +58 -86
- package/dist/config.cjs +4 -16
- package/dist/config.d.cts +1 -12
- package/dist/config.d.ts +1 -12
- package/dist/config.js +5 -17
- package/dist/index-0O1WSfVP.d.ts +52 -0
- package/dist/index-COVHErnx.d.cts +52 -0
- package/dist/index.cjs +437 -9
- package/dist/index.d.cts +9 -17
- package/dist/index.d.ts +9 -17
- package/dist/index.js +438 -10
- package/dist/plugins/unplugin.cjs +21 -0
- package/dist/plugins/unplugin.d.cts +17 -0
- package/dist/plugins/unplugin.d.ts +15 -0
- package/dist/{bundler → plugins}/unplugin.js +6 -5
- package/dist/types-CMtZnV8C.d.ts +112 -0
- package/dist/types-D93PuOOl.d.cts +112 -0
- package/package.json +48 -52
- package/dist/ast/index.cjs +0 -17
- package/dist/ast/index.d.cts +0 -18
- package/dist/ast/index.d.ts +0 -18
- package/dist/ast/index.js +0 -17
- package/dist/bundler/unplugin.cjs +0 -20
- package/dist/bundler/unplugin.d.cts +0 -16
- package/dist/bundler/unplugin.d.ts +0 -14
- package/dist/chunk-24K5NDXH.cjs +0 -370
- package/dist/chunk-27HR647Q.js +0 -190
- package/dist/chunk-4TDLLEEU.cjs +0 -15
- package/dist/chunk-5LCMI2TL.js +0 -575
- package/dist/chunk-5M6Z7ZFT.cjs +0 -83
- package/dist/chunk-6N6S6WTQ.cjs +0 -423
- package/dist/chunk-7YVEHJVM.cjs +0 -575
- package/dist/chunk-J5CGNZDM.cjs +0 -190
- package/dist/chunk-KQWNFKT2.js +0 -423
- package/dist/chunk-LXP73HJC.cjs +0 -4532
- package/dist/chunk-R6EBIR3T.cjs +0 -14
- package/dist/chunk-S4S2WXGC.js +0 -14
- package/dist/chunk-UMPUYLLZ.js +0 -4532
- package/dist/chunk-X5MKMFMX.js +0 -83
- package/dist/cli/index.cjs +0 -324
- package/dist/cli/index.d.cts +0 -22
- package/dist/cli/index.d.ts +0 -22
- package/dist/esbuild.cjs +0 -15
- package/dist/esbuild.d.cts +0 -11
- package/dist/esbuild.d.ts +0 -11
- package/dist/esbuild.js +0 -13
- package/dist/next/adapter.cjs +0 -31
- package/dist/next/adapter.js +0 -31
- package/dist/next/index.cjs +0 -18
- package/dist/next/index.d.cts +0 -42
- package/dist/next/index.d.ts +0 -42
- package/dist/next/index.js +0 -18
- package/dist/rollup.cjs +0 -15
- package/dist/rollup.d.cts +0 -11
- package/dist/rollup.d.ts +0 -11
- package/dist/rollup.js +0 -13
- package/dist/runtime/index.cjs +0 -17
- package/dist/runtime/index.d.cts +0 -36
- package/dist/runtime/index.d.ts +0 -36
- package/dist/runtime/index.js +0 -17
- package/dist/vite.cjs +0 -15
- package/dist/vite.d.cts +0 -11
- package/dist/vite.d.ts +0 -11
- package/dist/vite.js +0 -13
- package/dist/webpack.cjs +0 -15
- package/dist/webpack.d.cts +0 -11
- package/dist/webpack.d.ts +0 -11
- package/dist/webpack.js +0 -13
package/dist/next/index.js
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
createUnpeekNextAdapter,
|
|
3
|
-
getUnpeekAdapterPath,
|
|
4
|
-
readUnpeekNextOptionsFromEnv,
|
|
5
|
-
withUnpeek
|
|
6
|
-
} from "../chunk-5QD6FZPB.js";
|
|
7
|
-
import "../chunk-5LCMI2TL.js";
|
|
8
|
-
import "../chunk-GZB7PFLY.js";
|
|
9
|
-
import "../chunk-UMPUYLLZ.js";
|
|
10
|
-
import "../chunk-KQWNFKT2.js";
|
|
11
|
-
import "../chunk-S4S2WXGC.js";
|
|
12
|
-
import "../chunk-OOXSZTRV.js";
|
|
13
|
-
export {
|
|
14
|
-
createUnpeekNextAdapter,
|
|
15
|
-
getUnpeekAdapterPath,
|
|
16
|
-
readUnpeekNextOptionsFromEnv,
|
|
17
|
-
withUnpeek
|
|
18
|
-
};
|
package/dist/rollup.cjs
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
|
-
|
|
3
|
-
var _chunk5M6Z7ZFTcjs = require('./chunk-5M6Z7ZFT.cjs');
|
|
4
|
-
require('./chunk-LXP73HJC.cjs');
|
|
5
|
-
require('./chunk-6N6S6WTQ.cjs');
|
|
6
|
-
require('./chunk-R6EBIR3T.cjs');
|
|
7
|
-
require('./chunk-4TDLLEEU.cjs');
|
|
8
|
-
|
|
9
|
-
// src/rollup.ts
|
|
10
|
-
var rollup_default = _chunk5M6Z7ZFTcjs.rollupPlugin;
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
exports.default = rollup_default;
|
|
14
|
-
|
|
15
|
-
module.exports = exports.default;
|
package/dist/rollup.d.cts
DELETED
package/dist/rollup.d.ts
DELETED
package/dist/rollup.js
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
rollupPlugin
|
|
3
|
-
} from "./chunk-X5MKMFMX.js";
|
|
4
|
-
import "./chunk-UMPUYLLZ.js";
|
|
5
|
-
import "./chunk-KQWNFKT2.js";
|
|
6
|
-
import "./chunk-S4S2WXGC.js";
|
|
7
|
-
import "./chunk-OOXSZTRV.js";
|
|
8
|
-
|
|
9
|
-
// src/rollup.ts
|
|
10
|
-
var rollup_default = rollupPlugin;
|
|
11
|
-
export {
|
|
12
|
-
rollup_default as default
|
|
13
|
-
};
|
package/dist/runtime/index.cjs
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
var _chunk6N6S6WTQcjs = require('../chunk-6N6S6WTQ.cjs');
|
|
9
|
-
require('../chunk-4TDLLEEU.cjs');
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
exports.computeIntegrityHash = _chunk6N6S6WTQcjs.computeIntegrityHash; exports.createDeterrentSnippet = _chunk6N6S6WTQcjs.createDeterrentSnippet; exports.deriveIntegrityFnName = _chunk6N6S6WTQcjs.deriveIntegrityFnName; exports.deriveWindowKeySymbol = _chunk6N6S6WTQcjs.deriveWindowKeySymbol; exports.generateRuntimeShield = _chunk6N6S6WTQcjs.generateRuntimeShield; exports.verifyCodeIntegrity = _chunk6N6S6WTQcjs.verifyCodeIntegrity;
|
package/dist/runtime/index.d.cts
DELETED
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
import { ShieldConfig, ShieldPayload } from '../browser.cjs';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Computes a 32-bit unsigned FNV-1a hash over the un-normalized source string.
|
|
5
|
-
* Any formatting change (such as DevTools Pretty-Print adding newlines or spaces)
|
|
6
|
-
* or monkeypatching alters the resulting hash.
|
|
7
|
-
*/
|
|
8
|
-
declare function computeIntegrityHash(source: string, seed?: number): number;
|
|
9
|
-
/**
|
|
10
|
-
* Verifies that a function or source string has not been pretty-printed or modified
|
|
11
|
-
* by comparing its un-normalized Function.prototype.toString() FNV-1a hash.
|
|
12
|
-
*/
|
|
13
|
-
declare function verifyCodeIntegrity(fnOrSource: ((...args: unknown[]) => unknown) | string, expectedHash: number, seed?: number): boolean;
|
|
14
|
-
|
|
15
|
-
declare function deriveIntegrityFnName(seed: number): string;
|
|
16
|
-
declare function deriveWindowKeySymbol(seed: number): string;
|
|
17
|
-
/**
|
|
18
|
-
* Generates a single-line, self-executing (IIFE), polymorphic, synchronous, SSR-safe (<1.5 KB)
|
|
19
|
-
* anti-tamper deterrent snippet that calculates a synchronous 32-bit FNV-1a hash of its own
|
|
20
|
-
* Function.prototype.toString() representation and writes the 16-bit key component (expectedDelta)
|
|
21
|
-
* to window[windowKeySymbol].
|
|
22
|
-
*
|
|
23
|
-
* Freedom To Operate (FTO) Compliance:
|
|
24
|
-
* Strictly avoids timer / setInterval active debugging checks, timing differential loops,
|
|
25
|
-
* and periodic debugger polling covered by third-party patents (e.g. Jscrambler US9979726B2).
|
|
26
|
-
* Operates purely via synchronous cryptographic state coupling via FNV-1a hash and tamper flags.
|
|
27
|
-
*
|
|
28
|
-
* When tampering is detected (formatting, pretty-print, webdriver, toString spoofing):
|
|
29
|
-
* window.__unpeek_tampered is set to true, String.prototype._u is poisoned to 14,
|
|
30
|
-
* window[sym] is poisoned to expectedDelta ^ 0x5a5b, and CustomEvent('unpeek:tamper') is dispatched.
|
|
31
|
-
*/
|
|
32
|
-
declare function createDeterrentSnippet(config: ShieldConfig): string;
|
|
33
|
-
|
|
34
|
-
declare function generateRuntimeShield(config: ShieldConfig): ShieldPayload;
|
|
35
|
-
|
|
36
|
-
export { computeIntegrityHash, createDeterrentSnippet, deriveIntegrityFnName, deriveWindowKeySymbol, generateRuntimeShield, verifyCodeIntegrity };
|
package/dist/runtime/index.d.ts
DELETED
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
import { ShieldConfig, ShieldPayload } from '../browser.js';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Computes a 32-bit unsigned FNV-1a hash over the un-normalized source string.
|
|
5
|
-
* Any formatting change (such as DevTools Pretty-Print adding newlines or spaces)
|
|
6
|
-
* or monkeypatching alters the resulting hash.
|
|
7
|
-
*/
|
|
8
|
-
declare function computeIntegrityHash(source: string, seed?: number): number;
|
|
9
|
-
/**
|
|
10
|
-
* Verifies that a function or source string has not been pretty-printed or modified
|
|
11
|
-
* by comparing its un-normalized Function.prototype.toString() FNV-1a hash.
|
|
12
|
-
*/
|
|
13
|
-
declare function verifyCodeIntegrity(fnOrSource: ((...args: unknown[]) => unknown) | string, expectedHash: number, seed?: number): boolean;
|
|
14
|
-
|
|
15
|
-
declare function deriveIntegrityFnName(seed: number): string;
|
|
16
|
-
declare function deriveWindowKeySymbol(seed: number): string;
|
|
17
|
-
/**
|
|
18
|
-
* Generates a single-line, self-executing (IIFE), polymorphic, synchronous, SSR-safe (<1.5 KB)
|
|
19
|
-
* anti-tamper deterrent snippet that calculates a synchronous 32-bit FNV-1a hash of its own
|
|
20
|
-
* Function.prototype.toString() representation and writes the 16-bit key component (expectedDelta)
|
|
21
|
-
* to window[windowKeySymbol].
|
|
22
|
-
*
|
|
23
|
-
* Freedom To Operate (FTO) Compliance:
|
|
24
|
-
* Strictly avoids timer / setInterval active debugging checks, timing differential loops,
|
|
25
|
-
* and periodic debugger polling covered by third-party patents (e.g. Jscrambler US9979726B2).
|
|
26
|
-
* Operates purely via synchronous cryptographic state coupling via FNV-1a hash and tamper flags.
|
|
27
|
-
*
|
|
28
|
-
* When tampering is detected (formatting, pretty-print, webdriver, toString spoofing):
|
|
29
|
-
* window.__unpeek_tampered is set to true, String.prototype._u is poisoned to 14,
|
|
30
|
-
* window[sym] is poisoned to expectedDelta ^ 0x5a5b, and CustomEvent('unpeek:tamper') is dispatched.
|
|
31
|
-
*/
|
|
32
|
-
declare function createDeterrentSnippet(config: ShieldConfig): string;
|
|
33
|
-
|
|
34
|
-
declare function generateRuntimeShield(config: ShieldConfig): ShieldPayload;
|
|
35
|
-
|
|
36
|
-
export { computeIntegrityHash, createDeterrentSnippet, deriveIntegrityFnName, deriveWindowKeySymbol, generateRuntimeShield, verifyCodeIntegrity };
|
package/dist/runtime/index.js
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
computeIntegrityHash,
|
|
3
|
-
createDeterrentSnippet,
|
|
4
|
-
deriveIntegrityFnName,
|
|
5
|
-
deriveWindowKeySymbol,
|
|
6
|
-
generateRuntimeShield,
|
|
7
|
-
verifyCodeIntegrity
|
|
8
|
-
} from "../chunk-KQWNFKT2.js";
|
|
9
|
-
import "../chunk-OOXSZTRV.js";
|
|
10
|
-
export {
|
|
11
|
-
computeIntegrityHash,
|
|
12
|
-
createDeterrentSnippet,
|
|
13
|
-
deriveIntegrityFnName,
|
|
14
|
-
deriveWindowKeySymbol,
|
|
15
|
-
generateRuntimeShield,
|
|
16
|
-
verifyCodeIntegrity
|
|
17
|
-
};
|
package/dist/vite.cjs
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
|
-
|
|
3
|
-
var _chunk5M6Z7ZFTcjs = require('./chunk-5M6Z7ZFT.cjs');
|
|
4
|
-
require('./chunk-LXP73HJC.cjs');
|
|
5
|
-
require('./chunk-6N6S6WTQ.cjs');
|
|
6
|
-
require('./chunk-R6EBIR3T.cjs');
|
|
7
|
-
require('./chunk-4TDLLEEU.cjs');
|
|
8
|
-
|
|
9
|
-
// src/vite.ts
|
|
10
|
-
var vite_default = _chunk5M6Z7ZFTcjs.vitePlugin;
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
exports.default = vite_default;
|
|
14
|
-
|
|
15
|
-
module.exports = exports.default;
|
package/dist/vite.d.cts
DELETED
package/dist/vite.d.ts
DELETED
package/dist/vite.js
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
vitePlugin
|
|
3
|
-
} from "./chunk-X5MKMFMX.js";
|
|
4
|
-
import "./chunk-UMPUYLLZ.js";
|
|
5
|
-
import "./chunk-KQWNFKT2.js";
|
|
6
|
-
import "./chunk-S4S2WXGC.js";
|
|
7
|
-
import "./chunk-OOXSZTRV.js";
|
|
8
|
-
|
|
9
|
-
// src/vite.ts
|
|
10
|
-
var vite_default = vitePlugin;
|
|
11
|
-
export {
|
|
12
|
-
vite_default as default
|
|
13
|
-
};
|
package/dist/webpack.cjs
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
|
-
|
|
3
|
-
var _chunk5M6Z7ZFTcjs = require('./chunk-5M6Z7ZFT.cjs');
|
|
4
|
-
require('./chunk-LXP73HJC.cjs');
|
|
5
|
-
require('./chunk-6N6S6WTQ.cjs');
|
|
6
|
-
require('./chunk-R6EBIR3T.cjs');
|
|
7
|
-
require('./chunk-4TDLLEEU.cjs');
|
|
8
|
-
|
|
9
|
-
// src/webpack.ts
|
|
10
|
-
var webpack_default = _chunk5M6Z7ZFTcjs.webpackPlugin;
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
exports.default = webpack_default;
|
|
14
|
-
|
|
15
|
-
module.exports = exports.default;
|
package/dist/webpack.d.cts
DELETED
package/dist/webpack.d.ts
DELETED
package/dist/webpack.js
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
webpackPlugin
|
|
3
|
-
} from "./chunk-X5MKMFMX.js";
|
|
4
|
-
import "./chunk-UMPUYLLZ.js";
|
|
5
|
-
import "./chunk-KQWNFKT2.js";
|
|
6
|
-
import "./chunk-S4S2WXGC.js";
|
|
7
|
-
import "./chunk-OOXSZTRV.js";
|
|
8
|
-
|
|
9
|
-
// src/webpack.ts
|
|
10
|
-
var webpack_default = webpackPlugin;
|
|
11
|
-
export {
|
|
12
|
-
webpack_default as default
|
|
13
|
-
};
|