@stripe/extensibility-eslint-plugin 0.15.4 → 0.15.6

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.
Files changed (74) hide show
  1. package/README.md +34 -0
  2. package/dist/api-surface.d.ts.map +1 -0
  3. package/dist/configs/async-with-egress.cjs +11 -0
  4. package/dist/configs/async-with-egress.js +11 -0
  5. package/dist/configs/billing.bill.discount_calculation.cjs +11 -0
  6. package/dist/configs/billing.bill.discount_calculation.js +11 -0
  7. package/dist/configs/billing.customer_balance_application.cjs +11 -0
  8. package/dist/configs/billing.customer_balance_application.js +11 -0
  9. package/dist/configs/billing.invoice_collection_setting.cjs +11 -0
  10. package/dist/configs/billing.invoice_collection_setting.js +11 -0
  11. package/dist/configs/billing.prorations.cjs +11 -0
  12. package/dist/configs/billing.prorations.js +11 -0
  13. package/dist/configs/billing.recurring_billing_item_handling.cjs +11 -0
  14. package/dist/configs/billing.recurring_billing_item_handling.js +11 -0
  15. package/dist/configs/core.workflows.custom_action.cjs +11 -0
  16. package/dist/configs/core.workflows.custom_action.js +11 -0
  17. package/dist/configs/custom-objects.cjs +11 -0
  18. package/dist/configs/custom-objects.js +11 -0
  19. package/dist/configs/extend.objects.custom_objects.cjs +11 -0
  20. package/dist/configs/extend.objects.custom_objects.js +11 -0
  21. package/dist/configs/extend.workflows.custom_action.cjs +11 -0
  22. package/dist/configs/extend.workflows.custom_action.js +11 -0
  23. package/dist/configs/runtime-core.cjs +11 -0
  24. package/dist/configs/runtime-core.js +11 -0
  25. package/dist/configs/sync-no-egress.cjs +11 -0
  26. package/dist/configs/sync-no-egress.js +11 -0
  27. package/dist/index.cjs +11 -0
  28. package/dist/index.d.ts.map +1 -1
  29. package/dist/index.js +11 -0
  30. package/dist/rule-config.d.ts.map +1 -1
  31. package/dist/security-rules/no-secrets.d.ts +13 -0
  32. package/dist/security-rules/no-secrets.d.ts.map +1 -1
  33. package/dist/tsconfig.build.tsbuildinfo +1 -1
  34. package/package.json +3 -3
  35. package/dist/extensibility-eslint-plugin-alpha.d.ts +0 -49
  36. package/dist/extensibility-eslint-plugin-beta.d.ts +0 -49
  37. package/dist/extensibility-eslint-plugin-billing.bill.discount_calculation-alpha.d.ts +0 -11
  38. package/dist/extensibility-eslint-plugin-billing.bill.discount_calculation-beta.d.ts +0 -11
  39. package/dist/extensibility-eslint-plugin-billing.bill.discount_calculation-internal.d.ts +0 -11
  40. package/dist/extensibility-eslint-plugin-billing.bill.discount_calculation-public.d.ts +0 -11
  41. package/dist/extensibility-eslint-plugin-billing.customer_balance_application-alpha.d.ts +0 -11
  42. package/dist/extensibility-eslint-plugin-billing.customer_balance_application-beta.d.ts +0 -11
  43. package/dist/extensibility-eslint-plugin-billing.customer_balance_application-internal.d.ts +0 -11
  44. package/dist/extensibility-eslint-plugin-billing.customer_balance_application-public.d.ts +0 -11
  45. package/dist/extensibility-eslint-plugin-billing.invoice_collection_setting-alpha.d.ts +0 -11
  46. package/dist/extensibility-eslint-plugin-billing.invoice_collection_setting-beta.d.ts +0 -11
  47. package/dist/extensibility-eslint-plugin-billing.invoice_collection_setting-internal.d.ts +0 -11
  48. package/dist/extensibility-eslint-plugin-billing.invoice_collection_setting-public.d.ts +0 -11
  49. package/dist/extensibility-eslint-plugin-billing.prorations-alpha.d.ts +0 -10
  50. package/dist/extensibility-eslint-plugin-billing.prorations-beta.d.ts +0 -10
  51. package/dist/extensibility-eslint-plugin-billing.prorations-internal.d.ts +0 -10
  52. package/dist/extensibility-eslint-plugin-billing.prorations-public.d.ts +0 -10
  53. package/dist/extensibility-eslint-plugin-billing.recurring_billing_item_handling-alpha.d.ts +0 -11
  54. package/dist/extensibility-eslint-plugin-billing.recurring_billing_item_handling-beta.d.ts +0 -11
  55. package/dist/extensibility-eslint-plugin-billing.recurring_billing_item_handling-internal.d.ts +0 -11
  56. package/dist/extensibility-eslint-plugin-billing.recurring_billing_item_handling-public.d.ts +0 -11
  57. package/dist/extensibility-eslint-plugin-core.workflows.custom_action-alpha.d.ts +0 -11
  58. package/dist/extensibility-eslint-plugin-core.workflows.custom_action-beta.d.ts +0 -11
  59. package/dist/extensibility-eslint-plugin-core.workflows.custom_action-internal.d.ts +0 -11
  60. package/dist/extensibility-eslint-plugin-core.workflows.custom_action-public.d.ts +0 -11
  61. package/dist/extensibility-eslint-plugin-custom-objects-alpha.d.ts +0 -11
  62. package/dist/extensibility-eslint-plugin-custom-objects-beta.d.ts +0 -11
  63. package/dist/extensibility-eslint-plugin-custom-objects-internal.d.ts +0 -11
  64. package/dist/extensibility-eslint-plugin-custom-objects-public.d.ts +0 -11
  65. package/dist/extensibility-eslint-plugin-extend.objects.custom_objects-alpha.d.ts +0 -11
  66. package/dist/extensibility-eslint-plugin-extend.objects.custom_objects-beta.d.ts +0 -11
  67. package/dist/extensibility-eslint-plugin-extend.objects.custom_objects-internal.d.ts +0 -11
  68. package/dist/extensibility-eslint-plugin-extend.objects.custom_objects-public.d.ts +0 -11
  69. package/dist/extensibility-eslint-plugin-extend.workflows.custom_action-alpha.d.ts +0 -11
  70. package/dist/extensibility-eslint-plugin-extend.workflows.custom_action-beta.d.ts +0 -11
  71. package/dist/extensibility-eslint-plugin-extend.workflows.custom_action-internal.d.ts +0 -11
  72. package/dist/extensibility-eslint-plugin-extend.workflows.custom_action-public.d.ts +0 -11
  73. package/dist/extensibility-eslint-plugin-internal.d.ts +0 -80
  74. package/dist/extensibility-eslint-plugin-public.d.ts +0 -49
package/dist/index.cjs CHANGED
@@ -36872,6 +36872,16 @@ var originalRule = noSecrets.rules["no-secrets"];
36872
36872
  if (!originalRule) {
36873
36873
  throw new Error("Expected rule 'no-secrets' not found in eslint-plugin-no-secrets");
36874
36874
  }
36875
+ var noSecretsOptions = {
36876
+ tolerance: 5,
36877
+ // High enough to avoid false-positives on normal identifiers.
36878
+ ignoreModules: true,
36879
+ additionalRegexes: {
36880
+ "Stripe Secret Key": "sk_(live|test)_[a-zA-Z0-9]{20,}",
36881
+ "Stripe Restricted Key": "rk_(live|test)_[a-zA-Z0-9]{20,}",
36882
+ "Stripe Webhook Secret": "whsec_[a-zA-Z0-9+/=]{20,}"
36883
+ }
36884
+ };
36875
36885
  var rule16 = {
36876
36886
  ...originalRule,
36877
36887
  meta: {
@@ -37274,6 +37284,7 @@ var _requiredRules = {
37274
37284
  "no-unmodified-loop-condition": "warn",
37275
37285
  "no-constant-condition": "warn",
37276
37286
  "for-direction": "warn",
37287
+ [`${_PLUGIN_NAME}/no-secrets`]: ["error", noSecretsOptions],
37277
37288
  [`${_PLUGIN_NAME}/valid-extension-interface`]: "warn"
37278
37289
  };
37279
37290
  var _recommendedRules = {
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAEH,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AA0B7C;;;GAGG;AACH,eAAO,MAAM,YAAY,wCAAwC,CAAC;AAClE;;;GAGG;AACH,eAAO,MAAM,0BAA0B,OAAO,CAAC;AAE/C;;;GAGG;AACH,eAAO,MAAM,yBAAyB,EAAE,MAAM,CAAC,MAE9C,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,wBAAwB,EAAE,MAAM,CAAC,MAE7C,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,cAAc,EAAE,MAAM,CAAC,WAWnC,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,iBAAiB,EAAE,MAAM,CAAC,WAmBtC,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,YAAY,EAAE,MAAM,CAAC,WAOjC,CAAC;AAIF;;;;;;;GAOG;AACH,QAAA,MAAM,MAAM,EAAE,MAAM,CAAC,MAAM,EAwG1B,CAAC;AAEF,eAAe,MAAM,CAAC;AACtB,OAAO,EAAE,MAAM,IAAI,gBAAgB,EAAE,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAEH,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AA2B7C;;;GAGG;AACH,eAAO,MAAM,YAAY,wCAAwC,CAAC;AAClE;;;GAGG;AACH,eAAO,MAAM,0BAA0B,OAAO,CAAC;AAE/C;;;GAGG;AACH,eAAO,MAAM,yBAAyB,EAAE,MAAM,CAAC,MAE9C,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,wBAAwB,EAAE,MAAM,CAAC,MAE7C,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,cAAc,EAAE,MAAM,CAAC,WAYnC,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,iBAAiB,EAAE,MAAM,CAAC,WAmBtC,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,YAAY,EAAE,MAAM,CAAC,WAOjC,CAAC;AAIF;;;;;;;GAOG;AACH,QAAA,MAAM,MAAM,EAAE,MAAM,CAAC,MAAM,EAwG1B,CAAC;AAEF,eAAe,MAAM,CAAC;AACtB,OAAO,EAAE,MAAM,IAAI,gBAAgB,EAAE,CAAC"}
package/dist/index.js CHANGED
@@ -36860,6 +36860,16 @@ var originalRule = noSecrets.rules["no-secrets"];
36860
36860
  if (!originalRule) {
36861
36861
  throw new Error("Expected rule 'no-secrets' not found in eslint-plugin-no-secrets");
36862
36862
  }
36863
+ var noSecretsOptions = {
36864
+ tolerance: 5,
36865
+ // High enough to avoid false-positives on normal identifiers.
36866
+ ignoreModules: true,
36867
+ additionalRegexes: {
36868
+ "Stripe Secret Key": "sk_(live|test)_[a-zA-Z0-9]{20,}",
36869
+ "Stripe Restricted Key": "rk_(live|test)_[a-zA-Z0-9]{20,}",
36870
+ "Stripe Webhook Secret": "whsec_[a-zA-Z0-9+/=]{20,}"
36871
+ }
36872
+ };
36863
36873
  var rule16 = {
36864
36874
  ...originalRule,
36865
36875
  meta: {
@@ -37262,6 +37272,7 @@ var _requiredRules = {
37262
37272
  "no-unmodified-loop-condition": "warn",
37263
37273
  "no-constant-condition": "warn",
37264
37274
  "for-direction": "warn",
37275
+ [`${_PLUGIN_NAME}/no-secrets`]: ["error", noSecretsOptions],
37265
37276
  [`${_PLUGIN_NAME}/valid-extension-interface`]: "warn"
37266
37277
  };
37267
37278
  var _recommendedRules = {
@@ -1 +1 @@
1
- {"version":3,"file":"rule-config.d.ts","sourceRoot":"","sources":["../src/rule-config.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAG7C;;;GAGG;AACH,eAAO,MAAM,YAAY,kBAAkB,CAAC;AAE5C;;;GAGG;AACH,eAAO,MAAM,yBAAyB,EAAE,MAAM,CAAC,MAE9C,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,cAAc,EAAE,MAAM,CAAC,WAcnC,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,iBAAiB,EAAE,MAAM,CAAC,WAetC,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,YAAY,EAAE,MAAM,CAAC,WAMjC,CAAC"}
1
+ {"version":3,"file":"rule-config.d.ts","sourceRoot":"","sources":["../src/rule-config.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAI7C;;;GAGG;AACH,eAAO,MAAM,YAAY,kBAAkB,CAAC;AAE5C;;;GAGG;AACH,eAAO,MAAM,yBAAyB,EAAE,MAAM,CAAC,MAE9C,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,cAAc,EAAE,MAAM,CAAC,WAenC,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,iBAAiB,EAAE,MAAM,CAAC,WAetC,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,YAAY,EAAE,MAAM,CAAC,WAMjC,CAAC"}
@@ -1,4 +1,17 @@
1
1
  import type { Rule } from 'eslint';
2
+ /**
3
+ * Options for the no-secrets rule. Secrets must go through the secrets injection system.
4
+ * @internal
5
+ */
6
+ export declare const noSecretsOptions: {
7
+ tolerance: number;
8
+ ignoreModules: boolean;
9
+ additionalRegexes: {
10
+ 'Stripe Secret Key': string;
11
+ 'Stripe Restricted Key': string;
12
+ 'Stripe Webhook Secret': string;
13
+ };
14
+ };
2
15
  /**
3
16
  * A wrapper around the community no-secrets ESLint rule that redacts
4
17
  * secret values from error messages. The original rule includes the
@@ -1 +1 @@
1
- {"version":3,"file":"no-secrets.d.ts","sourceRoot":"","sources":["../../src/security-rules/no-secrets.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAYnC;;;;GAIG;AACH,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,UAShB,CAAC;AAEF,eAAe,IAAI,CAAC"}
1
+ {"version":3,"file":"no-secrets.d.ts","sourceRoot":"","sources":["../../src/security-rules/no-secrets.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAYnC;;;GAGG;AACH,eAAO,MAAM,gBAAgB;;;;;;;;CAQ5B,CAAC;AAEF;;;;GAIG;AACH,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,UAShB,CAAC;AAEF,eAAe,IAAI,CAAC"}