@voxgig/sdkgen 4.8.2 → 4.9.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/bin/voxgig-sdkgen +1 -1
- package/dist/action/doctor.d.ts +1 -0
- package/dist/action/doctor.js +50 -2
- package/dist/action/doctor.js.map +1 -1
- package/dist/helpers/naming.js +4 -2
- package/dist/helpers/naming.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/model/sdkgen.aon +21 -0
- package/package.json +1 -1
- package/project/.sdk/model/feature/secrets.aon +120 -18
- package/project/.sdk/model/target/c.aon +10 -0
- package/project/.sdk/model/target/clojure.aon +13 -0
- package/project/.sdk/model/target/cpp.aon +10 -0
- package/project/.sdk/model/target/csharp.aon +9 -0
- package/project/.sdk/model/target/dart.aon +10 -0
- package/project/.sdk/model/target/elixir.aon +9 -0
- package/project/.sdk/model/target/go.aon +13 -0
- package/project/.sdk/model/target/java.aon +9 -0
- package/project/.sdk/model/target/js.aon +7 -0
- package/project/.sdk/model/target/kotlin.aon +9 -0
- package/project/.sdk/model/target/lean.aon +17 -0
- package/project/.sdk/model/target/lua.aon +8 -0
- package/project/.sdk/model/target/ocaml.aon +9 -0
- package/project/.sdk/model/target/perl.aon +8 -0
- package/project/.sdk/model/target/php.aon +8 -0
- package/project/.sdk/model/target/py.aon +13 -0
- package/project/.sdk/model/target/rb.aon +8 -0
- package/project/.sdk/model/target/rust.aon +10 -0
- package/project/.sdk/model/target/scala.aon +21 -2
- package/project/.sdk/model/target/swift.aon +18 -0
- package/project/.sdk/model/target/ts.aon +13 -0
- package/project/.sdk/model/target/zig.aon +9 -0
- package/project/.sdk/src/cmp/clojure/Package_clojure.ts +9 -2
- package/project/.sdk/src/cmp/cpp/Gitignore_cpp.ts +3 -0
- package/project/.sdk/src/cmp/dart/Test_dart.ts +2 -0
- package/project/.sdk/src/cmp/elixir/Package_elixir.ts +4 -1
- package/project/.sdk/src/cmp/go/Config_go.ts +59 -2
- package/project/.sdk/src/cmp/go/Main_go.ts +8 -2
- package/project/.sdk/src/cmp/java/Test_java.ts +6 -5
- package/project/.sdk/src/cmp/kotlin/Test_kotlin.ts +6 -5
- package/project/.sdk/src/cmp/lean/Package_lean.ts +23 -0
- package/project/.sdk/src/cmp/lean/ReadmeInstall_lean.ts +1 -0
- package/project/.sdk/src/cmp/lean/ReadmeTopTest_lean.ts +1 -0
- package/project/.sdk/src/cmp/ocaml/Gitignore_ocaml.ts +1 -0
- package/project/.sdk/src/cmp/ocaml/Main_ocaml.ts +7 -3
- package/project/.sdk/src/cmp/py/Config_py.ts +82 -1
- package/project/.sdk/src/cmp/py/Main_py.ts +44 -0
- package/project/.sdk/src/cmp/py/fragment/Main.fragment.py +2 -0
- package/project/.sdk/src/cmp/swift/Main_swift.ts +10 -0
- package/project/.sdk/src/cmp/swift/Package_swift.ts +13 -1
- package/project/.sdk/src/cmp/ts/Config_ts.ts +42 -17
- package/project/.sdk/src/cmp/ts/fragment/Config.data.fragment.ts +13 -1
- package/project/.sdk/src/cmp/ts/fragment/Config.fragment.ts +13 -1
- package/project/.sdk/src/cmp/zig/Package_zig.ts +15 -11
- package/project/.sdk/src/cmp/zig/fragment/Entity.fragment.zig +3 -3
- package/project/.sdk/src/cmp/zig/fragment/EntityListOp.fragment.zig +3 -3
- package/project/.sdk/src/cmp/zig/fragment/Main.fragment.zig +3 -3
- package/project/.sdk/src/cmp/zig/utility_zig.ts +50 -1
- package/project/.sdk/tm/c/Makefile +38 -3
- package/project/.sdk/tm/c/tests/omni_resolver.h +361 -0
- package/project/.sdk/tm/c/tests/omni_smoke_test.c +237 -0
- package/project/.sdk/tm/c/tests/primary_corpus_test.c +205 -284
- package/project/.sdk/tm/c/tests/struct_corpus_test.c +292 -212
- package/project/.sdk/tm/c/tests/vendor/omni/json.c +811 -0
- package/project/.sdk/tm/c/tests/vendor/omni/omni.h +240 -0
- package/project/.sdk/tm/c/tests/vendor/omni/runner.c +940 -0
- package/project/.sdk/tm/c/tests/vendor/omni/util.c +351 -0
- package/project/.sdk/tm/c/utility/struct/utility.c +7 -2
- package/project/.sdk/tm/clojure/test/sdk/test/omni.clj +401 -0
- package/project/.sdk/tm/clojure/test/sdk/test/omni_smoke.clj +81 -0
- package/project/.sdk/tm/clojure/test/sdk/test/primary.clj +92 -58
- package/project/.sdk/tm/clojure/test/sdk/test/struct_corpus.clj +122 -149
- package/project/.sdk/tm/clojure/test/sdk/test_runner.clj +8 -3
- package/project/.sdk/tm/clojure/test/vendor/omni/voxgig/omni/json.clj +145 -0
- package/project/.sdk/tm/clojure/test/vendor/omni/voxgig/omni/runner.clj +445 -0
- package/project/.sdk/tm/clojure/test/vendor/omni/voxgig/omni/util.clj +145 -0
- package/project/.sdk/tm/cpp/Makefile +5 -1
- package/project/.sdk/tm/cpp/test/omni_resolver.hpp +473 -0
- package/project/.sdk/tm/cpp/test/omni_smoke_test.cpp +209 -0
- package/project/.sdk/tm/cpp/test/primary_utility_test.cpp +243 -184
- package/project/.sdk/tm/cpp/test/runner_support.hpp +68 -181
- package/project/.sdk/tm/cpp/test/struct_corpus_test.cpp +183 -56
- package/project/.sdk/tm/cpp/test/vendor/omni/json.hpp +406 -0
- package/project/.sdk/tm/cpp/test/vendor/omni/omni.hpp +751 -0
- package/project/.sdk/tm/cpp/test/vendor/omni/util.hpp +256 -0
- package/project/.sdk/tm/cpp/utility/pipeline.hpp +7 -1
- package/project/.sdk/tm/csharp/test/OmniResolver.cs +491 -0
- package/project/.sdk/tm/csharp/test/OmniSmokeTest.cs +106 -0
- package/project/.sdk/tm/csharp/test/PrimaryUtilityTest.cs +299 -316
- package/project/.sdk/tm/csharp/test/Runner.cs +104 -269
- package/project/.sdk/tm/csharp/test/StructUtilityTest.cs +535 -724
- package/project/.sdk/tm/csharp/test/vendor/omni/Runner.cs +864 -0
- package/project/.sdk/tm/csharp/test/vendor/omni/Util.cs +347 -0
- package/project/.sdk/tm/csharp/utility/MakeSpec.cs +3 -1
- package/project/.sdk/tm/csharp/utility/PrepareMethod.cs +6 -1
- package/project/.sdk/tm/csharp/utility/struct/Struct.cs +21 -5
- package/project/.sdk/tm/dart/test/omni.dart +520 -0
- package/project/.sdk/tm/dart/test/omni_smoke_test.dart +143 -0
- package/project/.sdk/tm/dart/test/primary_test.dart +86 -28
- package/project/.sdk/tm/dart/test/struct_test.dart +438 -11
- package/project/.sdk/tm/dart/test/vendor/omni/omni.dart +7 -0
- package/project/.sdk/tm/dart/test/vendor/omni/runner.dart +653 -0
- package/project/.sdk/tm/dart/test/vendor/omni/util.dart +232 -0
- package/project/.sdk/tm/elixir/Makefile +11 -3
- package/project/.sdk/tm/elixir/test/omni_smoke_test.exs +117 -0
- package/project/.sdk/tm/elixir/test/primary_utility_test.exs +341 -16
- package/project/.sdk/tm/elixir/test/struct_corpus_test.exs +554 -9
- package/project/.sdk/tm/elixir/test/support/omni.ex +377 -0
- package/project/.sdk/tm/elixir/test/vendor/omni/json.ex +122 -0
- package/project/.sdk/tm/elixir/test/vendor/omni/runner.ex +623 -0
- package/project/.sdk/tm/elixir/test/vendor/omni/util.ex +187 -0
- package/project/.sdk/tm/go/core/context.go +32 -16
- package/project/.sdk/tm/go/feature/secrets/plugin/capability.go +261 -0
- package/project/.sdk/tm/go/feature/secrets/plugin/catalog.go +78 -0
- package/project/.sdk/tm/go/feature/secrets/plugin/config.go +652 -0
- package/project/.sdk/tm/go/feature/secrets/plugin/depend.go +250 -0
- package/project/.sdk/tm/go/feature/secrets/plugin/env.go +194 -0
- package/project/.sdk/tm/go/feature/secrets/plugin/export.go +80 -0
- package/project/.sdk/tm/go/feature/secrets/plugin/graph.go +238 -0
- package/project/.sdk/tm/go/feature/secrets/plugin/host.go +1575 -0
- package/project/.sdk/tm/go/feature/secrets/plugin/order.go +248 -0
- package/project/.sdk/tm/go/feature/secrets/plugin/point.go +184 -0
- package/project/.sdk/tm/go/feature/secrets/plugin/ref.go +123 -0
- package/project/.sdk/tm/go/feature/secrets/plugin/resolve.go +79 -0
- package/project/.sdk/tm/go/feature/secrets/plugin/types.go +296 -0
- package/project/.sdk/tm/go/feature/secrets/plugin/util.go +87 -0
- package/project/.sdk/tm/go/feature/secrets/plugin/version.go +161 -0
- package/project/.sdk/tm/go/feature/secrets/plugins/aws/aws.go +292 -0
- package/project/.sdk/tm/go/feature/secrets/plugins/aws/sigv4.go +201 -0
- package/project/.sdk/tm/go/feature/secrets/plugins/azuresecrets/azuresecrets.go +187 -0
- package/project/.sdk/tm/go/feature/secrets/plugins/boru/boru.go +184 -0
- package/project/.sdk/tm/go/feature/secrets/plugins/doppler/doppler.go +114 -0
- package/project/.sdk/tm/go/feature/secrets/plugins/gcpsecrets/gcpsecrets.go +156 -0
- package/project/.sdk/tm/go/feature/secrets/plugins/hashicorp/hashicorp.go +208 -0
- package/project/.sdk/tm/go/feature/secrets/plugins/httpjson/httpjson.go +241 -0
- package/project/.sdk/tm/go/feature/secrets/plugins/infisical/infisical.go +150 -0
- package/project/.sdk/tm/go/feature/secrets/plugins/onepassword/onepassword.go +152 -0
- package/project/.sdk/tm/go/feature/secrets/plugins/secretspec/secretspec.go +143 -0
- package/project/.sdk/tm/go/feature/secrets/sekreto/addr.go +120 -0
- package/project/.sdk/tm/go/feature/secrets/sekreto/providers.go +442 -0
- package/project/.sdk/tm/go/feature/secrets/sekreto/sekreto.go +714 -0
- package/project/.sdk/tm/go/feature/secrets_feature.go +675 -0
- package/project/.sdk/tm/go/src/feature/secrets/.gitkeep +0 -0
- package/project/.sdk/tm/go/test/feature/secrets/secrets_feature_test.go +799 -0
- package/project/.sdk/tm/go/test/omni/omni.go +902 -0
- package/project/.sdk/tm/go/test/omni/util.go +381 -0
- package/project/.sdk/tm/go/test/omniresolver_test.go +748 -0
- package/project/.sdk/tm/go/test/omnismoke_test.go +112 -0
- package/project/.sdk/tm/go/test/primary_utility_test.go +123 -191
- package/project/.sdk/tm/go/test/struct_utility_test.go +323 -16
- package/project/.sdk/tm/go/test/testsupport_test.go +294 -0
- package/project/.sdk/tm/go/utility/make_options.go +8 -1
- package/project/.sdk/tm/go/utility/prepare_method.go +5 -1
- package/project/.sdk/tm/go/utility/struct/voxgigstruct.go +2 -2
- package/project/.sdk/tm/java/test/OmniResolver.java +355 -0
- package/project/.sdk/tm/java/test/OmniSmokeTest.java +99 -0
- package/project/.sdk/tm/java/test/PrimaryUtilityTest.java +254 -280
- package/project/.sdk/tm/java/test/RunnerSupport.java +9 -194
- package/project/.sdk/tm/java/test/StructCorpusTest.java +119 -42
- package/project/.sdk/tm/java/test/vendor/omni/Json.java +287 -0
- package/project/.sdk/tm/java/test/vendor/omni/Runner.java +851 -0
- package/project/.sdk/tm/java/test/vendor/omni/Util.java +322 -0
- package/project/.sdk/tm/java/utility/MakeSpec.java +3 -1
- package/project/.sdk/tm/java/utility/PrepareMethod.java +5 -5
- package/project/.sdk/tm/java/utility/struct/Struct.java +17 -4
- package/project/.sdk/tm/js/src/utility/StructUtility.js +3 -3
- package/project/.sdk/tm/js/test/omni.js +251 -0
- package/project/.sdk/tm/js/test/omni.test.js +105 -0
- package/project/.sdk/tm/js/test/utility/PrimaryUtility.test.js +6 -2
- package/project/.sdk/tm/js/test/utility/StructUtility.test.js +27 -2
- package/project/.sdk/tm/js/test/vendor/omni/index.js +77 -0
- package/project/.sdk/tm/js/test/vendor/omni/runner.js +628 -0
- package/project/.sdk/tm/js/test/vendor/omni/util.js +229 -0
- package/project/.sdk/tm/kotlin/core/Utility.kt +1 -1
- package/project/.sdk/tm/kotlin/test/OmniResolver.kt +343 -0
- package/project/.sdk/tm/kotlin/test/OmniSmokeTest.kt +100 -0
- package/project/.sdk/tm/kotlin/test/PrimaryUtilityTest.kt +244 -262
- package/project/.sdk/tm/kotlin/test/RunnerSupport.kt +9 -178
- package/project/.sdk/tm/kotlin/test/StructCorpusTest.kt +121 -32
- package/project/.sdk/tm/kotlin/test/vendor/omni/Json.kt +264 -0
- package/project/.sdk/tm/kotlin/test/vendor/omni/Runner.kt +615 -0
- package/project/.sdk/tm/kotlin/test/vendor/omni/Util.kt +139 -0
- package/project/.sdk/tm/kotlin/utility/MakeSpecUrl.kt +6 -3
- package/project/.sdk/tm/kotlin/utility/Prepare.kt +6 -6
- package/project/.sdk/tm/kotlin/utility/struct/Struct.kt +18 -2
- package/project/.sdk/tm/lean/Makefile +12 -5
- package/project/.sdk/tm/lean/src/SdkUtility.lean +14 -1
- package/project/.sdk/tm/lean/test/OmniResolver.lean +358 -0
- package/project/.sdk/tm/lean/test/OmniSmoke.lean +174 -0
- package/project/.sdk/tm/lean/test/StructCorpus.lean +245 -574
- package/project/.sdk/tm/lean/test/TPrimaryUtility.lean +155 -291
- package/project/.sdk/tm/lean/test/vendor/omni/Omni.lean +997 -0
- package/project/.sdk/tm/lua/test/omni.lua +456 -0
- package/project/.sdk/tm/lua/test/omni_smoke_test.lua +103 -0
- package/project/.sdk/tm/lua/test/primary_utility_test.lua +250 -509
- package/project/.sdk/tm/lua/test/struct_utility_test.lua +161 -70
- package/project/.sdk/tm/lua/test/vendor/omni/json.lua +268 -0
- package/project/.sdk/tm/lua/test/vendor/omni/regex.lua +385 -0
- package/project/.sdk/tm/lua/test/vendor/omni/runner.lua +641 -0
- package/project/.sdk/tm/lua/test/vendor/omni/util.lua +282 -0
- package/project/.sdk/tm/lua/utility/prepare_method.lua +5 -1
- package/project/.sdk/tm/lua/utility/struct/regex.lua +663 -0
- package/project/.sdk/tm/lua/utility/struct/struct.lua +660 -420
- package/project/.sdk/tm/ocaml/Makefile +37 -12
- package/project/.sdk/tm/ocaml/test/omni_resolver.ml +284 -0
- package/project/.sdk/tm/ocaml/test/omni_smoke_test.ml +169 -0
- package/project/.sdk/tm/ocaml/test/primary_utility_test.ml +84 -100
- package/project/.sdk/tm/ocaml/test/struct_corpus.ml +225 -201
- package/project/.sdk/tm/ocaml/test/vendor/omni/omni.ml +1157 -0
- package/project/.sdk/tm/perl/lib/Voxgig/Struct.pm +88 -12
- package/project/.sdk/tm/perl/t/omni.pm +647 -0
- package/project/.sdk/tm/perl/t/omni_smoke.t +87 -0
- package/project/.sdk/tm/perl/t/primary_utility.t +189 -487
- package/project/.sdk/tm/perl/t/struct_utility.t +455 -389
- package/project/.sdk/tm/perl/t/vendor/omni/Voxgig/Omni/Runner.pm +649 -0
- package/project/.sdk/tm/perl/t/vendor/omni/Voxgig/Omni/Util.pm +253 -0
- package/project/.sdk/tm/perl/t/vendor/omni/Voxgig/Omni.pm +24 -0
- package/project/.sdk/tm/perl/utility/prepare_method.pm +7 -2
- package/project/.sdk/tm/php/test/Omni.php +691 -0
- package/project/.sdk/tm/php/test/OmniSmokeTest.php +93 -0
- package/project/.sdk/tm/php/test/PrimaryUtilityTest.php +210 -571
- package/project/.sdk/tm/php/test/StructUtilityTest.php +320 -342
- package/project/.sdk/tm/php/test/vendor/omni/Runner.php +644 -0
- package/project/.sdk/tm/php/test/vendor/omni/Util.php +283 -0
- package/project/.sdk/tm/php/utility/MakeSpec.php +10 -3
- package/project/.sdk/tm/php/utility/PrepareBody.php +7 -1
- package/project/.sdk/tm/php/utility/PrepareMethod.php +6 -2
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_plugin/__init__.py +36 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_plugin/capability.py +141 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_plugin/catalog.py +50 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_plugin/config.py +333 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_plugin/depend.py +198 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_plugin/env.py +147 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_plugin/export.py +52 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_plugin/graph.py +139 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_plugin/host.py +1053 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_plugin/order.py +171 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_plugin/point.py +95 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_plugin/ref.py +116 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_plugin/resolve.py +59 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_plugin/types.py +87 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_plugin/version.py +112 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_sekreto/__init__.py +76 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_sekreto/addr.py +116 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_sekreto/plugins/aws.py +192 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_sekreto/plugins/azuresecrets.py +120 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_sekreto/plugins/boru.py +140 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_sekreto/plugins/doppler.py +62 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_sekreto/plugins/gcpsecrets.py +101 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_sekreto/plugins/hashicorp.py +151 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_sekreto/plugins/httpjson.py +115 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_sekreto/plugins/infisical.py +90 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_sekreto/plugins/onepassword.py +101 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_sekreto/plugins/secretspec.py +119 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_sekreto/plugins/sigv4.py +125 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_sekreto/providers.py +211 -0
- package/project/.sdk/tm/py/pkg/feature/secrets/voxgig_sekreto/sekreto.py +475 -0
- package/project/.sdk/tm/py/pkg/feature/secrets_feature.py +467 -0
- package/project/.sdk/tm/py/pkg/utility/prepare_method.py +5 -1
- package/project/.sdk/tm/py/pkg/utility/voxgig_struct/__init__.py +0 -2
- package/project/.sdk/tm/py/pkg/utility/voxgig_struct/voxgig_struct.py +780 -529
- package/project/.sdk/tm/py/src/feature/secrets/.gitkeep +0 -0
- package/project/.sdk/tm/py/test/feature/__init__.py +0 -0
- package/project/.sdk/tm/py/test/feature/secrets/__init__.py +0 -0
- package/project/.sdk/tm/py/test/feature/secrets/test_secrets.py +337 -0
- package/project/.sdk/tm/py/test/omni.py +415 -0
- package/project/.sdk/tm/py/test/test_omni_smoke.py +74 -0
- package/project/.sdk/tm/py/test/test_primary_utility.py +144 -668
- package/project/.sdk/tm/py/test/test_struct_utility.py +74 -27
- package/project/.sdk/tm/py/test/voxgig_omni/__init__.py +62 -0
- package/project/.sdk/tm/py/test/voxgig_omni/runner.py +580 -0
- package/project/.sdk/tm/py/test/voxgig_omni/util.py +252 -0
- package/project/.sdk/tm/rb/test/omni.rb +505 -0
- package/project/.sdk/tm/rb/test/omni_smoke_test.rb +72 -0
- package/project/.sdk/tm/rb/test/primary_utility_test.rb +174 -560
- package/project/.sdk/tm/rb/test/struct_utility_test.rb +13 -7
- package/project/.sdk/tm/rb/test/vendor/omni/runner.rb +493 -0
- package/project/.sdk/tm/rb/test/vendor/omni/util.rb +199 -0
- package/project/.sdk/tm/rb/test/vendor/omni/voxgig_omni.rb +15 -0
- package/project/.sdk/tm/rb/utility/prepare_method.rb +5 -1
- package/project/.sdk/tm/rust/tests/common/mod.rs +19 -242
- package/project/.sdk/tm/rust/tests/omni_resolver/mod.rs +888 -0
- package/project/.sdk/tm/rust/tests/omni_smoke_test.rs +286 -0
- package/project/.sdk/tm/rust/tests/primary_utility_test.rs +318 -312
- package/project/.sdk/tm/rust/tests/struct_utility_test.rs +66 -28
- package/project/.sdk/tm/rust/tests/vendor/omni/json.rs +412 -0
- package/project/.sdk/tm/rust/tests/vendor/omni/mod.rs +38 -0
- package/project/.sdk/tm/rust/tests/vendor/omni/regex.rs +392 -0
- package/project/.sdk/tm/rust/tests/vendor/omni/runner.rs +1001 -0
- package/project/.sdk/tm/rust/tests/vendor/omni/util.rs +161 -0
- package/project/.sdk/tm/rust/utility/prepare_method.rs +5 -1
- package/project/.sdk/tm/scala/Makefile +16 -6
- package/project/.sdk/tm/scala/sdktest/OmniResolver.scala +497 -0
- package/project/.sdk/tm/scala/sdktest/OmniSmoke.scala +192 -0
- package/project/.sdk/tm/scala/sdktest/PrimaryCorpus.scala +47 -19
- package/project/.sdk/tm/scala/sdktest/StructCorpus.scala +0 -0
- package/project/.sdk/tm/scala/sdktest/vendor/omni/Json.scala +229 -0
- package/project/.sdk/tm/scala/sdktest/vendor/omni/Runner.scala +552 -0
- package/project/.sdk/tm/scala/sdktest/vendor/omni/Util.scala +104 -0
- package/project/.sdk/tm/swift/Sources/ProjectNameSDK/Struct/Constants.swift +10 -0
- package/project/.sdk/tm/swift/Sources/ProjectNameSDK/Struct/Inject.swift +28 -5
- package/project/.sdk/tm/swift/Sources/ProjectNameSDK/Struct/Injection.swift +5 -1
- package/project/.sdk/tm/swift/Sources/ProjectNameSDK/Struct/Minor.swift +4 -1
- package/project/.sdk/tm/swift/Sources/ProjectNameSDK/Struct/Validate.swift +15 -5
- package/project/.sdk/tm/swift/Sources/ProjectNameSDK/utility/Prepare.swift +6 -1
- package/project/.sdk/tm/swift/Tests/ProjectNameSDKTests/OmniResolver.swift +474 -0
- package/project/.sdk/tm/swift/Tests/ProjectNameSDKTests/OmniSmokeTest.swift +107 -0
- package/project/.sdk/tm/swift/Tests/ProjectNameSDKTests/PrimaryUtilityTest.swift +141 -178
- package/project/.sdk/tm/swift/Tests/ProjectNameSDKTests/Runner.swift +17 -113
- package/project/.sdk/tm/swift/Tests/ProjectNameSDKTests/StructUtilityTest.swift +295 -446
- package/project/.sdk/tm/swift/Tests/vendor/omni/Json.swift +364 -0
- package/project/.sdk/tm/swift/Tests/vendor/omni/Runner.swift +730 -0
- package/project/.sdk/tm/swift/Tests/vendor/omni/Util.swift +162 -0
- package/project/.sdk/tm/ts/src/feature/secrets/SecretsFeature.ts +7 -0
- package/project/.sdk/tm/ts/src/feature/secrets/plugin/Capability.ts +148 -0
- package/project/.sdk/tm/ts/src/feature/secrets/plugin/Catalog.ts +55 -0
- package/project/.sdk/tm/ts/src/feature/secrets/plugin/Config.ts +344 -0
- package/project/.sdk/tm/ts/src/feature/secrets/plugin/Depend.ts +205 -0
- package/project/.sdk/tm/ts/src/feature/secrets/plugin/Env.ts +138 -0
- package/project/.sdk/tm/ts/src/feature/secrets/plugin/Export.ts +46 -0
- package/project/.sdk/tm/ts/src/feature/secrets/plugin/FeatureHost.ts +349 -0
- package/project/.sdk/tm/ts/src/feature/secrets/plugin/Graph.ts +181 -0
- package/project/.sdk/tm/ts/src/feature/secrets/plugin/Host.ts +1132 -0
- package/project/.sdk/tm/ts/src/feature/secrets/plugin/Order.ts +177 -0
- package/project/.sdk/tm/ts/src/feature/secrets/plugin/Point.ts +119 -0
- package/project/.sdk/tm/ts/src/feature/secrets/plugin/Ref.ts +102 -0
- package/project/.sdk/tm/ts/src/feature/secrets/plugin/Resolve.ts +61 -0
- package/project/.sdk/tm/ts/src/feature/secrets/plugin/Types.ts +112 -0
- package/project/.sdk/tm/ts/src/feature/secrets/plugin/Version.ts +100 -0
- package/project/.sdk/tm/ts/src/feature/secrets/plugin/index.ts +37 -0
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/Sekreto.ts +163 -30
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/index.ts +27 -22
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/{provider → plugins}/aws.ts +26 -36
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/{provider → plugins}/azuresecrets.ts +19 -21
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/{provider → plugins}/boru.ts +36 -17
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/{provider → plugins}/doppler.ts +14 -21
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/{provider → plugins}/gcpsecrets.ts +27 -27
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/{provider → plugins}/hashicorp.ts +25 -39
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/plugins/httpjson.ts +99 -0
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/{provider → plugins}/infisical.ts +14 -16
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/{provider → plugins}/onepassword.ts +15 -22
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/plugins/secretspec.ts +98 -0
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/{Sigv4.ts → plugins/sigv4.ts} +7 -6
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/provider/addr.ts +97 -23
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/provider/builtin.ts +37 -0
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/provider/dotenv.ts +4 -17
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/provider/env.ts +4 -16
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/provider/file.ts +11 -25
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/provider/memory.ts +6 -23
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/provider/support.ts +106 -39
- package/project/.sdk/tm/ts/src/utility/StructUtility.ts +3 -3
- package/project/.sdk/tm/ts/test/omni.ts +104 -32
- package/project/.sdk/tm/ts/test/utility/StructUtility.test.ts +27 -0
- package/project/.sdk/tm/ts/test/vendor/omni/Runner.ts +32 -5
- package/project/.sdk/tm/ts/test/vendor/omni/Util.ts +2 -2
- package/project/.sdk/tm/ts/test/vendor/omni/index.ts +2 -2
- package/project/.sdk/tm/zig/Makefile +15 -1
- package/project/.sdk/tm/zig/build.zig +23 -5
- package/project/.sdk/tm/zig/core/helpers.zig +52 -11
- package/project/.sdk/tm/zig/core/mem.zig +17 -1
- package/project/.sdk/tm/zig/core/utility.zig +23 -19
- package/project/.sdk/tm/zig/feature/audit.zig +2 -2
- package/project/.sdk/tm/zig/feature/cache.zig +2 -2
- package/project/.sdk/tm/zig/feature/debug.zig +5 -5
- package/project/.sdk/tm/zig/feature/netsim.zig +2 -2
- package/project/.sdk/tm/zig/feature/paging.zig +2 -2
- package/project/.sdk/tm/zig/feature/proxy.zig +15 -8
- package/project/.sdk/tm/zig/feature/streaming.zig +5 -5
- package/project/.sdk/tm/zig/feature/support.zig +3 -3
- package/project/.sdk/tm/zig/feature/telemetry.zig +5 -5
- package/project/.sdk/tm/zig/feature/test.zig +10 -5
- package/project/.sdk/tm/zig/test/fh.zig +10 -10
- package/project/.sdk/tm/zig/test/gotcha_test.zig +5 -5
- package/project/.sdk/tm/zig/test/omniresolver.zig +515 -0
- package/project/.sdk/tm/zig/test/omnismoke_test.zig +284 -0
- package/project/.sdk/tm/zig/test/pipeline_test.zig +8 -8
- package/project/.sdk/tm/zig/test/primary_utility_test.zig +145 -155
- package/project/.sdk/tm/zig/test/struct_corpus.zig +264 -187
- package/project/.sdk/tm/zig/test/vendor/omni/omni.zig +1314 -0
- package/project/.sdk/tm/zig/test/vendor/omni/regex.zig +446 -0
- package/project/.sdk/tm/zig/utility/voxgigstruct/regex.zig +7 -4
- package/project/.sdk/tm/zig/utility/voxgigstruct/struct.zig +356 -157
- package/project/sdkgen-package.json +1 -1
- package/src/action/doctor.ts +66 -2
- package/src/helpers/naming.ts +4 -2
- package/project/.sdk/tm/c/tests/runner.h +0 -274
- package/project/.sdk/tm/cpp/test/struct_runner.hpp +0 -314
- package/project/.sdk/tm/csharp/test/StructRunner.cs +0 -276
- package/project/.sdk/tm/dart/test/runner.dart +0 -406
- package/project/.sdk/tm/dart/test/struct_corpus.dart +0 -531
- package/project/.sdk/tm/elixir/test/support/struct_corpus.ex +0 -1088
- package/project/.sdk/tm/go/test/runner_test.go +0 -629
- package/project/.sdk/tm/go/test/struct_runner_test.go +0 -1094
- package/project/.sdk/tm/java/test/StructRunner.java +0 -281
- package/project/.sdk/tm/js/test/runner.js +0 -387
- package/project/.sdk/tm/kotlin/test/StructRunner.kt +0 -177
- package/project/.sdk/tm/lua/test/struct_runner.lua +0 -602
- package/project/.sdk/tm/ocaml/test/corpus_runner.ml +0 -185
- package/project/.sdk/tm/perl/t/struct_runner.pm +0 -275
- package/project/.sdk/tm/php/test/StructRunner.php +0 -275
- package/project/.sdk/tm/py/test/struct_runner.py +0 -411
- package/project/.sdk/tm/rb/test/struct_runner.rb +0 -309
- package/project/.sdk/tm/rust/tests/struct_runner/mod.rs +0 -424
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/provider/Registry.ts +0 -90
- package/project/.sdk/tm/ts/src/feature/secrets/sekreto/provider/http.ts +0 -66
- package/project/.sdk/tm/ts/test/vendor/omni/compat.ts +0 -188
- package/project/.sdk/tm/zig/test/struct_runner.zig +0 -464
|
@@ -1,12 +1,25 @@
|
|
|
1
|
-
// VENDORED: @voxgig/sekreto 0.
|
|
2
|
-
// Source: https://github.com/voxgig/sekreto @
|
|
1
|
+
// VENDORED: @voxgig/sekreto 0.2.0 (typescript/plugins/gcpsecrets.ts)
|
|
2
|
+
// Source: https://github.com/voxgig/sekreto @ 86ba35a646e68a311bdece43cd5689369ca62e9d [tag: sdk-20260907-0029-0]
|
|
3
3
|
// License: MIT (c) voxgig - see repository LICENSE. Do not edit: resync from upstream.
|
|
4
4
|
/* Copyright (c) 2025 Voxgig Ltd, MIT License */
|
|
5
5
|
|
|
6
|
-
import {
|
|
7
|
-
|
|
8
|
-
|
|
6
|
+
import {
|
|
7
|
+
ProviderSpec, Provider, SekretoError, flatname, providerplugin, unbase64,
|
|
8
|
+
} from '../provider/support'
|
|
9
|
+
import { checkaddr } from '../provider/addr'
|
|
10
|
+
import { fetchjson } from './httpjson'
|
|
9
11
|
|
|
12
|
+
/** GCP Secret Manager.
|
|
13
|
+
*
|
|
14
|
+
* `api.token` reads secret `api_token` (dots flattened to `_`; Secret
|
|
15
|
+
* Manager ids have no hierarchy and reject dots), latest version. The
|
|
16
|
+
* token comes from config, then `GOOGLE_OAUTH_ACCESS_TOKEN`, then the
|
|
17
|
+
* GCE/GKE metadata server - so on Google's own platform no credential
|
|
18
|
+
* configuration is needed at all.
|
|
19
|
+
*
|
|
20
|
+
* The metadata call itself is plain http to a link-local host by
|
|
21
|
+
* platform design; no credential rides on it, so `checkaddr` guards the
|
|
22
|
+
* Secret Manager address instead. */
|
|
10
23
|
export function gcpsecretsprovider(options?: {
|
|
11
24
|
project?: string
|
|
12
25
|
token?: string
|
|
@@ -88,31 +101,18 @@ export function gcpsecretsprovider(options?: {
|
|
|
88
101
|
return undefined
|
|
89
102
|
}
|
|
90
103
|
|
|
91
|
-
|
|
104
|
+
const decoded = unbase64(data)
|
|
105
|
+
if (undefined === decoded) {
|
|
106
|
+
throw new SekretoError('sekreto: gcp: undecodable secret')
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
return decoded
|
|
92
110
|
},
|
|
93
111
|
describe: () => 'gcpsecrets:' + (opts.project || ''),
|
|
94
112
|
}
|
|
95
113
|
}
|
|
96
114
|
|
|
97
|
-
/** Azure Key Vault.
|
|
98
|
-
*
|
|
99
|
-
* `api.token` reads secret `api-token` (dots flattened to `-`; Key
|
|
100
|
-
* Vault names allow nothing else), current version. The token comes
|
|
101
|
-
* from config, then a client-credentials login when tenant/clientid/
|
|
102
|
-
* clientsecret are given, then the IMDS managed-identity endpoint - so
|
|
103
|
-
* on Azure's own platform no credential configuration is needed.
|
|
104
|
-
*
|
|
105
|
-
* As with GCP, the IMDS call is plain http to a link-local host by
|
|
106
|
-
* platform design and carries no credential; the login and vault
|
|
107
|
-
* addresses are `checkaddr`-guarded. */
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
// Registering at import is what makes this module's presence the only
|
|
111
|
-
// thing that decides whether the kind exists in a build.
|
|
112
|
-
import { register } from './Registry'
|
|
113
115
|
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
define: (spec: ProviderSpec) => gcpsecretsprovider(spec),
|
|
118
|
-
})
|
|
116
|
+
/** The plugin. Needs HTTPS. */
|
|
117
|
+
export const gcpsecrets = providerplugin('gcpsecrets', (spec: ProviderSpec) =>
|
|
118
|
+
gcpsecretsprovider(spec))
|
|
@@ -1,12 +1,28 @@
|
|
|
1
|
-
// VENDORED: @voxgig/sekreto 0.
|
|
2
|
-
// Source: https://github.com/voxgig/sekreto @
|
|
1
|
+
// VENDORED: @voxgig/sekreto 0.2.0 (typescript/plugins/hashicorp.ts)
|
|
2
|
+
// Source: https://github.com/voxgig/sekreto @ 86ba35a646e68a311bdece43cd5689369ca62e9d [tag: sdk-20260907-0029-0]
|
|
3
3
|
// License: MIT (c) voxgig - see repository LICENSE. Do not edit: resync from upstream.
|
|
4
4
|
/* Copyright (c) 2025 Voxgig Ltd, MIT License */
|
|
5
5
|
|
|
6
|
-
import {
|
|
7
|
-
|
|
8
|
-
|
|
6
|
+
import {
|
|
7
|
+
ProviderSpec, Provider, SekretoError, nodemod, providerplugin, vaultref,
|
|
8
|
+
} from '../provider/support'
|
|
9
|
+
import { checkaddr } from '../provider/addr'
|
|
10
|
+
import { fetchjson } from './httpjson'
|
|
9
11
|
|
|
12
|
+
/** HashiCorp Vault.
|
|
13
|
+
*
|
|
14
|
+
* KV v2 (the default): `api.token` reads `{addr}/v1/{mount}/data/api`
|
|
15
|
+
* and takes the `token` field of `data.data`. KV v1 (`kv: 1`) reads
|
|
16
|
+
* `{addr}/v1/{mount}/api` and takes the field of `data`. A 404 means
|
|
17
|
+
* "not here" - a miss - so a vault can sit in a chain with fallbacks.
|
|
18
|
+
*
|
|
19
|
+
* A Vault Enterprise namespace rides the X-Vault-Namespace header, on
|
|
20
|
+
* logins as well as reads.
|
|
21
|
+
*
|
|
22
|
+
* Instead of being handed a token, the provider can log in: Kubernetes
|
|
23
|
+
* auth (the pod's service-account JWT, from its conventional path) or
|
|
24
|
+
* AppRole. A failed login is an error, never a miss - it means this
|
|
25
|
+
* store could not answer at all. */
|
|
10
26
|
export function hashicorpprovider(
|
|
11
27
|
addr: string,
|
|
12
28
|
token: string,
|
|
@@ -117,43 +133,13 @@ export function hashicorpprovider(
|
|
|
117
133
|
}
|
|
118
134
|
}
|
|
119
135
|
|
|
120
|
-
/** A boru vault (https://github.com/boru-lang/boru).
|
|
121
|
-
*
|
|
122
|
-
* Two ways in, both boru's own.
|
|
123
|
-
*
|
|
124
|
-
* With no `addr`, the CLI: `boru vault get --reveal <alias>` prints the
|
|
125
|
-
* secret on stdout and nothing else. The passphrase is read by boru
|
|
126
|
-
* itself from `BORU_VAULT_PASSPHRASE`; sekreto never accepts it as
|
|
127
|
-
* config and never puts it on a command line, where it would show up in
|
|
128
|
-
* the process table.
|
|
129
|
-
*
|
|
130
|
-
* With an `addr`, boru's wire protocol: `boru vault serve` publishes a
|
|
131
|
-
* read-only, HashiCorp-shaped provision API (boru's
|
|
132
|
-
* design/VAULT-WIRE-PROTOCOL.0.md), authenticated by a capability token
|
|
133
|
-
* from `boru vault grant`. A sekreto name is already a valid boru
|
|
134
|
-
* alias, and boru aliases keep their dots, so `api.token` is the single
|
|
135
|
-
* path segment `api.token` - not the `api`/`token` split a HashiCorp KV
|
|
136
|
-
* gets. The value is the `value` field. A 404 is a miss; anything else
|
|
137
|
-
* the server refuses (a revoked capability, a sealed vault) is an
|
|
138
|
-
* error.
|
|
139
|
-
*
|
|
140
|
-
* boru's `vault proxy` and `vault mcp` remain out of bounds: they are a
|
|
141
|
-
* credential *broker*, built precisely so the caller never receives the
|
|
142
|
-
* credential. `vault serve` is the provision endpoint, built to hand
|
|
143
|
-
* the value back - that is the one sekreto uses. */
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
// Registering at import is what makes this module's presence the only
|
|
147
|
-
// thing that decides whether the kind exists in a build.
|
|
148
|
-
import { register } from './Registry'
|
|
149
136
|
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
define: (spec: ProviderSpec) => hashicorpprovider(spec.addr || '', spec.token || '', {
|
|
137
|
+
/** The plugin. Needs HTTPS, and the filesystem for a kubernetes JWT. */
|
|
138
|
+
export const hashicorp = providerplugin('hashicorp', (spec: ProviderSpec) =>
|
|
139
|
+
hashicorpprovider(spec.addr || '', spec.token || '', {
|
|
154
140
|
mount: spec.mount,
|
|
155
141
|
kv: spec.kv,
|
|
156
142
|
vaultnamespace: spec.vaultnamespace,
|
|
157
143
|
auth: spec.auth,
|
|
158
144
|
}),
|
|
159
|
-
|
|
145
|
+
)
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
// VENDORED: @voxgig/sekreto 0.2.0 (typescript/plugins/httpjson.ts)
|
|
2
|
+
// Source: https://github.com/voxgig/sekreto @ 86ba35a646e68a311bdece43cd5689369ca62e9d [tag: sdk-20260907-0029-0]
|
|
3
|
+
// License: MIT (c) voxgig - see repository LICENSE. Do not edit: resync from upstream.
|
|
4
|
+
/* Copyright (c) 2025 Voxgig Ltd, MIT License */
|
|
5
|
+
|
|
6
|
+
import { SekretoError } from '../provider/support'
|
|
7
|
+
|
|
8
|
+
/** How long any single vault round-trip may take before it is treated as
|
|
9
|
+
* unreachable. Ports carry the same bound. */
|
|
10
|
+
const HTTP_TIMEOUT_MS = 10000
|
|
11
|
+
|
|
12
|
+
/** How much of a response body will be read before the store is treated as
|
|
13
|
+
* having answered incoherently. Ports carry the same bound.
|
|
14
|
+
*
|
|
15
|
+
* Far above anything real. The largest legitimate payload this library
|
|
16
|
+
* fetches is Doppler's whole-config download, measured in kilobytes; a
|
|
17
|
+
* megabyte would do. Eight is chosen so that no honest store can meet it
|
|
18
|
+
* and the check never has to be reasoned about again.
|
|
19
|
+
*
|
|
20
|
+
* A bound is needed because the timeout is not one. Ten seconds on a
|
|
21
|
+
* loopback or datacentre link is gigabytes, and the body is accumulated
|
|
22
|
+
* in memory before it is parsed — measured at 3.2 GB in one port before
|
|
23
|
+
* this. Worse where a client advertises gzip and decompresses
|
|
24
|
+
* transparently, since a few hundred kilobytes of zeros expands to
|
|
25
|
+
* gigabytes in the client's heap. This is a secrets chain running on an
|
|
26
|
+
* application's startup path, so the failure is the application never
|
|
27
|
+
* starting. */
|
|
28
|
+
const HTTP_MAXBODY = 8 * 1024 * 1024
|
|
29
|
+
|
|
30
|
+
/** One JSON round-trip. Network failure is always an error - an
|
|
31
|
+
* unreachable store is a store that could not answer.
|
|
32
|
+
*
|
|
33
|
+
* Shared by every plugin that speaks HTTP, and by nothing in the core:
|
|
34
|
+
* a chain of built-ins never reaches this file. */
|
|
35
|
+
export async function fetchjson(
|
|
36
|
+
method: string,
|
|
37
|
+
url: string,
|
|
38
|
+
headers: Record<string, string>,
|
|
39
|
+
body?: string,
|
|
40
|
+
): Promise<{ status: number; body: any }> {
|
|
41
|
+
let res: Response
|
|
42
|
+
try {
|
|
43
|
+
res = await fetch(url, {
|
|
44
|
+
method,
|
|
45
|
+
headers,
|
|
46
|
+
body,
|
|
47
|
+
// A vault API never legitimately redirects, and a followed redirect
|
|
48
|
+
// carries X-Vault-Token to the redirect's host (and can downgrade
|
|
49
|
+
// https to http), which checkaddr - it only validates the configured
|
|
50
|
+
// address - cannot see. Refuse to follow one.
|
|
51
|
+
redirect: 'error',
|
|
52
|
+
// Bound the wait so an accepted-but-silent endpoint cannot hang the
|
|
53
|
+
// caller (and the app's startup) forever.
|
|
54
|
+
signal: AbortSignal.timeout(HTTP_TIMEOUT_MS),
|
|
55
|
+
})
|
|
56
|
+
} catch (err: any) {
|
|
57
|
+
throw new SekretoError('sekreto: cannot reach ' + url.split('?')[0] + ': ' + err.message)
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
// Read in chunks against HTTP_MAXBODY rather than `res.json()`, which
|
|
61
|
+
// buffers whatever arrives. Over the bound the request is aborted and
|
|
62
|
+
// the store has failed: an endless body is a store that could not
|
|
63
|
+
// answer, and returning a miss there would fall through to a weaker
|
|
64
|
+
// store on an attacker's cue.
|
|
65
|
+
let text = ''
|
|
66
|
+
try {
|
|
67
|
+
const decoder = new TextDecoder()
|
|
68
|
+
let size = 0
|
|
69
|
+
|
|
70
|
+
for await (const chunk of res.body ?? []) {
|
|
71
|
+
size += chunk.length
|
|
72
|
+
if (HTTP_MAXBODY < size) {
|
|
73
|
+
throw new SekretoError('sekreto: oversized response from ' + url.split('?')[0])
|
|
74
|
+
}
|
|
75
|
+
text += decoder.decode(chunk, { stream: true })
|
|
76
|
+
}
|
|
77
|
+
text += decoder.decode()
|
|
78
|
+
} catch (err: any) {
|
|
79
|
+
if (err instanceof SekretoError) {
|
|
80
|
+
throw err
|
|
81
|
+
}
|
|
82
|
+
throw new SekretoError('sekreto: cannot reach ' + url.split('?')[0] + ': ' + err.message)
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
let parsed: any = undefined
|
|
86
|
+
try {
|
|
87
|
+
parsed = JSON.parse(text)
|
|
88
|
+
} catch (err: any) {
|
|
89
|
+
// A success status promised JSON; a body that does not parse means
|
|
90
|
+
// the store could not answer coherently, and treating it as a miss
|
|
91
|
+
// would fall through to a weaker store. Error statuses may carry
|
|
92
|
+
// any body - they are decided on status alone.
|
|
93
|
+
if (200 === res.status) {
|
|
94
|
+
throw new SekretoError('sekreto: malformed response from ' + url.split('?')[0])
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
return { status: res.status, body: parsed }
|
|
99
|
+
}
|
|
@@ -1,12 +1,18 @@
|
|
|
1
|
-
// VENDORED: @voxgig/sekreto 0.
|
|
2
|
-
// Source: https://github.com/voxgig/sekreto @
|
|
1
|
+
// VENDORED: @voxgig/sekreto 0.2.0 (typescript/plugins/infisical.ts)
|
|
2
|
+
// Source: https://github.com/voxgig/sekreto @ 86ba35a646e68a311bdece43cd5689369ca62e9d [tag: sdk-20260907-0029-0]
|
|
3
3
|
// License: MIT (c) voxgig - see repository LICENSE. Do not edit: resync from upstream.
|
|
4
4
|
/* Copyright (c) 2025 Voxgig Ltd, MIT License */
|
|
5
5
|
|
|
6
|
-
import { ProviderSpec, Provider, SekretoError, envkey } from '
|
|
7
|
-
import { checkaddr } from '
|
|
8
|
-
import { fetchjson } from './
|
|
6
|
+
import { ProviderSpec, Provider, SekretoError, envkey, providerplugin } from '../provider/support'
|
|
7
|
+
import { checkaddr } from '../provider/addr'
|
|
8
|
+
import { fetchjson } from './httpjson'
|
|
9
9
|
|
|
10
|
+
/** Infisical.
|
|
11
|
+
*
|
|
12
|
+
* `api.token` reads the secret keyed `API_TOKEN` (Infisical's own
|
|
13
|
+
* convention is environment-style keys) at a secret path in one
|
|
14
|
+
* environment of a project. Auth is a token, or a universal-auth
|
|
15
|
+
* (machine identity) login with clientid/clientsecret. */
|
|
10
16
|
export function infisicalprovider(options?: {
|
|
11
17
|
addr?: string
|
|
12
18
|
token?: string
|
|
@@ -93,15 +99,7 @@ export function infisicalprovider(options?: {
|
|
|
93
99
|
}
|
|
94
100
|
}
|
|
95
101
|
|
|
96
|
-
/** Build a provider from its declarative form. */
|
|
97
102
|
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
import { register } from './Registry'
|
|
102
|
-
|
|
103
|
-
register({
|
|
104
|
-
name: 'infisical',
|
|
105
|
-
needs: ['fetch'],
|
|
106
|
-
define: (spec: ProviderSpec) => infisicalprovider(spec),
|
|
107
|
-
})
|
|
103
|
+
/** The plugin. Needs HTTPS. */
|
|
104
|
+
export const infisical = providerplugin('infisical', (spec: ProviderSpec) =>
|
|
105
|
+
infisicalprovider(spec))
|
|
@@ -1,14 +1,20 @@
|
|
|
1
|
-
// VENDORED: @voxgig/sekreto 0.
|
|
2
|
-
// Source: https://github.com/voxgig/sekreto @
|
|
1
|
+
// VENDORED: @voxgig/sekreto 0.2.0 (typescript/plugins/onepassword.ts)
|
|
2
|
+
// Source: https://github.com/voxgig/sekreto @ 86ba35a646e68a311bdece43cd5689369ca62e9d [tag: sdk-20260907-0029-0]
|
|
3
3
|
// License: MIT (c) voxgig - see repository LICENSE. Do not edit: resync from upstream.
|
|
4
4
|
/* Copyright (c) 2025 Voxgig Ltd, MIT License */
|
|
5
5
|
|
|
6
6
|
import {
|
|
7
|
-
ProviderSpec, Provider, SekretoError, checkname,
|
|
8
|
-
} from '
|
|
9
|
-
import { checkaddr } from '
|
|
10
|
-
import { fetchjson } from './
|
|
7
|
+
ProviderSpec, Provider, SekretoError, checkname, providerplugin,
|
|
8
|
+
} from '../provider/support'
|
|
9
|
+
import { checkaddr } from '../provider/addr'
|
|
10
|
+
import { fetchjson } from './httpjson'
|
|
11
11
|
|
|
12
|
+
/** 1Password, through a Connect server.
|
|
13
|
+
*
|
|
14
|
+
* The item titled `api.token` (titles keep their dots), in the named
|
|
15
|
+
* vault. The value is the field with purpose PASSWORD, or the field
|
|
16
|
+
* labelled `value`. A vault that cannot be found is an error - config
|
|
17
|
+
* names it, so its absence is a broken store, not a missing secret. */
|
|
12
18
|
export function onepasswordprovider(options?: {
|
|
13
19
|
addr?: string
|
|
14
20
|
token?: string
|
|
@@ -101,20 +107,7 @@ export function onepasswordprovider(options?: {
|
|
|
101
107
|
}
|
|
102
108
|
}
|
|
103
109
|
|
|
104
|
-
/** Doppler.
|
|
105
|
-
*
|
|
106
|
-
* The whole config is downloaded once - Doppler's own bulk endpoint -
|
|
107
|
-
* and answered from memory, like a remote .env: `api.token` is the
|
|
108
|
-
* `API_TOKEN` entry. A service token is config-scoped, so project and
|
|
109
|
-
* config are only needed with broader tokens. */
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
// Registering at import is what makes this module's presence the only
|
|
113
|
-
// thing that decides whether the kind exists in a build.
|
|
114
|
-
import { register } from './Registry'
|
|
115
110
|
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
define: (spec: ProviderSpec) => onepasswordprovider(spec),
|
|
120
|
-
})
|
|
111
|
+
/** The plugin. Needs HTTPS. */
|
|
112
|
+
export const onepassword = providerplugin('onepassword', (spec: ProviderSpec) =>
|
|
113
|
+
onepasswordprovider(spec))
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
// VENDORED: @voxgig/sekreto 0.2.0 (typescript/plugins/secretspec.ts)
|
|
2
|
+
// Source: https://github.com/voxgig/sekreto @ 86ba35a646e68a311bdece43cd5689369ca62e9d [tag: sdk-20260907-0029-0]
|
|
3
|
+
// License: MIT (c) voxgig - see repository LICENSE. Do not edit: resync from upstream.
|
|
4
|
+
/* Copyright (c) 2025 Voxgig Ltd, MIT License */
|
|
5
|
+
|
|
6
|
+
import {
|
|
7
|
+
ProviderSpec, Provider, SekretoError, envkey, nodemod, providerplugin,
|
|
8
|
+
} from '../provider/support'
|
|
9
|
+
|
|
10
|
+
/** SecretSpec — https://secretspec.dev
|
|
11
|
+
*
|
|
12
|
+
* A declaration plus a chain of its own backends: the same shape as
|
|
13
|
+
* sekreto one level down. A project that has declared its secrets there
|
|
14
|
+
* should not have to declare them again here, so this reads through the
|
|
15
|
+
* `secretspec` CLI rather than reimplementing its resolution.
|
|
16
|
+
*
|
|
17
|
+
* SecretSpec audits every read and refuses without `--reason`; sekreto
|
|
18
|
+
* sends `sekreto` unless configured otherwise. */
|
|
19
|
+
export function secretspecprovider(options?: {
|
|
20
|
+
command?: string
|
|
21
|
+
file?: string
|
|
22
|
+
profile?: string
|
|
23
|
+
backend?: string
|
|
24
|
+
reason?: string
|
|
25
|
+
prefix?: string
|
|
26
|
+
}): Provider {
|
|
27
|
+
const opts = options || {}
|
|
28
|
+
const command = opts.command || 'secretspec'
|
|
29
|
+
|
|
30
|
+
return {
|
|
31
|
+
lookup: (name: string) => {
|
|
32
|
+
const key = envkey(name, opts.prefix)
|
|
33
|
+
|
|
34
|
+
const args: string[] = []
|
|
35
|
+
if (opts.file) {
|
|
36
|
+
args.push('--file', opts.file)
|
|
37
|
+
}
|
|
38
|
+
args.push('get', key)
|
|
39
|
+
if (opts.backend) {
|
|
40
|
+
args.push('--provider', opts.backend)
|
|
41
|
+
}
|
|
42
|
+
if (opts.profile) {
|
|
43
|
+
args.push('--profile', opts.profile)
|
|
44
|
+
}
|
|
45
|
+
args.push('--reason', opts.reason || 'sekreto')
|
|
46
|
+
|
|
47
|
+
const { spawnSync } = nodemod<typeof import('node:child_process')>('node:child_process')
|
|
48
|
+
const run = spawnSync(command, args, { encoding: 'utf8' })
|
|
49
|
+
|
|
50
|
+
if (run.error) {
|
|
51
|
+
throw new SekretoError('sekreto: cannot run ' + command + ': ' + run.error.message)
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
if (0 === run.status) {
|
|
55
|
+
// The value and one newline, and nothing else.
|
|
56
|
+
return run.stdout.replace(/\n$/, '')
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
const why = (run.stderr || '').trim()
|
|
60
|
+
|
|
61
|
+
if (secretspecmiss(why, key)) {
|
|
62
|
+
return undefined
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
throw new SekretoError('sekreto: secretspec error: ' + (why || 'exit ' + run.status))
|
|
66
|
+
},
|
|
67
|
+
describe: () => 'secretspec' + (opts.backend ? ':' + opts.backend : ''),
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
/** Does this SecretSpec failure mean "no such secret" rather than "I
|
|
72
|
+
* could not answer"?
|
|
73
|
+
*
|
|
74
|
+
* SecretSpec says `Secret 'API_TOKEN' not found` for both a name it does
|
|
75
|
+
* not declare and one declared with no value, and both are misses: this
|
|
76
|
+
* store does not hold it, so the chain carries on.
|
|
77
|
+
*
|
|
78
|
+
* MATCHED ON THE WHOLE PHRASE, NOT ON "not found". SecretSpec also says
|
|
79
|
+
* `Provider backend 'keyring' not found`, which is a store that could
|
|
80
|
+
* not answer at all - and reading that as a miss is the worst failure
|
|
81
|
+
* this library has, because the chain then falls through to a weaker
|
|
82
|
+
* store without saying so. The key is required to appear, so the two
|
|
83
|
+
* cannot be confused. */
|
|
84
|
+
function secretspecmiss(why: string, key: string): boolean {
|
|
85
|
+
return why.includes("Secret '" + key + "' not found")
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
/** The plugin. Needs a child process. */
|
|
89
|
+
export const secretspec = providerplugin('secretspec', (spec: ProviderSpec) =>
|
|
90
|
+
secretspecprovider({
|
|
91
|
+
command: spec.command,
|
|
92
|
+
file: spec.file,
|
|
93
|
+
profile: spec.profile,
|
|
94
|
+
backend: spec.backend,
|
|
95
|
+
reason: spec.reason,
|
|
96
|
+
prefix: spec.prefix,
|
|
97
|
+
}),
|
|
98
|
+
)
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
// VENDORED: @voxgig/sekreto 0.
|
|
2
|
-
// Source: https://github.com/voxgig/sekreto @
|
|
1
|
+
// VENDORED: @voxgig/sekreto 0.2.0 (typescript/plugins/sigv4.ts)
|
|
2
|
+
// Source: https://github.com/voxgig/sekreto @ 86ba35a646e68a311bdece43cd5689369ca62e9d [tag: sdk-20260907-0029-0]
|
|
3
3
|
// License: MIT (c) voxgig - see repository LICENSE. Do not edit: resync from upstream.
|
|
4
4
|
// AWS Signature Version 4, hand-rolled.
|
|
5
5
|
//
|
|
@@ -16,10 +16,11 @@
|
|
|
16
16
|
|
|
17
17
|
// node:crypto is loaded ON FIRST USE, not at import time.
|
|
18
18
|
//
|
|
19
|
-
//
|
|
20
|
-
//
|
|
21
|
-
// of
|
|
22
|
-
//
|
|
19
|
+
// This module lives under plugins/ and is reached only through the aws
|
|
20
|
+
// plugin, so the core never sees it at all; deferring the builtin on top
|
|
21
|
+
// of that keeps importing the plugin free of side effects too, and lets
|
|
22
|
+
// the sigv4 conformance group run on a runtime that has crypto without
|
|
23
|
+
// anything else in the module graph having asked for it.
|
|
23
24
|
//
|
|
24
25
|
// require(), not `await import()`: these helpers are synchronous and are
|
|
25
26
|
// called from synchronous signing code. The package is CommonJS.
|
|
@@ -1,43 +1,117 @@
|
|
|
1
|
-
// VENDORED: @voxgig/sekreto 0.
|
|
2
|
-
// Source: https://github.com/voxgig/sekreto @
|
|
1
|
+
// VENDORED: @voxgig/sekreto 0.2.0 (typescript/src/provider/addr.ts)
|
|
2
|
+
// Source: https://github.com/voxgig/sekreto @ 86ba35a646e68a311bdece43cd5689369ca62e9d [tag: sdk-20260907-0029-0]
|
|
3
3
|
// License: MIT (c) voxgig - see repository LICENSE. Do not edit: resync from upstream.
|
|
4
4
|
/* Copyright (c) 2025 Voxgig Ltd, MIT License */
|
|
5
5
|
|
|
6
6
|
import { SekretoError } from './support'
|
|
7
7
|
|
|
8
|
+
/** An address with any userinfo replaced by `[redacted]`, for messages.
|
|
9
|
+
*
|
|
10
|
+
* Every refusal below names the address it refused, and one of them fires
|
|
11
|
+
* precisely because the address carries a credential — so printing it
|
|
12
|
+
* verbatim wrote the password to stderr and into the logs. It cannot be
|
|
13
|
+
* cleaned up afterwards either: that password was never resolved as a
|
|
14
|
+
* secret, so `redact()` has never seen it and never will. The host is what
|
|
15
|
+
* a reader needs to identify which chain entry is at fault; the userinfo
|
|
16
|
+
* is not. */
|
|
17
|
+
export function safeaddr(addr: string): string {
|
|
18
|
+
const mark = addr.indexOf('://')
|
|
19
|
+
if (-1 === mark) {
|
|
20
|
+
return addr
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
const rest = addr.slice(mark + 3)
|
|
24
|
+
const end = rest.search(/[/?#]/)
|
|
25
|
+
const authority = -1 === end ? rest : rest.slice(0, end)
|
|
26
|
+
|
|
27
|
+
const at = authority.lastIndexOf('@')
|
|
28
|
+
if (-1 === at) {
|
|
29
|
+
return addr
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
return addr.slice(0, mark + 3) + '[redacted]' + addr.slice(mark + 3 + at)
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/** Refuse to send a secret-bearing credential in the clear.
|
|
36
|
+
*
|
|
37
|
+
* A vault API is HTTPS in any real deployment; plaintext is a dev-mode
|
|
38
|
+
* convenience. Sending a token over http to anything but the local
|
|
39
|
+
* machine puts both the token and the secret it fetches on the wire for
|
|
40
|
+
* anyone on the path, so sekreto will not do it. Loopback stays allowed:
|
|
41
|
+
* that is `vault server -dev`, `boru vault serve`, and this repo's own
|
|
42
|
+
* test harness.
|
|
43
|
+
*
|
|
44
|
+
* The address is read by hand, in the same handful of steps in every
|
|
45
|
+
* port, rather than by each platform's URL parser. That is deliberate.
|
|
46
|
+
* Twelve parsers disagree about malformed input — where userinfo ends,
|
|
47
|
+
* whether `0177.0.0.1` is loopback, what an unclosed bracket means — and
|
|
48
|
+
* a check that answers differently in different ports is not a check.
|
|
49
|
+
*
|
|
50
|
+
* The rule this parse obeys, and the reason it can be trusted: it is
|
|
51
|
+
* never more permissive than the HTTP client that will dial the address.
|
|
52
|
+
* It ends the authority at `/`, `?` or `#` only, so a client that also
|
|
53
|
+
* breaks on `\` (WHATWG does) can only ever see a SHORTER host than this
|
|
54
|
+
* does. It refuses userinfo outright rather than locating its end. It
|
|
55
|
+
* compares the host literally, so a numeric form no parser here agrees on
|
|
56
|
+
* is refused rather than guessed at. Each of those can refuse an address
|
|
57
|
+
* that would in fact have been safe; none can allow one that is not. */
|
|
8
58
|
export function checkaddr(addr: string): void {
|
|
9
|
-
|
|
10
|
-
|
|
59
|
+
const scheme = addr.startsWith('https://')
|
|
60
|
+
? 'https://'
|
|
61
|
+
: addr.startsWith('http://')
|
|
62
|
+
? 'http://'
|
|
63
|
+
: ''
|
|
64
|
+
|
|
65
|
+
if ('' === scheme) {
|
|
66
|
+
throw new SekretoError('sekreto: not an http(s) address: ' + safeaddr(addr))
|
|
11
67
|
}
|
|
12
68
|
|
|
13
|
-
|
|
14
|
-
|
|
69
|
+
const rest = addr.slice(scheme.length)
|
|
70
|
+
const end = rest.search(/[/?#]/)
|
|
71
|
+
const authority = -1 === end ? rest : rest.slice(0, end)
|
|
72
|
+
|
|
73
|
+
// Userinfo is refused outright rather than parsed around, and on https
|
|
74
|
+
// as well as http. No store this library speaks authenticates by
|
|
75
|
+
// userinfo — they take a token or a signature — so an address carrying
|
|
76
|
+
// one is a mistake at best. At worst it is the attack this whole
|
|
77
|
+
// function exists to stop: `http://localhost:8200@evil.example.com/` is
|
|
78
|
+
// a request to evil.example.com that reads, to anything that splits the
|
|
79
|
+
// authority on ':', as loopback. Refusing the shape is a rule twelve
|
|
80
|
+
// ports can apply identically; agreeing on where the userinfo ends is
|
|
81
|
+
// not.
|
|
82
|
+
if (authority.includes('@')) {
|
|
83
|
+
throw new SekretoError(
|
|
84
|
+
'sekreto: refusing an address with embedded credentials: ' + safeaddr(addr),
|
|
85
|
+
)
|
|
15
86
|
}
|
|
16
87
|
|
|
17
|
-
//
|
|
18
|
-
//
|
|
19
|
-
//
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
// The ALLOWLIST is unchanged. URL only fixes what the host IS: it strips
|
|
23
|
-
// userinfo (so `http://127.0.0.1@evil.com/` reads as evil.com, as
|
|
24
|
-
// before), lowercases, and normalises numeric forms — `0177.0.0.1` is
|
|
25
|
-
// 127.0.0.1 and is now recognised as the loopback it actually is.
|
|
26
|
-
// IPv4-mapped IPv6 (`[::ffff:127.0.0.1]`) is deliberately still refused:
|
|
27
|
-
// widening the set is a separate decision from parsing it correctly.
|
|
28
|
-
let host: string
|
|
29
|
-
try {
|
|
30
|
-
host = new URL(addr).hostname
|
|
31
|
-
} catch (err: any) {
|
|
32
|
-
throw new SekretoError('sekreto: not a valid http(s) address: ' + addr)
|
|
88
|
+
// An opening bracket with no closing one is not an address at all, and
|
|
89
|
+
// saying so is more use to whoever wrote the config than refusing it as
|
|
90
|
+
// though it named a remote host.
|
|
91
|
+
if (authority.startsWith('[') && !authority.includes(']')) {
|
|
92
|
+
throw new SekretoError('sekreto: not a valid http(s) address: ' + safeaddr(addr))
|
|
33
93
|
}
|
|
34
94
|
|
|
95
|
+
if ('https://' === scheme) {
|
|
96
|
+
return
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
// A bracketed IPv6 literal keeps its brackets. Splitting the authority
|
|
100
|
+
// on the first colon yields '[', so `http://[::1]:8200` could never
|
|
101
|
+
// match — which made the '[::1]' entry below unreachable, and refused a
|
|
102
|
+
// legitimate local vault.
|
|
103
|
+
const host = (
|
|
104
|
+
authority.startsWith('[')
|
|
105
|
+
? authority.slice(0, authority.indexOf(']') + 1)
|
|
106
|
+
: authority.split(':')[0]
|
|
107
|
+
).toLowerCase()
|
|
108
|
+
|
|
35
109
|
if ('localhost' === host || '127.0.0.1' === host || '::1' === host || '[::1]' === host) {
|
|
36
110
|
return
|
|
37
111
|
}
|
|
38
112
|
|
|
39
113
|
throw new SekretoError(
|
|
40
|
-
'sekreto: refusing to send a token in plaintext to ' + addr + ' (use https)',
|
|
114
|
+
'sekreto: refusing to send a token in plaintext to ' + safeaddr(addr) + ' (use https)',
|
|
41
115
|
)
|
|
42
116
|
}
|
|
43
117
|
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
// VENDORED: @voxgig/sekreto 0.2.0 (typescript/src/provider/builtin.ts)
|
|
2
|
+
// Source: https://github.com/voxgig/sekreto @ 86ba35a646e68a311bdece43cd5689369ca62e9d [tag: sdk-20260907-0029-0]
|
|
3
|
+
// License: MIT (c) voxgig - see repository LICENSE. Do not edit: resync from upstream.
|
|
4
|
+
/* Copyright (c) 2025 Voxgig Ltd, MIT License */
|
|
5
|
+
|
|
6
|
+
// THE BUILT-IN PROVIDER KINDS - the same four in every port.
|
|
7
|
+
//
|
|
8
|
+
// What makes a kind built in is that it needs nothing of the platform
|
|
9
|
+
// beyond reading a local file: no socket, no TLS, no crypto, no child
|
|
10
|
+
// process. These four are the floor every chain stands on, and a chain
|
|
11
|
+
// that reads secrets from options, the environment, a plaintext `.env`
|
|
12
|
+
// and a mounted secret directory works with no plugin loaded at all.
|
|
13
|
+
// Everything else - the vault clients, the cloud stores, the CLIs - is a
|
|
14
|
+
// plugin, and lives under `plugins/` (docs/design/plugin-providers.md).
|
|
15
|
+
|
|
16
|
+
import { Definition, ProviderSpec, providerplugin } from './support'
|
|
17
|
+
import { envprovider } from './env'
|
|
18
|
+
import { memoryprovider } from './memory'
|
|
19
|
+
import { dotenvprovider } from './dotenv'
|
|
20
|
+
import { fileprovider } from './file'
|
|
21
|
+
|
|
22
|
+
export const BUILTINS: Definition[] = [
|
|
23
|
+
providerplugin('env', (spec: ProviderSpec) => envprovider(spec.prefix)),
|
|
24
|
+
providerplugin('memory', (spec: ProviderSpec) => memoryprovider(spec.values || {}, spec.prefix)),
|
|
25
|
+
providerplugin('dotenv', (spec: ProviderSpec) => dotenvprovider(spec.file || '.env', spec.prefix)),
|
|
26
|
+
providerplugin('file', (spec: ProviderSpec) => fileprovider(spec.dir || '', spec.prefix)),
|
|
27
|
+
]
|
|
28
|
+
|
|
29
|
+
/** Every kind this library ships, built in or as a plugin, so that an
|
|
30
|
+
* unknown kind can be told from a plugin that was not loaded. */
|
|
31
|
+
export const KINDS = {
|
|
32
|
+
builtin: ['env', 'memory', 'dotenv', 'file'],
|
|
33
|
+
plugin: [
|
|
34
|
+
'hashicorp', 'boru', 'awssecrets', 'awsparams', 'gcpsecrets',
|
|
35
|
+
'azuresecrets', 'onepassword', 'doppler', 'infisical', 'secretspec',
|
|
36
|
+
],
|
|
37
|
+
}
|