@prosopo/procaptcha 2.10.57 → 2.10.59
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/.turbo/turbo-build$colon$cjs.log +15 -14
- package/.turbo/turbo-build$colon$tsc.log +20 -20
- package/.turbo/turbo-build.log +17 -14
- package/CHANGELOG.md +48 -0
- package/dist/_virtual/_rolldown/runtime.js +3 -0
- package/dist/cjs/index.cjs +6 -8
- package/dist/cjs/modules/Manager.cjs +288 -384
- package/dist/cjs/modules/ProsopoCaptchaApi.cjs +41 -74
- package/dist/cjs/modules/collector.cjs +43 -73
- package/dist/cjs/modules/index.cjs +6 -8
- package/dist/index.js +3 -7
- package/dist/modules/Manager.d.ts.map +1 -1
- package/dist/modules/Manager.js +285 -382
- package/dist/modules/Manager.js.map +1 -1
- package/dist/modules/ProsopoCaptchaApi.d.ts.map +1 -1
- package/dist/modules/ProsopoCaptchaApi.js +40 -74
- package/dist/modules/ProsopoCaptchaApi.js.map +1 -1
- package/dist/modules/collector.js +44 -74
- package/dist/modules/index.js +2 -6
- package/dist/tests/collector.unit.test.d.ts +2 -0
- package/dist/tests/collector.unit.test.d.ts.map +1 -0
- package/dist/tests/collector.unit.test.js +173 -0
- package/dist/tests/collector.unit.test.js.map +1 -0
- package/dist/tests/manager.unit.test.d.ts +2 -0
- package/dist/tests/manager.unit.test.d.ts.map +1 -0
- package/dist/tests/manager.unit.test.js +788 -0
- package/dist/tests/manager.unit.test.js.map +1 -0
- package/dist/tests/managerHarness.d.ts +18 -0
- package/dist/tests/managerHarness.d.ts.map +1 -0
- package/dist/tests/managerHarness.js +94 -0
- package/dist/tests/managerHarness.js.map +1 -0
- package/dist/tests/procaptcha.test-d.d.ts +2 -0
- package/dist/tests/procaptcha.test-d.d.ts.map +1 -0
- package/dist/tests/procaptcha.test-d.js +78 -0
- package/dist/tests/procaptcha.test-d.js.map +1 -0
- package/dist/tests/prosopoCaptchaApi.unit.test.d.ts +2 -0
- package/dist/tests/prosopoCaptchaApi.unit.test.d.ts.map +1 -0
- package/dist/tests/prosopoCaptchaApi.unit.test.js +155 -0
- package/dist/tests/prosopoCaptchaApi.unit.test.js.map +1 -0
- package/package.json +17 -12
- package/vite.test.config.ts +25 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
> @prosopo/procaptcha@2.10.
|
|
2
|
+
> @prosopo/procaptcha@2.10.59 build:cjs
|
|
3
3
|
> NODE_ENV=${NODE_ENV:-development}; vite build --config vite.cjs.config.ts --mode $NODE_ENV
|
|
4
4
|
|
|
5
5
|
ViteCommonJSConfig: .
|
|
@@ -13,8 +13,8 @@ ViteCommonJSConfig: .
|
|
|
13
13
|
'/home/runner/work/captcha/captcha/packages/types/tsconfig.json',
|
|
14
14
|
'/home/runner/work/captcha/captcha/packages/util-crypto/tsconfig.json',
|
|
15
15
|
'/home/runner/work/captcha/captcha/packages/api/tsconfig.json',
|
|
16
|
-
'/home/runner/work/captcha/captcha/packages/procaptcha-common/tsconfig.json',
|
|
17
16
|
'/home/runner/work/captcha/captcha/packages/load-balancer/tsconfig.json',
|
|
17
|
+
'/home/runner/work/captcha/captcha/packages/procaptcha-common/tsconfig.json',
|
|
18
18
|
'/home/runner/work/captcha/captcha/packages/widget-skeleton/tsconfig.json',
|
|
19
19
|
'/home/runner/work/captcha/captcha/packages/account/tsconfig.json',
|
|
20
20
|
'/home/runner/work/captcha/captcha/packages/fingerprint/tsconfig.json',
|
|
@@ -32,8 +32,8 @@ ViteCommonJSConfig: .
|
|
|
32
32
|
'@prosopo/types',
|
|
33
33
|
'@prosopo/util-crypto',
|
|
34
34
|
'@prosopo/api',
|
|
35
|
-
'@prosopo/procaptcha-common',
|
|
36
35
|
'@prosopo/load-balancer',
|
|
36
|
+
'@prosopo/procaptcha-common',
|
|
37
37
|
'@prosopo/widget-skeleton',
|
|
38
38
|
'@prosopo/account',
|
|
39
39
|
'@prosopo/fingerprint',
|
|
@@ -41,16 +41,17 @@ ViteCommonJSConfig: .
|
|
|
41
41
|
'@prosopo/keyring'
|
|
42
42
|
]
|
|
43
43
|
}
|
|
44
|
-
[
|
|
44
|
+
[33mThe plugin "vite-tsconfig-paths" is detected. Vite now supports tsconfig paths resolution natively via the [1mresolve.tsconfigPaths[22m option. You can remove the plugin and set [1mresolve.tsconfigPaths: true[22m in your Vite config instead.[39m
|
|
45
|
+
[36mvite v8.1.5 [32mbuilding ssr environment for production...[36m[39m
|
|
45
46
|
Bundle build started
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
[32m✓[39m 5 modules transformed.
|
|
49
|
-
[33mEntry module "src/modules/ProsopoCaptchaApi.ts" is using named and default exports together. Consumers of your bundle will have to use `..default` to access the default export, which may not be what you want. Use `output.exports: "named"` to disable this warning.[39m
|
|
47
|
+
[2K
|
|
48
|
+
✓ 6 modules transformed.
|
|
50
49
|
rendering chunks...
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
50
|
+
computing gzip size...
|
|
51
|
+
dist/cjs/modules/index.cjs 0.34 kB │ gzip: 0.13 kB
|
|
52
|
+
dist/cjs/index.cjs 0.44 kB │ gzip: 0.19 kB
|
|
53
|
+
dist/cjs/modules/collector.cjs 1.83 kB │ gzip: 0.59 kB
|
|
54
|
+
dist/cjs/modules/ProsopoCaptchaApi.cjs 2.17 kB │ gzip: 0.78 kB
|
|
55
|
+
dist/cjs/modules/Manager.cjs 13.39 kB │ gzip: 3.71 kB
|
|
56
|
+
|
|
57
|
+
[32m✓ built in 97ms[39m
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
|
|
2
|
-
> @prosopo/procaptcha@2.10.
|
|
2
|
+
> @prosopo/procaptcha@2.10.59 build:tsc
|
|
3
3
|
> tsc --build --verbose
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
12:36:38 PM - Projects in this build:
|
|
6
6
|
* ../../dev/config/tsconfig.json
|
|
7
7
|
* ../locale/tsconfig.json
|
|
8
8
|
* ../util/tsconfig.json
|
|
@@ -21,39 +21,39 @@
|
|
|
21
21
|
* ../procaptcha-common/tsconfig.json
|
|
22
22
|
* tsconfig.json
|
|
23
23
|
|
|
24
|
-
|
|
24
|
+
12:36:38 PM - Project '../../dev/config/tsconfig.json' is up to date because newest input '../../dev/config/src/webpack/index.ts' is older than output '../../dev/config/tsconfig.tsbuildinfo'
|
|
25
25
|
|
|
26
|
-
|
|
26
|
+
12:36:38 PM - Project '../locale/tsconfig.json' is up to date because newest input '../locale/src/translationKey.ts' is older than output '../locale/tsconfig.tsbuildinfo'
|
|
27
27
|
|
|
28
|
-
|
|
28
|
+
12:36:38 PM - Project '../util/tsconfig.json' is up to date because newest input '../util/src/url.ts' is older than output '../util/tsconfig.tsbuildinfo'
|
|
29
29
|
|
|
30
|
-
|
|
30
|
+
12:36:38 PM - Project '../logger/tsconfig.json' is up to date because newest input '../logger/src/index.ts' is older than output '../logger/tsconfig.tsbuildinfo'
|
|
31
31
|
|
|
32
|
-
|
|
32
|
+
12:36:38 PM - Project '../util-crypto/tsconfig.json' is up to date because newest input '../util-crypto/src/types.ts' is older than output '../util-crypto/tsconfig.tsbuildinfo'
|
|
33
33
|
|
|
34
|
-
|
|
34
|
+
12:36:38 PM - Project '../types/tsconfig.json' is up to date because newest input '../types/src/provider/api.ts' is older than output '../types/tsconfig.tsbuildinfo'
|
|
35
35
|
|
|
36
|
-
|
|
36
|
+
12:36:38 PM - Project '../common/tsconfig.json' is up to date because newest input '../common/src/index.ts' is older than output '../common/tsconfig.tsbuildinfo'
|
|
37
37
|
|
|
38
|
-
|
|
38
|
+
12:36:38 PM - Project '../datasets/tsconfig.json' is up to date because newest input '../datasets/src/tests/dataset.unit.test.ts' is older than output '../datasets/tsconfig.tsbuildinfo'
|
|
39
39
|
|
|
40
|
-
|
|
40
|
+
12:36:38 PM - Project '../api/tsconfig.json' is up to date because newest input '../api/src/tests/apiHarness.ts' is older than output '../api/tsconfig.tsbuildinfo'
|
|
41
41
|
|
|
42
|
-
|
|
42
|
+
12:36:39 PM - Project '../load-balancer/tsconfig.json' is up to date because newest input '../load-balancer/src/tests/providers.unit.test.ts' is older than output '../load-balancer/tsconfig.tsbuildinfo'
|
|
43
43
|
|
|
44
|
-
|
|
44
|
+
12:36:39 PM - Project '../widget-skeleton/tsconfig.json' is up to date because newest input '../widget-skeleton/src/webComponent/createWidget.ts' is older than output '../widget-skeleton/tsconfig.tsbuildinfo'
|
|
45
45
|
|
|
46
|
-
|
|
46
|
+
12:36:39 PM - Project '../fingerprintjs/tsconfig.json' is up to date because newest input '../fingerprintjs/src/utils/browser.ts' is older than output '../fingerprintjs/tsconfig.tsbuildinfo'
|
|
47
47
|
|
|
48
|
-
|
|
48
|
+
12:36:39 PM - Project '../fingerprint/tsconfig.json' is up to date because newest input '../fingerprint/src/index.ts' is older than output '../fingerprint/tsconfig.tsbuildinfo'
|
|
49
49
|
|
|
50
|
-
|
|
50
|
+
12:36:39 PM - Project '../keyring/tsconfig.json' is up to date because newest input '../keyring/src/keyring/keyring.ts' is older than output '../keyring/tsconfig.tsbuildinfo'
|
|
51
51
|
|
|
52
|
-
|
|
52
|
+
12:36:39 PM - Project '../account/tsconfig.json' is up to date because newest input '../account/src/custom.d.ts' is older than output '../account/tsconfig.tsbuildinfo'
|
|
53
53
|
|
|
54
|
-
|
|
54
|
+
12:36:39 PM - Project '../procaptcha-common/tsconfig.json' is up to date because newest input '../procaptcha-common/src/simdReadings.ts' is older than output '../procaptcha-common/tsconfig.tsbuildinfo'
|
|
55
55
|
|
|
56
|
-
|
|
56
|
+
12:36:39 PM - Project 'tsconfig.json' is out of date because output file 'tsconfig.tsbuildinfo' does not exist
|
|
57
57
|
|
|
58
|
-
|
|
58
|
+
12:36:39 PM - Building project '/home/runner/work/captcha/captcha/packages/procaptcha/tsconfig.json'...
|
|
59
59
|
|
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
|
|
2
|
-
> @prosopo/procaptcha@2.10.
|
|
2
|
+
> @prosopo/procaptcha@2.10.59 build
|
|
3
3
|
> npm run build:cross-env -- --mode ${NODE_ENV:-development}
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
> @prosopo/procaptcha@2.10.
|
|
6
|
+
> @prosopo/procaptcha@2.10.59 build:cross-env
|
|
7
7
|
> vite build --config vite.esm.config.ts --mode production
|
|
8
8
|
|
|
9
9
|
ViteEsmConfig: .
|
|
@@ -17,8 +17,8 @@ ViteEsmConfig: .
|
|
|
17
17
|
'/home/runner/work/captcha/captcha/packages/types/tsconfig.json',
|
|
18
18
|
'/home/runner/work/captcha/captcha/packages/util-crypto/tsconfig.json',
|
|
19
19
|
'/home/runner/work/captcha/captcha/packages/api/tsconfig.json',
|
|
20
|
-
'/home/runner/work/captcha/captcha/packages/procaptcha-common/tsconfig.json',
|
|
21
20
|
'/home/runner/work/captcha/captcha/packages/load-balancer/tsconfig.json',
|
|
21
|
+
'/home/runner/work/captcha/captcha/packages/procaptcha-common/tsconfig.json',
|
|
22
22
|
'/home/runner/work/captcha/captcha/packages/widget-skeleton/tsconfig.json',
|
|
23
23
|
'/home/runner/work/captcha/captcha/packages/account/tsconfig.json',
|
|
24
24
|
'/home/runner/work/captcha/captcha/packages/fingerprint/tsconfig.json',
|
|
@@ -36,8 +36,8 @@ ViteEsmConfig: .
|
|
|
36
36
|
'@prosopo/types',
|
|
37
37
|
'@prosopo/util-crypto',
|
|
38
38
|
'@prosopo/api',
|
|
39
|
-
'@prosopo/procaptcha-common',
|
|
40
39
|
'@prosopo/load-balancer',
|
|
40
|
+
'@prosopo/procaptcha-common',
|
|
41
41
|
'@prosopo/widget-skeleton',
|
|
42
42
|
'@prosopo/account',
|
|
43
43
|
'@prosopo/fingerprint',
|
|
@@ -45,15 +45,18 @@ ViteEsmConfig: .
|
|
|
45
45
|
'@prosopo/keyring'
|
|
46
46
|
]
|
|
47
47
|
}
|
|
48
|
-
[
|
|
48
|
+
[33mThe plugin "vite-tsconfig-paths" is detected. Vite now supports tsconfig paths resolution natively via the [1mresolve.tsconfigPaths[22m option. You can remove the plugin and set [1mresolve.tsconfigPaths: true[22m in your Vite config instead.[39m
|
|
49
|
+
[36mvite v8.1.5 [32mbuilding ssr environment for production...[36m[39m
|
|
49
50
|
Bundle build started
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
[32m✓[39m 5 modules transformed.
|
|
51
|
+
[2K
|
|
52
|
+
✓ 6 modules transformed.
|
|
53
53
|
rendering chunks...
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
54
|
+
computing gzip size...
|
|
55
|
+
dist/_virtual/_rolldown/runtime.js 0.04 kB │ gzip: 0.06 kB
|
|
56
|
+
dist/modules/index.js 0.20 kB │ gzip: 0.11 kB
|
|
57
|
+
dist/index.js 0.27 kB │ gzip: 0.14 kB
|
|
58
|
+
dist/modules/collector.js 1.81 kB │ gzip: 0.59 kB
|
|
59
|
+
dist/modules/ProsopoCaptchaApi.js 2.09 kB │ gzip: 0.78 kB
|
|
60
|
+
dist/modules/Manager.js 12.62 kB │ gzip: 3.65 kB
|
|
61
|
+
|
|
62
|
+
[32m✓ built in 66ms[39m
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,53 @@
|
|
|
1
1
|
# @prosopo/procaptcha
|
|
2
2
|
|
|
3
|
+
## 2.10.59
|
|
4
|
+
### Patch Changes
|
|
5
|
+
|
|
6
|
+
- cc022be: Add unit and type tests for the image captcha manager, the provider adapter and the behavioural collector (140 tests, 100% statement/branch/function/line coverage).
|
|
7
|
+
|
|
8
|
+
Two edge cases surfaced and fixed while covering `ProsopoCaptchaApi`/`Manager`:
|
|
9
|
+
|
|
10
|
+
- `submitCaptchaSolution` overflowed the stack on an empty solution set: `CaptchaMerkleTree` recurses on an empty layer, so the existing `!tree.root` guard never ran. Empty solution sets are now rejected up front.
|
|
11
|
+
- `loadProviderApi` proved the site key was set but its callers still fell back to `""` when constructing `ProsopoCaptchaApi`, so a missing site key could have been forwarded as an empty dapp account. It now returns the validated site key alongside the client.
|
|
12
|
+
|
|
13
|
+
No behavioural changes to the captcha flow itself.
|
|
14
|
+
- Updated dependencies [1e0cf14]
|
|
15
|
+
- @prosopo/api@3.5.21
|
|
16
|
+
|
|
17
|
+
## 2.10.58
|
|
18
|
+
### Patch Changes
|
|
19
|
+
|
|
20
|
+
- ab3499c: feat(procaptcha): block on SIMD readings at solution submit
|
|
21
|
+
|
|
22
|
+
Solution submit is the last hop the client controls, so it's the last chance to
|
|
23
|
+
attach the catcher's WASM SIMD readings for a session. The image, PoW and puzzle
|
|
24
|
+
managers now wait for the benchmark there via a shared
|
|
25
|
+
`getSimdReadingsForSubmit` helper, capped at 5s, instead of attaching only
|
|
26
|
+
whatever the prefetch happened to have resolved.
|
|
27
|
+
|
|
28
|
+
The helper passes the budget down to the detector *and* races it locally — the
|
|
29
|
+
detector ships prebuilt, so a bundle that ignores `timeoutMs` (or a benchmark
|
|
30
|
+
wedged on a busy main thread) can't hang the submission. It never rejects: a
|
|
31
|
+
missing accessor, a rejection, a synchronous throw and a timeout all resolve to
|
|
32
|
+
`undefined` and the solution is submitted without readings, so a user is never
|
|
33
|
+
failed over telemetry.
|
|
34
|
+
|
|
35
|
+
The earlier frictionless POST and challenge GET hops are unchanged and remain
|
|
36
|
+
non-blocking.
|
|
37
|
+
- e14fce6: chore(deps): bump vite to 6.4.3 and mongoose to 8.24.1, and adjust types for the mongoose 8.24 Document/ObjectId changes
|
|
38
|
+
- Updated dependencies [2c47bb7]
|
|
39
|
+
- Updated dependencies [ab3499c]
|
|
40
|
+
- Updated dependencies [0e1171c]
|
|
41
|
+
- Updated dependencies [103318c]
|
|
42
|
+
- Updated dependencies [270a8d8]
|
|
43
|
+
- Updated dependencies [e14fce6]
|
|
44
|
+
- @prosopo/util@3.3.5
|
|
45
|
+
- @prosopo/procaptcha-common@2.11.18
|
|
46
|
+
- @prosopo/types@4.10.0
|
|
47
|
+
- @prosopo/api@3.5.20
|
|
48
|
+
- @prosopo/common@3.1.48
|
|
49
|
+
- @prosopo/datasets@3.1.55
|
|
50
|
+
|
|
3
51
|
## 2.10.57
|
|
4
52
|
### Patch Changes
|
|
5
53
|
|
package/dist/cjs/index.cjs
CHANGED
|
@@ -1,9 +1,7 @@
|
|
|
1
|
-
"use strict";
|
|
2
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
require("./modules/
|
|
4
|
-
const
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
exports.
|
|
8
|
-
exports.
|
|
9
|
-
exports.startCollector = collector.startCollector;
|
|
2
|
+
const require_ProsopoCaptchaApi = require("./modules/ProsopoCaptchaApi.cjs");
|
|
3
|
+
const require_Manager = require("./modules/Manager.cjs");
|
|
4
|
+
const require_collector = require("./modules/collector.cjs");
|
|
5
|
+
exports.Manager = require_Manager.Manager;
|
|
6
|
+
exports.ProsopoCaptchaApi = require_ProsopoCaptchaApi.ProsopoCaptchaApi;
|
|
7
|
+
exports.startCollector = require_collector.startCollector;
|