@nocobase/plugin-idp-oauth 2.1.0-alpha.10
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/LICENSE.txt +107 -0
- package/README.md +14 -0
- package/build.config.ts +46 -0
- package/client.d.ts +2 -0
- package/client.js +1 -0
- package/dist/client/ErrorPage.d.ts +11 -0
- package/dist/client/InteractionPage.d.ts +11 -0
- package/dist/client/index.d.ts +9 -0
- package/dist/client/index.js +10 -0
- package/dist/client/locale.d.ts +10 -0
- package/dist/client/models/index.d.ts +11 -0
- package/dist/client/plugin.d.ts +13 -0
- package/dist/externalVersion.js +18 -0
- package/dist/index.d.ts +10 -0
- package/dist/index.js +48 -0
- package/dist/locale/en-US.json +1 -0
- package/dist/locale/zh-CN.json +1 -0
- package/dist/node_modules/eta/LICENSE +7 -0
- package/dist/node_modules/eta/README.md +185 -0
- package/dist/node_modules/eta/dist/core.d.ts +179 -0
- package/dist/node_modules/eta/dist/core.d.ts.map +1 -0
- package/dist/node_modules/eta/dist/core.js +42 -0
- package/dist/node_modules/eta/dist/core.js.map +1 -0
- package/dist/node_modules/eta/dist/index.cjs +542 -0
- package/dist/node_modules/eta/dist/index.cjs.map +1 -0
- package/dist/node_modules/eta/dist/index.d.cts +187 -0
- package/dist/node_modules/eta/dist/index.d.cts.map +1 -0
- package/dist/node_modules/eta/dist/index.d.mts +187 -0
- package/dist/node_modules/eta/dist/index.d.mts.map +1 -0
- package/dist/node_modules/eta/dist/index.mjs +512 -0
- package/dist/node_modules/eta/dist/index.mjs.map +1 -0
- package/dist/node_modules/eta/package.json +75 -0
- package/dist/node_modules/jose/LICENSE.md +21 -0
- package/dist/node_modules/jose/README.md +153 -0
- package/dist/node_modules/jose/dist/types/index.d.ts +55 -0
- package/dist/node_modules/jose/dist/types/jwe/compact/decrypt.d.ts +31 -0
- package/dist/node_modules/jose/dist/types/jwe/compact/encrypt.d.ts +65 -0
- package/dist/node_modules/jose/dist/types/jwe/flattened/decrypt.d.ts +31 -0
- package/dist/node_modules/jose/dist/types/jwe/flattened/encrypt.d.ts +83 -0
- package/dist/node_modules/jose/dist/types/jwe/general/decrypt.d.ts +38 -0
- package/dist/node_modules/jose/dist/types/jwe/general/encrypt.d.ts +74 -0
- package/dist/node_modules/jose/dist/types/jwk/embedded.d.ts +17 -0
- package/dist/node_modules/jose/dist/types/jwk/thumbprint.d.ts +32 -0
- package/dist/node_modules/jose/dist/types/jwks/local.d.ts +29 -0
- package/dist/node_modules/jose/dist/types/jwks/remote.d.ts +237 -0
- package/dist/node_modules/jose/dist/types/jws/compact/sign.d.ts +36 -0
- package/dist/node_modules/jose/dist/types/jws/compact/verify.d.ts +33 -0
- package/dist/node_modules/jose/dist/types/jws/flattened/sign.d.ts +42 -0
- package/dist/node_modules/jose/dist/types/jws/flattened/verify.d.ts +33 -0
- package/dist/node_modules/jose/dist/types/jws/general/sign.d.ts +53 -0
- package/dist/node_modules/jose/dist/types/jws/general/verify.d.ts +41 -0
- package/dist/node_modules/jose/dist/types/jwt/decrypt.d.ts +35 -0
- package/dist/node_modules/jose/dist/types/jwt/encrypt.d.ts +91 -0
- package/dist/node_modules/jose/dist/types/jwt/sign.d.ts +43 -0
- package/dist/node_modules/jose/dist/types/jwt/unsecured.d.ts +43 -0
- package/dist/node_modules/jose/dist/types/jwt/verify.d.ts +37 -0
- package/dist/node_modules/jose/dist/types/key/export.d.ts +33 -0
- package/dist/node_modules/jose/dist/types/key/generate_key_pair.d.ts +47 -0
- package/dist/node_modules/jose/dist/types/key/generate_secret.d.ts +35 -0
- package/dist/node_modules/jose/dist/types/key/import.d.ts +83 -0
- package/dist/node_modules/jose/dist/types/types.d.ts +852 -0
- package/dist/node_modules/jose/dist/types/util/base64url.d.ts +9 -0
- package/dist/node_modules/jose/dist/types/util/decode_jwt.d.ts +18 -0
- package/dist/node_modules/jose/dist/types/util/decode_protected_header.d.ts +17 -0
- package/dist/node_modules/jose/dist/types/util/errors.d.ts +213 -0
- package/dist/node_modules/jose/dist/webapi/index.js +32 -0
- package/dist/node_modules/jose/dist/webapi/jwe/compact/decrypt.js +27 -0
- package/dist/node_modules/jose/dist/webapi/jwe/compact/encrypt.js +27 -0
- package/dist/node_modules/jose/dist/webapi/jwe/flattened/decrypt.js +155 -0
- package/dist/node_modules/jose/dist/webapi/jwe/flattened/encrypt.js +165 -0
- package/dist/node_modules/jose/dist/webapi/jwe/general/decrypt.js +31 -0
- package/dist/node_modules/jose/dist/webapi/jwe/general/encrypt.js +182 -0
- package/dist/node_modules/jose/dist/webapi/jwk/embedded.js +17 -0
- package/dist/node_modules/jose/dist/webapi/jwk/thumbprint.js +68 -0
- package/dist/node_modules/jose/dist/webapi/jwks/local.js +119 -0
- package/dist/node_modules/jose/dist/webapi/jwks/remote.js +179 -0
- package/dist/node_modules/jose/dist/webapi/jws/compact/sign.js +18 -0
- package/dist/node_modules/jose/dist/webapi/jws/compact/verify.js +21 -0
- package/dist/node_modules/jose/dist/webapi/jws/flattened/sign.js +89 -0
- package/dist/node_modules/jose/dist/webapi/jws/flattened/verify.js +110 -0
- package/dist/node_modules/jose/dist/webapi/jws/general/sign.js +70 -0
- package/dist/node_modules/jose/dist/webapi/jws/general/verify.js +24 -0
- package/dist/node_modules/jose/dist/webapi/jwt/decrypt.js +23 -0
- package/dist/node_modules/jose/dist/webapi/jwt/encrypt.js +101 -0
- package/dist/node_modules/jose/dist/webapi/jwt/sign.js +52 -0
- package/dist/node_modules/jose/dist/webapi/jwt/unsecured.js +63 -0
- package/dist/node_modules/jose/dist/webapi/jwt/verify.js +15 -0
- package/dist/node_modules/jose/dist/webapi/key/export.js +11 -0
- package/dist/node_modules/jose/dist/webapi/key/generate_key_pair.js +97 -0
- package/dist/node_modules/jose/dist/webapi/key/generate_secret.js +40 -0
- package/dist/node_modules/jose/dist/webapi/key/import.js +57 -0
- package/dist/node_modules/jose/dist/webapi/lib/aesgcmkw.js +15 -0
- package/dist/node_modules/jose/dist/webapi/lib/aeskw.js +25 -0
- package/dist/node_modules/jose/dist/webapi/lib/asn1.js +243 -0
- package/dist/node_modules/jose/dist/webapi/lib/base64.js +22 -0
- package/dist/node_modules/jose/dist/webapi/lib/buffer_utils.js +43 -0
- package/dist/node_modules/jose/dist/webapi/lib/check_key_type.js +122 -0
- package/dist/node_modules/jose/dist/webapi/lib/content_encryption.js +217 -0
- package/dist/node_modules/jose/dist/webapi/lib/crypto_key.js +136 -0
- package/dist/node_modules/jose/dist/webapi/lib/deflate.js +44 -0
- package/dist/node_modules/jose/dist/webapi/lib/ecdhes.js +52 -0
- package/dist/node_modules/jose/dist/webapi/lib/helpers.js +19 -0
- package/dist/node_modules/jose/dist/webapi/lib/invalid_key_input.js +27 -0
- package/dist/node_modules/jose/dist/webapi/lib/is_key_like.js +17 -0
- package/dist/node_modules/jose/dist/webapi/lib/jwk_to_key.js +107 -0
- package/dist/node_modules/jose/dist/webapi/lib/jwt_claims_set.js +238 -0
- package/dist/node_modules/jose/dist/webapi/lib/key_management.js +186 -0
- package/dist/node_modules/jose/dist/webapi/lib/key_to_jwk.js +31 -0
- package/dist/node_modules/jose/dist/webapi/lib/normalize_key.js +166 -0
- package/dist/node_modules/jose/dist/webapi/lib/pbes2kw.js +39 -0
- package/dist/node_modules/jose/dist/webapi/lib/rsaes.js +24 -0
- package/dist/node_modules/jose/dist/webapi/lib/signing.js +68 -0
- package/dist/node_modules/jose/dist/webapi/lib/type_checks.js +40 -0
- package/dist/node_modules/jose/dist/webapi/lib/validate_algorithms.js +10 -0
- package/dist/node_modules/jose/dist/webapi/lib/validate_crit.js +33 -0
- package/dist/node_modules/jose/dist/webapi/util/base64url.js +30 -0
- package/dist/node_modules/jose/dist/webapi/util/decode_jwt.js +32 -0
- package/dist/node_modules/jose/dist/webapi/util/decode_protected_header.js +34 -0
- package/dist/node_modules/jose/dist/webapi/util/errors.js +99 -0
- package/dist/node_modules/jose/package.json +200 -0
- package/dist/node_modules/light-my-request/.gitattributes +2 -0
- package/dist/node_modules/light-my-request/.github/dependabot.yml +13 -0
- package/dist/node_modules/light-my-request/.github/stale.yml +21 -0
- package/dist/node_modules/light-my-request/.github/workflows/benchmark.yml +30 -0
- package/dist/node_modules/light-my-request/.github/workflows/ci.yml +23 -0
- package/dist/node_modules/light-my-request/LICENSE +32 -0
- package/dist/node_modules/light-my-request/benchmark/benchmark.js +164 -0
- package/dist/node_modules/light-my-request/build/build-validation.js +100 -0
- package/dist/node_modules/light-my-request/eslint.config.js +9 -0
- package/dist/node_modules/light-my-request/index.js +2 -0
- package/dist/node_modules/light-my-request/lib/config-validator.js +919 -0
- package/dist/node_modules/light-my-request/lib/form-data.js +79 -0
- package/dist/node_modules/light-my-request/lib/parse-url.js +47 -0
- package/dist/node_modules/light-my-request/lib/request.js +290 -0
- package/dist/node_modules/light-my-request/lib/response.js +240 -0
- package/dist/node_modules/light-my-request/node_modules/process-warning/.gitattributes +2 -0
- package/dist/node_modules/light-my-request/node_modules/process-warning/.github/dependabot.yml +13 -0
- package/dist/node_modules/light-my-request/node_modules/process-warning/.github/workflows/ci.yml +24 -0
- package/dist/node_modules/light-my-request/node_modules/process-warning/.taprc +2 -0
- package/dist/node_modules/light-my-request/node_modules/process-warning/benchmarks/warn.js +25 -0
- package/dist/node_modules/light-my-request/node_modules/process-warning/eslint.config.js +6 -0
- package/dist/node_modules/light-my-request/node_modules/process-warning/examples/example.js +11 -0
- package/dist/node_modules/light-my-request/node_modules/process-warning/index.js +124 -0
- package/dist/node_modules/light-my-request/node_modules/process-warning/package.json +73 -0
- package/dist/node_modules/light-my-request/node_modules/process-warning/test/emit-interpolated-string.test.js +29 -0
- package/dist/node_modules/light-my-request/node_modules/process-warning/test/emit-once-only.test.js +28 -0
- package/dist/node_modules/light-my-request/node_modules/process-warning/test/emit-reset.test.js +36 -0
- package/dist/node_modules/light-my-request/node_modules/process-warning/test/emit-set.test.js +30 -0
- package/dist/node_modules/light-my-request/node_modules/process-warning/test/emit-unlimited.test.js +37 -0
- package/dist/node_modules/light-my-request/node_modules/process-warning/test/index.test.js +99 -0
- package/dist/node_modules/light-my-request/node_modules/process-warning/test/issue-88.test.js +33 -0
- package/dist/node_modules/light-my-request/node_modules/process-warning/test/jest.test.js +22 -0
- package/dist/node_modules/light-my-request/node_modules/process-warning/test/no-warnings.test.js +80 -0
- package/dist/node_modules/light-my-request/node_modules/process-warning/types/index.d.ts +37 -0
- package/dist/node_modules/light-my-request/node_modules/process-warning/types/index.test-d.ts +36 -0
- package/dist/node_modules/light-my-request/package.json +1 -0
- package/dist/node_modules/light-my-request/test/async-await.test.js +55 -0
- package/dist/node_modules/light-my-request/test/index.test.js +2316 -0
- package/dist/node_modules/light-my-request/test/request.test.js +16 -0
- package/dist/node_modules/light-my-request/test/response.test.js +19 -0
- package/dist/node_modules/light-my-request/test/stream.test.js +359 -0
- package/dist/node_modules/light-my-request/types/index.d.ts +128 -0
- package/dist/node_modules/light-my-request/types/index.test-d.ts +149 -0
- package/dist/node_modules/oidc-provider/LICENSE.md +21 -0
- package/dist/node_modules/oidc-provider/README.md +174 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/assign_claims.js +28 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/assign_defaults.js +17 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/authenticated_client_id.js +6 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/backchannel_request_remap_errors.js +17 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/backchannel_request_response.js +41 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/check_ciba_context.js +12 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/check_claims.js +68 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/check_client.js +21 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/check_client_grant_type.js +21 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/check_dpop_jkt.js +35 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/check_extra_params.js +18 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/check_id_token_hint.js +23 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/check_max_age.js +25 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/check_openid_scope.js +47 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/check_pkce.js +41 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/check_prompt.js +25 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/check_redirect_uri.js +41 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/check_requested_expiry.js +16 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/check_response_mode.js +54 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/check_response_type.js +26 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/check_scope.js +53 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/ciba_load_account.js +58 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/ciba_required.js +13 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/device_authorization_response.js +31 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/device_user_flow.js +31 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/device_user_flow_errors.js +37 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/device_user_flow_response.js +55 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/index.js +200 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/interaction_emit.js +9 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/interactions.js +149 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/load_account.js +15 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/load_grant.js +29 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/load_pushed_authorization_request.js +36 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/oauth_required.js +11 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/oidc_required.js +27 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/one_redirect_uri_clients.js +20 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/process_request_object.js +214 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/pushed_authorization_request_remap_errors.js +17 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/pushed_authorization_request_response.js +65 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/reject_registration.js +12 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/reject_request_and_uri.js +12 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/reject_unsupported.js +33 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/respond.js +46 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/resume.js +111 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/strip_outside_jar_params.js +19 -0
- package/dist/node_modules/oidc-provider/lib/actions/authorization/unsupported_rar.js +9 -0
- package/dist/node_modules/oidc-provider/lib/actions/challenge.js +22 -0
- package/dist/node_modules/oidc-provider/lib/actions/code_verification.js +122 -0
- package/dist/node_modules/oidc-provider/lib/actions/discovery.js +151 -0
- package/dist/node_modules/oidc-provider/lib/actions/end_session.js +222 -0
- package/dist/node_modules/oidc-provider/lib/actions/grants/authorization_code.js +144 -0
- package/dist/node_modules/oidc-provider/lib/actions/grants/ciba.js +127 -0
- package/dist/node_modules/oidc-provider/lib/actions/grants/client_credentials.js +79 -0
- package/dist/node_modules/oidc-provider/lib/actions/grants/device_code.js +125 -0
- package/dist/node_modules/oidc-provider/lib/actions/grants/index.js +7 -0
- package/dist/node_modules/oidc-provider/lib/actions/grants/refresh_token.js +229 -0
- package/dist/node_modules/oidc-provider/lib/actions/index.js +25 -0
- package/dist/node_modules/oidc-provider/lib/actions/interaction.js +150 -0
- package/dist/node_modules/oidc-provider/lib/actions/introspection.js +164 -0
- package/dist/node_modules/oidc-provider/lib/actions/jwks.js +7 -0
- package/dist/node_modules/oidc-provider/lib/actions/registration.js +274 -0
- package/dist/node_modules/oidc-provider/lib/actions/revocation.js +81 -0
- package/dist/node_modules/oidc-provider/lib/actions/token.js +74 -0
- package/dist/node_modules/oidc-provider/lib/actions/userinfo.js +183 -0
- package/dist/node_modules/oidc-provider/lib/adapters/memory_adapter.js +95 -0
- package/dist/node_modules/oidc-provider/lib/consts/client_attributes.js +211 -0
- package/dist/node_modules/oidc-provider/lib/consts/dev_keystore.js +18 -0
- package/dist/node_modules/oidc-provider/lib/consts/index.js +13 -0
- package/dist/node_modules/oidc-provider/lib/consts/jwa.js +47 -0
- package/dist/node_modules/oidc-provider/lib/consts/non_rejectable_claims.js +1 -0
- package/dist/node_modules/oidc-provider/lib/consts/param_list.js +23 -0
- package/dist/node_modules/oidc-provider/lib/helpers/_/camel_case.js +1 -0
- package/dist/node_modules/oidc-provider/lib/helpers/_/defaults.js +28 -0
- package/dist/node_modules/oidc-provider/lib/helpers/_/difference.js +1 -0
- package/dist/node_modules/oidc-provider/lib/helpers/_/is_plain_object.js +1 -0
- package/dist/node_modules/oidc-provider/lib/helpers/_/map_keys.js +9 -0
- package/dist/node_modules/oidc-provider/lib/helpers/_/merge.js +25 -0
- package/dist/node_modules/oidc-provider/lib/helpers/_/omit_by.js +11 -0
- package/dist/node_modules/oidc-provider/lib/helpers/_/pick.js +10 -0
- package/dist/node_modules/oidc-provider/lib/helpers/_/pick_by.js +10 -0
- package/dist/node_modules/oidc-provider/lib/helpers/_/remove.js +9 -0
- package/dist/node_modules/oidc-provider/lib/helpers/_/set.js +18 -0
- package/dist/node_modules/oidc-provider/lib/helpers/_/snake_case.js +1 -0
- package/dist/node_modules/oidc-provider/lib/helpers/_/upper_first.js +1 -0
- package/dist/node_modules/oidc-provider/lib/helpers/account_claims.js +6 -0
- package/dist/node_modules/oidc-provider/lib/helpers/add_client.js +14 -0
- package/dist/node_modules/oidc-provider/lib/helpers/als.js +3 -0
- package/dist/node_modules/oidc-provider/lib/helpers/append_www_authenticate.js +9 -0
- package/dist/node_modules/oidc-provider/lib/helpers/attention.js +23 -0
- package/dist/node_modules/oidc-provider/lib/helpers/base64url.js +11 -0
- package/dist/node_modules/oidc-provider/lib/helpers/certificate_thumbprint.js +15 -0
- package/dist/node_modules/oidc-provider/lib/helpers/challenge.js +111 -0
- package/dist/node_modules/oidc-provider/lib/helpers/check_attest_binding.js +10 -0
- package/dist/node_modules/oidc-provider/lib/helpers/claims.js +79 -0
- package/dist/node_modules/oidc-provider/lib/helpers/client_id_metadata_document.js +198 -0
- package/dist/node_modules/oidc-provider/lib/helpers/client_schema.js +700 -0
- package/dist/node_modules/oidc-provider/lib/helpers/combined_scope.js +17 -0
- package/dist/node_modules/oidc-provider/lib/helpers/configuration.js +544 -0
- package/dist/node_modules/oidc-provider/lib/helpers/constant_equals.js +20 -0
- package/dist/node_modules/oidc-provider/lib/helpers/defaults.js +3510 -0
- package/dist/node_modules/oidc-provider/lib/helpers/epoch_time.js +1 -0
- package/dist/node_modules/oidc-provider/lib/helpers/err_out.js +17 -0
- package/dist/node_modules/oidc-provider/lib/helpers/errors.js +161 -0
- package/dist/node_modules/oidc-provider/lib/helpers/features.js +51 -0
- package/dist/node_modules/oidc-provider/lib/helpers/fetch_body_check.js +25 -0
- package/dist/node_modules/oidc-provider/lib/helpers/fetch_request.js +221 -0
- package/dist/node_modules/oidc-provider/lib/helpers/filter_claims.js +16 -0
- package/dist/node_modules/oidc-provider/lib/helpers/formatters.js +24 -0
- package/dist/node_modules/oidc-provider/lib/helpers/grant_common.js +214 -0
- package/dist/node_modules/oidc-provider/lib/helpers/html_safe.js +19 -0
- package/dist/node_modules/oidc-provider/lib/helpers/initialize_adapter.js +24 -0
- package/dist/node_modules/oidc-provider/lib/helpers/initialize_app.js +243 -0
- package/dist/node_modules/oidc-provider/lib/helpers/initialize_clients.js +24 -0
- package/dist/node_modules/oidc-provider/lib/helpers/initialize_keystore.js +310 -0
- package/dist/node_modules/oidc-provider/lib/helpers/interaction_policy/check.js +21 -0
- package/dist/node_modules/oidc-provider/lib/helpers/interaction_policy/index.js +43 -0
- package/dist/node_modules/oidc-provider/lib/helpers/interaction_policy/prompt.js +95 -0
- package/dist/node_modules/oidc-provider/lib/helpers/interaction_policy/prompts/consent.js +105 -0
- package/dist/node_modules/oidc-provider/lib/helpers/interaction_policy/prompts/login.js +162 -0
- package/dist/node_modules/oidc-provider/lib/helpers/jwt.js +211 -0
- package/dist/node_modules/oidc-provider/lib/helpers/keystore.js +301 -0
- package/dist/node_modules/oidc-provider/lib/helpers/nanoid.js +5 -0
- package/dist/node_modules/oidc-provider/lib/helpers/oidc_context.js +284 -0
- package/dist/node_modules/oidc-provider/lib/helpers/params.js +27 -0
- package/dist/node_modules/oidc-provider/lib/helpers/pkce.js +30 -0
- package/dist/node_modules/oidc-provider/lib/helpers/pkce_format.js +17 -0
- package/dist/node_modules/oidc-provider/lib/helpers/process_response_types.js +202 -0
- package/dist/node_modules/oidc-provider/lib/helpers/re_render_errors.js +39 -0
- package/dist/node_modules/oidc-provider/lib/helpers/redirect_uri.js +16 -0
- package/dist/node_modules/oidc-provider/lib/helpers/resolve_resource.js +33 -0
- package/dist/node_modules/oidc-provider/lib/helpers/resolve_response_mode.js +7 -0
- package/dist/node_modules/oidc-provider/lib/helpers/resource_server.js +20 -0
- package/dist/node_modules/oidc-provider/lib/helpers/revoke.js +27 -0
- package/dist/node_modules/oidc-provider/lib/helpers/script_src_sha.js +21 -0
- package/dist/node_modules/oidc-provider/lib/helpers/sector_identifier.js +19 -0
- package/dist/node_modules/oidc-provider/lib/helpers/sector_validate.js +55 -0
- package/dist/node_modules/oidc-provider/lib/helpers/set_rt_bindings.js +21 -0
- package/dist/node_modules/oidc-provider/lib/helpers/token_find.js +51 -0
- package/dist/node_modules/oidc-provider/lib/helpers/type_validators.js +8 -0
- package/dist/node_modules/oidc-provider/lib/helpers/user_code_form.js +19 -0
- package/dist/node_modules/oidc-provider/lib/helpers/user_codes.js +38 -0
- package/dist/node_modules/oidc-provider/lib/helpers/valid_url.js +8 -0
- package/dist/node_modules/oidc-provider/lib/helpers/validate_dpop.js +129 -0
- package/dist/node_modules/oidc-provider/lib/helpers/validate_presence.js +17 -0
- package/dist/node_modules/oidc-provider/lib/helpers/weak_cache.js +11 -0
- package/dist/node_modules/oidc-provider/lib/index.js +21 -0
- package/dist/node_modules/oidc-provider/lib/models/access_token.js +31 -0
- package/dist/node_modules/oidc-provider/lib/models/authorization_code.js +27 -0
- package/dist/node_modules/oidc-provider/lib/models/backchannel_authentication_request.js +26 -0
- package/dist/node_modules/oidc-provider/lib/models/base_model.js +141 -0
- package/dist/node_modules/oidc-provider/lib/models/base_token.js +86 -0
- package/dist/node_modules/oidc-provider/lib/models/client.js +593 -0
- package/dist/node_modules/oidc-provider/lib/models/client_credentials.js +19 -0
- package/dist/node_modules/oidc-provider/lib/models/device_code.js +44 -0
- package/dist/node_modules/oidc-provider/lib/models/formats/dynamic.js +21 -0
- package/dist/node_modules/oidc-provider/lib/models/formats/index.js +14 -0
- package/dist/node_modules/oidc-provider/lib/models/formats/jwt.js +198 -0
- package/dist/node_modules/oidc-provider/lib/models/formats/opaque.js +58 -0
- package/dist/node_modules/oidc-provider/lib/models/grant.js +243 -0
- package/dist/node_modules/oidc-provider/lib/models/id_token.js +271 -0
- package/dist/node_modules/oidc-provider/lib/models/index.js +37 -0
- package/dist/node_modules/oidc-provider/lib/models/initial_access_token.js +12 -0
- package/dist/node_modules/oidc-provider/lib/models/interaction.js +73 -0
- package/dist/node_modules/oidc-provider/lib/models/mixins/apply.js +4 -0
- package/dist/node_modules/oidc-provider/lib/models/mixins/consumable.js +17 -0
- package/dist/node_modules/oidc-provider/lib/models/mixins/has_format.js +46 -0
- package/dist/node_modules/oidc-provider/lib/models/mixins/has_grant_id.js +12 -0
- package/dist/node_modules/oidc-provider/lib/models/mixins/has_grant_type.js +8 -0
- package/dist/node_modules/oidc-provider/lib/models/mixins/has_policies.js +38 -0
- package/dist/node_modules/oidc-provider/lib/models/mixins/is_attestation_constrained.js +15 -0
- package/dist/node_modules/oidc-provider/lib/models/mixins/is_sender_constrained.js +50 -0
- package/dist/node_modules/oidc-provider/lib/models/mixins/is_session_bound.js +38 -0
- package/dist/node_modules/oidc-provider/lib/models/mixins/set_audience.js +21 -0
- package/dist/node_modules/oidc-provider/lib/models/mixins/stores_auth.js +16 -0
- package/dist/node_modules/oidc-provider/lib/models/mixins/stores_pkce.js +9 -0
- package/dist/node_modules/oidc-provider/lib/models/pushed_authorization_request.js +21 -0
- package/dist/node_modules/oidc-provider/lib/models/refresh_token.js +47 -0
- package/dist/node_modules/oidc-provider/lib/models/registration_access_token.js +8 -0
- package/dist/node_modules/oidc-provider/lib/models/replay_detection.js +31 -0
- package/dist/node_modules/oidc-provider/lib/models/session.js +192 -0
- package/dist/node_modules/oidc-provider/lib/provider.js +453 -0
- package/dist/node_modules/oidc-provider/lib/response_modes/form_post.js +36 -0
- package/dist/node_modules/oidc-provider/lib/response_modes/fragment.js +7 -0
- package/dist/node_modules/oidc-provider/lib/response_modes/index.js +15 -0
- package/dist/node_modules/oidc-provider/lib/response_modes/jwt.js +43 -0
- package/dist/node_modules/oidc-provider/lib/response_modes/query.js +7 -0
- package/dist/node_modules/oidc-provider/lib/response_modes/web_message.js +55 -0
- package/dist/node_modules/oidc-provider/lib/shared/assemble_params.js +7 -0
- package/dist/node_modules/oidc-provider/lib/shared/attest_client_auth.js +111 -0
- package/dist/node_modules/oidc-provider/lib/shared/authorization_error_handler.js +104 -0
- package/dist/node_modules/oidc-provider/lib/shared/check_rar.js +75 -0
- package/dist/node_modules/oidc-provider/lib/shared/check_resource.js +77 -0
- package/dist/node_modules/oidc-provider/lib/shared/client_auth.js +263 -0
- package/dist/node_modules/oidc-provider/lib/shared/conditional_body.js +9 -0
- package/dist/node_modules/oidc-provider/lib/shared/cors.js +49 -0
- package/dist/node_modules/oidc-provider/lib/shared/error_handler.js +59 -0
- package/dist/node_modules/oidc-provider/lib/shared/jwt_client_auth.js +79 -0
- package/dist/node_modules/oidc-provider/lib/shared/no_cache.js +4 -0
- package/dist/node_modules/oidc-provider/lib/shared/reject_dupes.js +45 -0
- package/dist/node_modules/oidc-provider/lib/shared/reject_structured_tokens.js +18 -0
- package/dist/node_modules/oidc-provider/lib/shared/selective_body.js +60 -0
- package/dist/node_modules/oidc-provider/lib/shared/session.js +68 -0
- package/dist/node_modules/oidc-provider/lib/shared/set_www_authenticate_header.js +52 -0
- package/dist/node_modules/oidc-provider/lib/views/index.js +22 -0
- package/dist/node_modules/oidc-provider/lib/views/interaction.js +171 -0
- package/dist/node_modules/oidc-provider/lib/views/layout.js +237 -0
- package/dist/node_modules/oidc-provider/lib/views/login.js +43 -0
- package/dist/node_modules/oidc-provider/node_modules/@koa/router/LICENSE +21 -0
- package/dist/node_modules/oidc-provider/node_modules/@koa/router/README.md +1370 -0
- package/dist/node_modules/oidc-provider/node_modules/@koa/router/dist/index.d.mts +1003 -0
- package/dist/node_modules/oidc-provider/node_modules/@koa/router/dist/index.d.ts +1003 -0
- package/dist/node_modules/oidc-provider/node_modules/@koa/router/dist/index.js +1616 -0
- package/dist/node_modules/oidc-provider/node_modules/@koa/router/dist/index.mjs +1573 -0
- package/dist/node_modules/oidc-provider/node_modules/@koa/router/package.json +122 -0
- package/dist/node_modules/oidc-provider/node_modules/debug/LICENSE +20 -0
- package/dist/node_modules/oidc-provider/node_modules/debug/README.md +481 -0
- package/dist/node_modules/oidc-provider/node_modules/debug/package.json +64 -0
- package/dist/node_modules/oidc-provider/node_modules/debug/src/browser.js +272 -0
- package/dist/node_modules/oidc-provider/node_modules/debug/src/common.js +292 -0
- package/dist/node_modules/oidc-provider/node_modules/debug/src/index.js +10 -0
- package/dist/node_modules/oidc-provider/node_modules/debug/src/node.js +263 -0
- package/dist/node_modules/oidc-provider/node_modules/http-errors/HISTORY.md +186 -0
- package/dist/node_modules/oidc-provider/node_modules/http-errors/LICENSE +23 -0
- package/dist/node_modules/oidc-provider/node_modules/http-errors/README.md +169 -0
- package/dist/node_modules/oidc-provider/node_modules/http-errors/index.js +290 -0
- package/dist/node_modules/oidc-provider/node_modules/http-errors/package.json +54 -0
- package/dist/node_modules/oidc-provider/node_modules/jsesc/LICENSE-MIT.txt +20 -0
- package/dist/node_modules/oidc-provider/node_modules/jsesc/README.md +422 -0
- package/dist/node_modules/oidc-provider/node_modules/jsesc/bin/jsesc +148 -0
- package/dist/node_modules/oidc-provider/node_modules/jsesc/jsesc.js +337 -0
- package/dist/node_modules/oidc-provider/node_modules/jsesc/man/jsesc.1 +94 -0
- package/dist/node_modules/oidc-provider/node_modules/jsesc/package.json +56 -0
- package/dist/node_modules/oidc-provider/node_modules/nanoid/LICENSE +20 -0
- package/dist/node_modules/oidc-provider/node_modules/nanoid/README.md +38 -0
- package/dist/node_modules/oidc-provider/node_modules/nanoid/bin/nanoid.js +55 -0
- package/dist/node_modules/oidc-provider/node_modules/nanoid/index.browser.js +29 -0
- package/dist/node_modules/oidc-provider/node_modules/nanoid/index.d.ts +106 -0
- package/dist/node_modules/oidc-provider/node_modules/nanoid/index.js +47 -0
- package/dist/node_modules/oidc-provider/node_modules/nanoid/nanoid.js +1 -0
- package/dist/node_modules/oidc-provider/node_modules/nanoid/non-secure/index.d.ts +48 -0
- package/dist/node_modules/oidc-provider/node_modules/nanoid/non-secure/index.js +21 -0
- package/dist/node_modules/oidc-provider/node_modules/nanoid/package.json +46 -0
- package/dist/node_modules/oidc-provider/node_modules/nanoid/url-alphabet/index.js +2 -0
- package/dist/node_modules/oidc-provider/node_modules/path-to-regexp/LICENSE +21 -0
- package/dist/node_modules/oidc-provider/node_modules/path-to-regexp/Readme.md +224 -0
- package/dist/node_modules/oidc-provider/node_modules/path-to-regexp/dist/index.d.ts +144 -0
- package/dist/node_modules/oidc-provider/node_modules/path-to-regexp/dist/index.js +409 -0
- package/dist/node_modules/oidc-provider/node_modules/path-to-regexp/dist/index.js.map +1 -0
- package/dist/node_modules/oidc-provider/node_modules/path-to-regexp/package.json +64 -0
- package/dist/node_modules/oidc-provider/node_modules/statuses/HISTORY.md +87 -0
- package/dist/node_modules/oidc-provider/node_modules/statuses/LICENSE +23 -0
- package/dist/node_modules/oidc-provider/node_modules/statuses/README.md +139 -0
- package/dist/node_modules/oidc-provider/node_modules/statuses/codes.json +65 -0
- package/dist/node_modules/oidc-provider/node_modules/statuses/index.js +146 -0
- package/dist/node_modules/oidc-provider/node_modules/statuses/package.json +49 -0
- package/dist/node_modules/oidc-provider/package.json +95 -0
- package/dist/node_modules/quick-lru/index.d.ts +178 -0
- package/dist/node_modules/quick-lru/index.js +329 -0
- package/dist/node_modules/quick-lru/license +9 -0
- package/dist/node_modules/quick-lru/package.json +54 -0
- package/dist/node_modules/quick-lru/readme.md +236 -0
- package/dist/node_modules/statuses/HISTORY.md +65 -0
- package/dist/node_modules/statuses/LICENSE +23 -0
- package/dist/node_modules/statuses/README.md +127 -0
- package/dist/node_modules/statuses/codes.json +66 -0
- package/dist/node_modules/statuses/index.js +113 -0
- package/dist/node_modules/statuses/package.json +48 -0
- package/dist/server/cache-adapter.d.ts +33 -0
- package/dist/server/cache-adapter.js +159 -0
- package/dist/server/index.d.ts +10 -0
- package/dist/server/index.js +48 -0
- package/dist/server/interaction.d.ts +26 -0
- package/dist/server/interaction.js +172 -0
- package/dist/server/paths.d.ts +19 -0
- package/dist/server/paths.js +64 -0
- package/dist/server/plugin.d.ts +16 -0
- package/dist/server/plugin.js +108 -0
- package/dist/server/provider-dispatch.d.ts +32 -0
- package/dist/server/provider-dispatch.js +252 -0
- package/dist/server/service.d.ts +63 -0
- package/dist/server/service.js +540 -0
- package/dist/server/utils.d.ts +12 -0
- package/dist/server/utils.js +58 -0
- package/package.json +24 -0
- package/server.d.ts +2 -0
- package/server.js +1 -0
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { JOSENotSupported } from '../util/errors.js';
|
|
2
|
+
import { checkSigCryptoKey } from './crypto_key.js';
|
|
3
|
+
import { invalidKeyInput } from './invalid_key_input.js';
|
|
4
|
+
export function checkKeyLength(alg, key) {
|
|
5
|
+
if (alg.startsWith('RS') || alg.startsWith('PS')) {
|
|
6
|
+
const { modulusLength } = key.algorithm;
|
|
7
|
+
if (typeof modulusLength !== 'number' || modulusLength < 2048) {
|
|
8
|
+
throw new TypeError(`${alg} requires key modulusLength to be 2048 bits or larger`);
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
function subtleAlgorithm(alg, algorithm) {
|
|
13
|
+
const hash = `SHA-${alg.slice(-3)}`;
|
|
14
|
+
switch (alg) {
|
|
15
|
+
case 'HS256':
|
|
16
|
+
case 'HS384':
|
|
17
|
+
case 'HS512':
|
|
18
|
+
return { hash, name: 'HMAC' };
|
|
19
|
+
case 'PS256':
|
|
20
|
+
case 'PS384':
|
|
21
|
+
case 'PS512':
|
|
22
|
+
return { hash, name: 'RSA-PSS', saltLength: parseInt(alg.slice(-3), 10) >> 3 };
|
|
23
|
+
case 'RS256':
|
|
24
|
+
case 'RS384':
|
|
25
|
+
case 'RS512':
|
|
26
|
+
return { hash, name: 'RSASSA-PKCS1-v1_5' };
|
|
27
|
+
case 'ES256':
|
|
28
|
+
case 'ES384':
|
|
29
|
+
case 'ES512':
|
|
30
|
+
return { hash, name: 'ECDSA', namedCurve: algorithm.namedCurve };
|
|
31
|
+
case 'Ed25519':
|
|
32
|
+
case 'EdDSA':
|
|
33
|
+
return { name: 'Ed25519' };
|
|
34
|
+
case 'ML-DSA-44':
|
|
35
|
+
case 'ML-DSA-65':
|
|
36
|
+
case 'ML-DSA-87':
|
|
37
|
+
return { name: alg };
|
|
38
|
+
default:
|
|
39
|
+
throw new JOSENotSupported(`alg ${alg} is not supported either by JOSE or your javascript runtime`);
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
async function getSigKey(alg, key, usage) {
|
|
43
|
+
if (key instanceof Uint8Array) {
|
|
44
|
+
if (!alg.startsWith('HS')) {
|
|
45
|
+
throw new TypeError(invalidKeyInput(key, 'CryptoKey', 'KeyObject', 'JSON Web Key'));
|
|
46
|
+
}
|
|
47
|
+
return crypto.subtle.importKey('raw', key, { hash: `SHA-${alg.slice(-3)}`, name: 'HMAC' }, false, [usage]);
|
|
48
|
+
}
|
|
49
|
+
checkSigCryptoKey(key, alg, usage);
|
|
50
|
+
return key;
|
|
51
|
+
}
|
|
52
|
+
export async function sign(alg, key, data) {
|
|
53
|
+
const cryptoKey = await getSigKey(alg, key, 'sign');
|
|
54
|
+
checkKeyLength(alg, cryptoKey);
|
|
55
|
+
const signature = await crypto.subtle.sign(subtleAlgorithm(alg, cryptoKey.algorithm), cryptoKey, data);
|
|
56
|
+
return new Uint8Array(signature);
|
|
57
|
+
}
|
|
58
|
+
export async function verify(alg, key, signature, data) {
|
|
59
|
+
const cryptoKey = await getSigKey(alg, key, 'verify');
|
|
60
|
+
checkKeyLength(alg, cryptoKey);
|
|
61
|
+
const algorithm = subtleAlgorithm(alg, cryptoKey.algorithm);
|
|
62
|
+
try {
|
|
63
|
+
return await crypto.subtle.verify(algorithm, cryptoKey, signature, data);
|
|
64
|
+
}
|
|
65
|
+
catch {
|
|
66
|
+
return false;
|
|
67
|
+
}
|
|
68
|
+
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
const isObjectLike = (value) => typeof value === 'object' && value !== null;
|
|
2
|
+
export function isObject(input) {
|
|
3
|
+
if (!isObjectLike(input) || Object.prototype.toString.call(input) !== '[object Object]') {
|
|
4
|
+
return false;
|
|
5
|
+
}
|
|
6
|
+
if (Object.getPrototypeOf(input) === null) {
|
|
7
|
+
return true;
|
|
8
|
+
}
|
|
9
|
+
let proto = input;
|
|
10
|
+
while (Object.getPrototypeOf(proto) !== null) {
|
|
11
|
+
proto = Object.getPrototypeOf(proto);
|
|
12
|
+
}
|
|
13
|
+
return Object.getPrototypeOf(input) === proto;
|
|
14
|
+
}
|
|
15
|
+
export function isDisjoint(...headers) {
|
|
16
|
+
const sources = headers.filter(Boolean);
|
|
17
|
+
if (sources.length === 0 || sources.length === 1) {
|
|
18
|
+
return true;
|
|
19
|
+
}
|
|
20
|
+
let acc;
|
|
21
|
+
for (const header of sources) {
|
|
22
|
+
const parameters = Object.keys(header);
|
|
23
|
+
if (!acc || acc.size === 0) {
|
|
24
|
+
acc = new Set(parameters);
|
|
25
|
+
continue;
|
|
26
|
+
}
|
|
27
|
+
for (const parameter of parameters) {
|
|
28
|
+
if (acc.has(parameter)) {
|
|
29
|
+
return false;
|
|
30
|
+
}
|
|
31
|
+
acc.add(parameter);
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
return true;
|
|
35
|
+
}
|
|
36
|
+
export const isJWK = (key) => isObject(key) && typeof key.kty === 'string';
|
|
37
|
+
export const isPrivateJWK = (key) => key.kty !== 'oct' &&
|
|
38
|
+
((key.kty === 'AKP' && typeof key.priv === 'string') || typeof key.d === 'string');
|
|
39
|
+
export const isPublicJWK = (key) => key.kty !== 'oct' && key.d === undefined && key.priv === undefined;
|
|
40
|
+
export const isSecretJWK = (key) => key.kty === 'oct' && typeof key.k === 'string';
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export function validateAlgorithms(option, algorithms) {
|
|
2
|
+
if (algorithms !== undefined &&
|
|
3
|
+
(!Array.isArray(algorithms) || algorithms.some((s) => typeof s !== 'string'))) {
|
|
4
|
+
throw new TypeError(`"${option}" option must be an array of strings`);
|
|
5
|
+
}
|
|
6
|
+
if (!algorithms) {
|
|
7
|
+
return undefined;
|
|
8
|
+
}
|
|
9
|
+
return new Set(algorithms);
|
|
10
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { JOSENotSupported, JWEInvalid, JWSInvalid } from '../util/errors.js';
|
|
2
|
+
export function validateCrit(Err, recognizedDefault, recognizedOption, protectedHeader, joseHeader) {
|
|
3
|
+
if (joseHeader.crit !== undefined && protectedHeader?.crit === undefined) {
|
|
4
|
+
throw new Err('"crit" (Critical) Header Parameter MUST be integrity protected');
|
|
5
|
+
}
|
|
6
|
+
if (!protectedHeader || protectedHeader.crit === undefined) {
|
|
7
|
+
return new Set();
|
|
8
|
+
}
|
|
9
|
+
if (!Array.isArray(protectedHeader.crit) ||
|
|
10
|
+
protectedHeader.crit.length === 0 ||
|
|
11
|
+
protectedHeader.crit.some((input) => typeof input !== 'string' || input.length === 0)) {
|
|
12
|
+
throw new Err('"crit" (Critical) Header Parameter MUST be an array of non-empty strings when present');
|
|
13
|
+
}
|
|
14
|
+
let recognized;
|
|
15
|
+
if (recognizedOption !== undefined) {
|
|
16
|
+
recognized = new Map([...Object.entries(recognizedOption), ...recognizedDefault.entries()]);
|
|
17
|
+
}
|
|
18
|
+
else {
|
|
19
|
+
recognized = recognizedDefault;
|
|
20
|
+
}
|
|
21
|
+
for (const parameter of protectedHeader.crit) {
|
|
22
|
+
if (!recognized.has(parameter)) {
|
|
23
|
+
throw new JOSENotSupported(`Extension Header Parameter "${parameter}" is not recognized`);
|
|
24
|
+
}
|
|
25
|
+
if (joseHeader[parameter] === undefined) {
|
|
26
|
+
throw new Err(`Extension Header Parameter "${parameter}" is missing`);
|
|
27
|
+
}
|
|
28
|
+
if (recognized.get(parameter) && protectedHeader[parameter] === undefined) {
|
|
29
|
+
throw new Err(`Extension Header Parameter "${parameter}" MUST be integrity protected`);
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
return new Set(protectedHeader.crit);
|
|
33
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { encoder, decoder } from '../lib/buffer_utils.js';
|
|
2
|
+
import { encodeBase64, decodeBase64 } from '../lib/base64.js';
|
|
3
|
+
export function decode(input) {
|
|
4
|
+
if (Uint8Array.fromBase64) {
|
|
5
|
+
return Uint8Array.fromBase64(typeof input === 'string' ? input : decoder.decode(input), {
|
|
6
|
+
alphabet: 'base64url',
|
|
7
|
+
});
|
|
8
|
+
}
|
|
9
|
+
let encoded = input;
|
|
10
|
+
if (encoded instanceof Uint8Array) {
|
|
11
|
+
encoded = decoder.decode(encoded);
|
|
12
|
+
}
|
|
13
|
+
encoded = encoded.replace(/-/g, '+').replace(/_/g, '/');
|
|
14
|
+
try {
|
|
15
|
+
return decodeBase64(encoded);
|
|
16
|
+
}
|
|
17
|
+
catch {
|
|
18
|
+
throw new TypeError('The input to be decoded is not correctly encoded.');
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
export function encode(input) {
|
|
22
|
+
let unencoded = input;
|
|
23
|
+
if (typeof unencoded === 'string') {
|
|
24
|
+
unencoded = encoder.encode(unencoded);
|
|
25
|
+
}
|
|
26
|
+
if (Uint8Array.prototype.toBase64) {
|
|
27
|
+
return unencoded.toBase64({ alphabet: 'base64url', omitPadding: true });
|
|
28
|
+
}
|
|
29
|
+
return encodeBase64(unencoded).replace(/=/g, '').replace(/\+/g, '-').replace(/\//g, '_');
|
|
30
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { decode as b64u } from './base64url.js';
|
|
2
|
+
import { decoder } from '../lib/buffer_utils.js';
|
|
3
|
+
import { isObject } from '../lib/type_checks.js';
|
|
4
|
+
import { JWTInvalid } from './errors.js';
|
|
5
|
+
export function decodeJwt(jwt) {
|
|
6
|
+
if (typeof jwt !== 'string')
|
|
7
|
+
throw new JWTInvalid('JWTs must use Compact JWS serialization, JWT must be a string');
|
|
8
|
+
const { 1: payload, length } = jwt.split('.');
|
|
9
|
+
if (length === 5)
|
|
10
|
+
throw new JWTInvalid('Only JWTs using Compact JWS serialization can be decoded');
|
|
11
|
+
if (length !== 3)
|
|
12
|
+
throw new JWTInvalid('Invalid JWT');
|
|
13
|
+
if (!payload)
|
|
14
|
+
throw new JWTInvalid('JWTs must contain a payload');
|
|
15
|
+
let decoded;
|
|
16
|
+
try {
|
|
17
|
+
decoded = b64u(payload);
|
|
18
|
+
}
|
|
19
|
+
catch {
|
|
20
|
+
throw new JWTInvalid('Failed to base64url decode the payload');
|
|
21
|
+
}
|
|
22
|
+
let result;
|
|
23
|
+
try {
|
|
24
|
+
result = JSON.parse(decoder.decode(decoded));
|
|
25
|
+
}
|
|
26
|
+
catch {
|
|
27
|
+
throw new JWTInvalid('Failed to parse the decoded payload as JSON');
|
|
28
|
+
}
|
|
29
|
+
if (!isObject(result))
|
|
30
|
+
throw new JWTInvalid('Invalid JWT Claims Set');
|
|
31
|
+
return result;
|
|
32
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { decode as b64u } from './base64url.js';
|
|
2
|
+
import { decoder } from '../lib/buffer_utils.js';
|
|
3
|
+
import { isObject } from '../lib/type_checks.js';
|
|
4
|
+
export function decodeProtectedHeader(token) {
|
|
5
|
+
let protectedB64u;
|
|
6
|
+
if (typeof token === 'string') {
|
|
7
|
+
const parts = token.split('.');
|
|
8
|
+
if (parts.length === 3 || parts.length === 5) {
|
|
9
|
+
;
|
|
10
|
+
[protectedB64u] = parts;
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
else if (typeof token === 'object' && token) {
|
|
14
|
+
if ('protected' in token) {
|
|
15
|
+
protectedB64u = token.protected;
|
|
16
|
+
}
|
|
17
|
+
else {
|
|
18
|
+
throw new TypeError('Token does not contain a Protected Header');
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
try {
|
|
22
|
+
if (typeof protectedB64u !== 'string' || !protectedB64u) {
|
|
23
|
+
throw new Error();
|
|
24
|
+
}
|
|
25
|
+
const result = JSON.parse(decoder.decode(b64u(protectedB64u)));
|
|
26
|
+
if (!isObject(result)) {
|
|
27
|
+
throw new Error();
|
|
28
|
+
}
|
|
29
|
+
return result;
|
|
30
|
+
}
|
|
31
|
+
catch {
|
|
32
|
+
throw new TypeError('Invalid Token or Protected Header formatting');
|
|
33
|
+
}
|
|
34
|
+
}
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
export class JOSEError extends Error {
|
|
2
|
+
static code = 'ERR_JOSE_GENERIC';
|
|
3
|
+
code = 'ERR_JOSE_GENERIC';
|
|
4
|
+
constructor(message, options) {
|
|
5
|
+
super(message, options);
|
|
6
|
+
this.name = this.constructor.name;
|
|
7
|
+
Error.captureStackTrace?.(this, this.constructor);
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
export class JWTClaimValidationFailed extends JOSEError {
|
|
11
|
+
static code = 'ERR_JWT_CLAIM_VALIDATION_FAILED';
|
|
12
|
+
code = 'ERR_JWT_CLAIM_VALIDATION_FAILED';
|
|
13
|
+
claim;
|
|
14
|
+
reason;
|
|
15
|
+
payload;
|
|
16
|
+
constructor(message, payload, claim = 'unspecified', reason = 'unspecified') {
|
|
17
|
+
super(message, { cause: { claim, reason, payload } });
|
|
18
|
+
this.claim = claim;
|
|
19
|
+
this.reason = reason;
|
|
20
|
+
this.payload = payload;
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
export class JWTExpired extends JOSEError {
|
|
24
|
+
static code = 'ERR_JWT_EXPIRED';
|
|
25
|
+
code = 'ERR_JWT_EXPIRED';
|
|
26
|
+
claim;
|
|
27
|
+
reason;
|
|
28
|
+
payload;
|
|
29
|
+
constructor(message, payload, claim = 'unspecified', reason = 'unspecified') {
|
|
30
|
+
super(message, { cause: { claim, reason, payload } });
|
|
31
|
+
this.claim = claim;
|
|
32
|
+
this.reason = reason;
|
|
33
|
+
this.payload = payload;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
export class JOSEAlgNotAllowed extends JOSEError {
|
|
37
|
+
static code = 'ERR_JOSE_ALG_NOT_ALLOWED';
|
|
38
|
+
code = 'ERR_JOSE_ALG_NOT_ALLOWED';
|
|
39
|
+
}
|
|
40
|
+
export class JOSENotSupported extends JOSEError {
|
|
41
|
+
static code = 'ERR_JOSE_NOT_SUPPORTED';
|
|
42
|
+
code = 'ERR_JOSE_NOT_SUPPORTED';
|
|
43
|
+
}
|
|
44
|
+
export class JWEDecryptionFailed extends JOSEError {
|
|
45
|
+
static code = 'ERR_JWE_DECRYPTION_FAILED';
|
|
46
|
+
code = 'ERR_JWE_DECRYPTION_FAILED';
|
|
47
|
+
constructor(message = 'decryption operation failed', options) {
|
|
48
|
+
super(message, options);
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
export class JWEInvalid extends JOSEError {
|
|
52
|
+
static code = 'ERR_JWE_INVALID';
|
|
53
|
+
code = 'ERR_JWE_INVALID';
|
|
54
|
+
}
|
|
55
|
+
export class JWSInvalid extends JOSEError {
|
|
56
|
+
static code = 'ERR_JWS_INVALID';
|
|
57
|
+
code = 'ERR_JWS_INVALID';
|
|
58
|
+
}
|
|
59
|
+
export class JWTInvalid extends JOSEError {
|
|
60
|
+
static code = 'ERR_JWT_INVALID';
|
|
61
|
+
code = 'ERR_JWT_INVALID';
|
|
62
|
+
}
|
|
63
|
+
export class JWKInvalid extends JOSEError {
|
|
64
|
+
static code = 'ERR_JWK_INVALID';
|
|
65
|
+
code = 'ERR_JWK_INVALID';
|
|
66
|
+
}
|
|
67
|
+
export class JWKSInvalid extends JOSEError {
|
|
68
|
+
static code = 'ERR_JWKS_INVALID';
|
|
69
|
+
code = 'ERR_JWKS_INVALID';
|
|
70
|
+
}
|
|
71
|
+
export class JWKSNoMatchingKey extends JOSEError {
|
|
72
|
+
static code = 'ERR_JWKS_NO_MATCHING_KEY';
|
|
73
|
+
code = 'ERR_JWKS_NO_MATCHING_KEY';
|
|
74
|
+
constructor(message = 'no applicable key found in the JSON Web Key Set', options) {
|
|
75
|
+
super(message, options);
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
export class JWKSMultipleMatchingKeys extends JOSEError {
|
|
79
|
+
[Symbol.asyncIterator];
|
|
80
|
+
static code = 'ERR_JWKS_MULTIPLE_MATCHING_KEYS';
|
|
81
|
+
code = 'ERR_JWKS_MULTIPLE_MATCHING_KEYS';
|
|
82
|
+
constructor(message = 'multiple matching keys found in the JSON Web Key Set', options) {
|
|
83
|
+
super(message, options);
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
export class JWKSTimeout extends JOSEError {
|
|
87
|
+
static code = 'ERR_JWKS_TIMEOUT';
|
|
88
|
+
code = 'ERR_JWKS_TIMEOUT';
|
|
89
|
+
constructor(message = 'request timed out', options) {
|
|
90
|
+
super(message, options);
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
export class JWSSignatureVerificationFailed extends JOSEError {
|
|
94
|
+
static code = 'ERR_JWS_SIGNATURE_VERIFICATION_FAILED';
|
|
95
|
+
code = 'ERR_JWS_SIGNATURE_VERIFICATION_FAILED';
|
|
96
|
+
constructor(message = 'signature verification failed', options) {
|
|
97
|
+
super(message, options);
|
|
98
|
+
}
|
|
99
|
+
}
|
|
@@ -0,0 +1,200 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "jose",
|
|
3
|
+
"version": "6.2.1",
|
|
4
|
+
"description": "JWA, JWS, JWE, JWT, JWK, JWKS for Node.js, Browser, Cloudflare Workers, Deno, Bun, and other Web-interoperable runtimes",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"akp",
|
|
7
|
+
"browser",
|
|
8
|
+
"bun",
|
|
9
|
+
"cloudflare",
|
|
10
|
+
"compact",
|
|
11
|
+
"decode",
|
|
12
|
+
"decrypt",
|
|
13
|
+
"deno",
|
|
14
|
+
"detached",
|
|
15
|
+
"ec",
|
|
16
|
+
"ecdsa",
|
|
17
|
+
"ed25519",
|
|
18
|
+
"eddsa",
|
|
19
|
+
"edge",
|
|
20
|
+
"electron",
|
|
21
|
+
"embedded",
|
|
22
|
+
"encrypt",
|
|
23
|
+
"flattened",
|
|
24
|
+
"general",
|
|
25
|
+
"jose",
|
|
26
|
+
"json web token",
|
|
27
|
+
"jsonwebtoken",
|
|
28
|
+
"jwa",
|
|
29
|
+
"jwe",
|
|
30
|
+
"jwk",
|
|
31
|
+
"jwks",
|
|
32
|
+
"jws",
|
|
33
|
+
"jwt-decode",
|
|
34
|
+
"jwt",
|
|
35
|
+
"ml-dsa",
|
|
36
|
+
"netlify",
|
|
37
|
+
"next",
|
|
38
|
+
"nextjs",
|
|
39
|
+
"oct",
|
|
40
|
+
"okp",
|
|
41
|
+
"payload",
|
|
42
|
+
"pem",
|
|
43
|
+
"pkcs8",
|
|
44
|
+
"rsa",
|
|
45
|
+
"sign",
|
|
46
|
+
"signature",
|
|
47
|
+
"spki",
|
|
48
|
+
"validate",
|
|
49
|
+
"vercel",
|
|
50
|
+
"verify",
|
|
51
|
+
"webcrypto",
|
|
52
|
+
"workerd",
|
|
53
|
+
"workers",
|
|
54
|
+
"x509"
|
|
55
|
+
],
|
|
56
|
+
"homepage": "https://github.com/panva/jose",
|
|
57
|
+
"repository": "panva/jose",
|
|
58
|
+
"funding": {
|
|
59
|
+
"url": "https://github.com/sponsors/panva"
|
|
60
|
+
},
|
|
61
|
+
"license": "MIT",
|
|
62
|
+
"author": "Filip Skokan <panva.ip@gmail.com>",
|
|
63
|
+
"sideEffects": false,
|
|
64
|
+
"type": "module",
|
|
65
|
+
"exports": {
|
|
66
|
+
".": {
|
|
67
|
+
"types": "./dist/types/index.d.ts",
|
|
68
|
+
"default": "./dist/webapi/index.js"
|
|
69
|
+
},
|
|
70
|
+
"./jwk/embedded": {
|
|
71
|
+
"types": "./dist/types/jwk/embedded.d.ts",
|
|
72
|
+
"default": "./dist/webapi/jwk/embedded.js"
|
|
73
|
+
},
|
|
74
|
+
"./jwk/thumbprint": {
|
|
75
|
+
"types": "./dist/types/jwk/thumbprint.d.ts",
|
|
76
|
+
"default": "./dist/webapi/jwk/thumbprint.js"
|
|
77
|
+
},
|
|
78
|
+
"./key/import": {
|
|
79
|
+
"types": "./dist/types/key/import.d.ts",
|
|
80
|
+
"default": "./dist/webapi/key/import.js"
|
|
81
|
+
},
|
|
82
|
+
"./key/export": {
|
|
83
|
+
"types": "./dist/types/key/export.d.ts",
|
|
84
|
+
"default": "./dist/webapi/key/export.js"
|
|
85
|
+
},
|
|
86
|
+
"./key/generate/keypair": {
|
|
87
|
+
"types": "./dist/types/key/generate_key_pair.d.ts",
|
|
88
|
+
"default": "./dist/webapi/key/generate_key_pair.js"
|
|
89
|
+
},
|
|
90
|
+
"./key/generate/secret": {
|
|
91
|
+
"types": "./dist/types/key/generate_secret.d.ts",
|
|
92
|
+
"default": "./dist/webapi/key/generate_secret.js"
|
|
93
|
+
},
|
|
94
|
+
"./jwks/remote": {
|
|
95
|
+
"types": "./dist/types/jwks/remote.d.ts",
|
|
96
|
+
"default": "./dist/webapi/jwks/remote.js"
|
|
97
|
+
},
|
|
98
|
+
"./jwks/local": {
|
|
99
|
+
"types": "./dist/types/jwks/local.d.ts",
|
|
100
|
+
"default": "./dist/webapi/jwks/local.js"
|
|
101
|
+
},
|
|
102
|
+
"./jwt/sign": {
|
|
103
|
+
"types": "./dist/types/jwt/sign.d.ts",
|
|
104
|
+
"default": "./dist/webapi/jwt/sign.js"
|
|
105
|
+
},
|
|
106
|
+
"./jwt/verify": {
|
|
107
|
+
"types": "./dist/types/jwt/verify.d.ts",
|
|
108
|
+
"default": "./dist/webapi/jwt/verify.js"
|
|
109
|
+
},
|
|
110
|
+
"./jwt/encrypt": {
|
|
111
|
+
"types": "./dist/types/jwt/encrypt.d.ts",
|
|
112
|
+
"default": "./dist/webapi/jwt/encrypt.js"
|
|
113
|
+
},
|
|
114
|
+
"./jwt/decrypt": {
|
|
115
|
+
"types": "./dist/types/jwt/decrypt.d.ts",
|
|
116
|
+
"default": "./dist/webapi/jwt/decrypt.js"
|
|
117
|
+
},
|
|
118
|
+
"./jwt/unsecured": {
|
|
119
|
+
"types": "./dist/types/jwt/unsecured.d.ts",
|
|
120
|
+
"default": "./dist/webapi/jwt/unsecured.js"
|
|
121
|
+
},
|
|
122
|
+
"./jwt/decode": {
|
|
123
|
+
"types": "./dist/types/util/decode_jwt.d.ts",
|
|
124
|
+
"default": "./dist/webapi/util/decode_jwt.js"
|
|
125
|
+
},
|
|
126
|
+
"./decode/protected_header": {
|
|
127
|
+
"types": "./dist/types/util/decode_protected_header.d.ts",
|
|
128
|
+
"default": "./dist/webapi/util/decode_protected_header.js"
|
|
129
|
+
},
|
|
130
|
+
"./jws/compact/sign": {
|
|
131
|
+
"types": "./dist/types/jws/compact/sign.d.ts",
|
|
132
|
+
"default": "./dist/webapi/jws/compact/sign.js"
|
|
133
|
+
},
|
|
134
|
+
"./jws/compact/verify": {
|
|
135
|
+
"types": "./dist/types/jws/compact/verify.d.ts",
|
|
136
|
+
"default": "./dist/webapi/jws/compact/verify.js"
|
|
137
|
+
},
|
|
138
|
+
"./jws/flattened/sign": {
|
|
139
|
+
"types": "./dist/types/jws/flattened/sign.d.ts",
|
|
140
|
+
"default": "./dist/webapi/jws/flattened/sign.js"
|
|
141
|
+
},
|
|
142
|
+
"./jws/flattened/verify": {
|
|
143
|
+
"types": "./dist/types/jws/flattened/verify.d.ts",
|
|
144
|
+
"default": "./dist/webapi/jws/flattened/verify.js"
|
|
145
|
+
},
|
|
146
|
+
"./jws/general/sign": {
|
|
147
|
+
"types": "./dist/types/jws/general/sign.d.ts",
|
|
148
|
+
"default": "./dist/webapi/jws/general/sign.js"
|
|
149
|
+
},
|
|
150
|
+
"./jws/general/verify": {
|
|
151
|
+
"types": "./dist/types/jws/general/verify.d.ts",
|
|
152
|
+
"default": "./dist/webapi/jws/general/verify.js"
|
|
153
|
+
},
|
|
154
|
+
"./jwe/compact/encrypt": {
|
|
155
|
+
"types": "./dist/types/jwe/compact/encrypt.d.ts",
|
|
156
|
+
"default": "./dist/webapi/jwe/compact/encrypt.js"
|
|
157
|
+
},
|
|
158
|
+
"./jwe/compact/decrypt": {
|
|
159
|
+
"types": "./dist/types/jwe/compact/decrypt.d.ts",
|
|
160
|
+
"default": "./dist/webapi/jwe/compact/decrypt.js"
|
|
161
|
+
},
|
|
162
|
+
"./jwe/flattened/encrypt": {
|
|
163
|
+
"types": "./dist/types/jwe/flattened/encrypt.d.ts",
|
|
164
|
+
"default": "./dist/webapi/jwe/flattened/encrypt.js"
|
|
165
|
+
},
|
|
166
|
+
"./jwe/flattened/decrypt": {
|
|
167
|
+
"types": "./dist/types/jwe/flattened/decrypt.d.ts",
|
|
168
|
+
"default": "./dist/webapi/jwe/flattened/decrypt.js"
|
|
169
|
+
},
|
|
170
|
+
"./jwe/general/encrypt": {
|
|
171
|
+
"types": "./dist/types/jwe/general/encrypt.d.ts",
|
|
172
|
+
"default": "./dist/webapi/jwe/general/encrypt.js"
|
|
173
|
+
},
|
|
174
|
+
"./jwe/general/decrypt": {
|
|
175
|
+
"types": "./dist/types/jwe/general/decrypt.d.ts",
|
|
176
|
+
"default": "./dist/webapi/jwe/general/decrypt.js"
|
|
177
|
+
},
|
|
178
|
+
"./errors": {
|
|
179
|
+
"types": "./dist/types/util/errors.d.ts",
|
|
180
|
+
"default": "./dist/webapi/util/errors.js"
|
|
181
|
+
},
|
|
182
|
+
"./base64url": {
|
|
183
|
+
"types": "./dist/types/util/base64url.d.ts",
|
|
184
|
+
"default": "./dist/webapi/util/base64url.js"
|
|
185
|
+
},
|
|
186
|
+
"./package.json": "./package.json"
|
|
187
|
+
},
|
|
188
|
+
"main": "./dist/webapi/index.js",
|
|
189
|
+
"types": "./dist/types/index.d.ts",
|
|
190
|
+
"files": [
|
|
191
|
+
"dist/webapi/**/*.js",
|
|
192
|
+
"dist/types/**/*.d.ts",
|
|
193
|
+
"!dist/**/*.bundle.js",
|
|
194
|
+
"!dist/**/*.umd.js",
|
|
195
|
+
"!dist/**/*.min.js",
|
|
196
|
+
"!dist/types/runtime/*",
|
|
197
|
+
"!dist/types/lib/*",
|
|
198
|
+
"!dist/deno/**/*"
|
|
199
|
+
]
|
|
200
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
version: 2
|
|
2
|
+
updates:
|
|
3
|
+
- package-ecosystem: "github-actions"
|
|
4
|
+
directory: "/"
|
|
5
|
+
schedule:
|
|
6
|
+
interval: "monthly"
|
|
7
|
+
open-pull-requests-limit: 10
|
|
8
|
+
|
|
9
|
+
- package-ecosystem: "npm"
|
|
10
|
+
directory: "/"
|
|
11
|
+
schedule:
|
|
12
|
+
interval: "monthly"
|
|
13
|
+
open-pull-requests-limit: 10
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# Number of days of inactivity before an issue becomes stale
|
|
2
|
+
daysUntilStale: 15
|
|
3
|
+
# Number of days of inactivity before a stale issue is closed
|
|
4
|
+
daysUntilClose: 7
|
|
5
|
+
# Issues with these labels will never be considered stale
|
|
6
|
+
exemptLabels:
|
|
7
|
+
- "discussion"
|
|
8
|
+
- "feature request"
|
|
9
|
+
- "bug"
|
|
10
|
+
- "help wanted"
|
|
11
|
+
- "plugin suggestion"
|
|
12
|
+
- "good first issue"
|
|
13
|
+
# Label to use when marking an issue as stale
|
|
14
|
+
staleLabel: stale
|
|
15
|
+
# Comment to post when marking an issue as stale. Set to `false` to disable
|
|
16
|
+
markComment: >
|
|
17
|
+
This issue has been automatically marked as stale because it has not had
|
|
18
|
+
recent activity. It will be closed if no further activity occurs. Thank you
|
|
19
|
+
for your contributions.
|
|
20
|
+
# Comment to post when closing a stale issue. Set to `false` to disable
|
|
21
|
+
closeComment: false
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
name: Benchmark PR
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
pull_request_target:
|
|
5
|
+
types:
|
|
6
|
+
- labeled
|
|
7
|
+
|
|
8
|
+
jobs:
|
|
9
|
+
benchmark:
|
|
10
|
+
if: ${{ github.event.label.name == 'benchmark' }}
|
|
11
|
+
uses: fastify/workflows/.github/workflows/plugins-benchmark-pr.yml@v5
|
|
12
|
+
with:
|
|
13
|
+
npm-script: benchmark
|
|
14
|
+
|
|
15
|
+
remove-label:
|
|
16
|
+
if: "always()"
|
|
17
|
+
needs:
|
|
18
|
+
- benchmark
|
|
19
|
+
runs-on: ubuntu-latest
|
|
20
|
+
steps:
|
|
21
|
+
- name: Remove benchmark label
|
|
22
|
+
uses: octokit/request-action@v2.x
|
|
23
|
+
id: remove-label
|
|
24
|
+
with:
|
|
25
|
+
route: DELETE /repos/{repo}/issues/{issue_number}/labels/{name}
|
|
26
|
+
repo: ${{ github.event.pull_request.head.repo.full_name }}
|
|
27
|
+
issue_number: ${{ github.event.pull_request.number }}
|
|
28
|
+
name: benchmark
|
|
29
|
+
env:
|
|
30
|
+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
name: CI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches:
|
|
6
|
+
- main
|
|
7
|
+
- next
|
|
8
|
+
- 'v*'
|
|
9
|
+
paths-ignore:
|
|
10
|
+
- 'docs/**'
|
|
11
|
+
- '*.md'
|
|
12
|
+
pull_request:
|
|
13
|
+
paths-ignore:
|
|
14
|
+
- 'docs/**'
|
|
15
|
+
- '*.md'
|
|
16
|
+
|
|
17
|
+
jobs:
|
|
18
|
+
test:
|
|
19
|
+
uses: fastify/workflows/.github/workflows/plugins-ci.yml@v5
|
|
20
|
+
with:
|
|
21
|
+
fastify-dependency-integration: true
|
|
22
|
+
license-check: true
|
|
23
|
+
lint: true
|