seekrit-sdk 0.5.0 → 0.7.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.
- checksums.yaml +4 -4
- data/README.md +2 -1
- data/lib/seekrit/version.rb +1 -1
- data/testdata/vectors.json +173 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 9f2206673124b0906c9621c714ebc247a4930ba80e5f179dfc38f17e8d912eac
|
|
4
|
+
data.tar.gz: 738b4c4a5ba931bc683b7be6e71cf84f7672561ae7797f082132444c015c0fce
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: fa03ad6828ef0201f6fb7e2e69bd1fd432244219dfa0439141e2d635b471ab775997dac240c3bd2105f223691acf5292cfb70fc4a03136d647cdc649d1734526
|
|
7
|
+
data.tar.gz: 6c5f8a2c75ed70a0fdab12bc427b52ba78cc8571fa888f5f778ac7a78c7da593be4df766226105c194f8cb2ab3d159a854f838d04bf460312883a5f089e610d1
|
data/README.md
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
# seekrit — Ruby SDK
|
|
2
2
|
|
|
3
|
-
Read-path SDK for [seekrit](https://seekrit.dev)
|
|
3
|
+
Read-path SDK for [seekrit](https://seekrit.dev), a zero-knowledge secrets
|
|
4
|
+
manager and credential broker for AI agents. Authenticate with a service
|
|
4
5
|
token, resolve your environment, and get **decrypted** secrets — the API only
|
|
5
6
|
ever returns ciphertext; decryption happens in your process.
|
|
6
7
|
|
data/lib/seekrit/version.rb
CHANGED
data/testdata/vectors.json
CHANGED
|
@@ -239,7 +239,7 @@
|
|
|
239
239
|
]
|
|
240
240
|
},
|
|
241
241
|
"substitution": {
|
|
242
|
-
"note": "Placeholder substitution over plaintext alone — no crypto involved. Every implementation of the engine (apps/proxy/src/substitute.rs and the fetch/httpx shims in the language SDKs) runs these, so the rules can never drift apart. The lookup each harness must install: a name in `denied` returns Denied, otherwise a name present in `values` returns that Value, otherwise Unknown. A case has either `expected` + `names`, or `error`.",
|
|
242
|
+
"note": "Placeholder substitution over plaintext alone — no crypto involved. Every implementation of the engine (apps/proxy/src/substitute.rs and the fetch/httpx shims in the language SDKs) runs these, so the rules can never drift apart. The lookup each harness must install: a name in `denied` returns Denied, otherwise a name present in `values` returns that Value, otherwise Unknown. A case has either `expected` + `names`, or `error`. A case with `header` is the value of that request header and runs through the header entry point (substitute_header / substituteHeader): an `Authorization` or `Proxy-Authorization` value (name compared case-insensitively) of the form `Basic <credentials>` — scheme case-insensitive, then one or more spaces, then canonical padded RFC 4648 base64 (standard alphabet, zero padding bits) that decodes to UTF-8 — has the decoded text substituted with the same lookup and re-encoded, keeping the scheme and spacing as sent. Any other value, including a Basic credential that fails one of those checks, is substituted as text exactly as a case without `header`.",
|
|
243
243
|
"cases": [
|
|
244
244
|
{
|
|
245
245
|
"name": "substitutes a placeholder and reports the name",
|
|
@@ -429,6 +429,178 @@
|
|
|
429
429
|
"names": [
|
|
430
430
|
"EMPTY"
|
|
431
431
|
]
|
|
432
|
+
},
|
|
433
|
+
{
|
|
434
|
+
"name": "a placeholder inside a Basic credential is decoded, substituted, and re-encoded",
|
|
435
|
+
"header": "authorization",
|
|
436
|
+
"input": "Basic eC1hY2Nlc3MtdG9rZW46e3tzZWVrcml0OkdJVEhVQl9UT0tFTn19",
|
|
437
|
+
"values": {
|
|
438
|
+
"GITHUB_TOKEN": "ghp_live"
|
|
439
|
+
},
|
|
440
|
+
"denied": [],
|
|
441
|
+
"expected": "Basic eC1hY2Nlc3MtdG9rZW46Z2hwX2xpdmU=",
|
|
442
|
+
"names": [
|
|
443
|
+
"GITHUB_TOKEN"
|
|
444
|
+
]
|
|
445
|
+
},
|
|
446
|
+
{
|
|
447
|
+
"name": "Proxy-Authorization carries a Basic credential too, re-encoded as UTF-8",
|
|
448
|
+
"header": "proxy-authorization",
|
|
449
|
+
"input": "Basic YWdlbnQ6e3tzZWVrcml0OlBST1hZX1BBU1NXT1JEfX0=",
|
|
450
|
+
"values": {
|
|
451
|
+
"PROXY_PASSWORD": "hünter2"
|
|
452
|
+
},
|
|
453
|
+
"denied": [],
|
|
454
|
+
"expected": "Basic YWdlbnQ6aMO8bnRlcjI=",
|
|
455
|
+
"names": [
|
|
456
|
+
"PROXY_PASSWORD"
|
|
457
|
+
]
|
|
458
|
+
},
|
|
459
|
+
{
|
|
460
|
+
"name": "the header name and the Basic scheme match case-insensitively",
|
|
461
|
+
"header": "Authorization",
|
|
462
|
+
"input": "bAsIc e3tzZWVrcml0OkdJVEhVQl9UT0tFTn19Ongtb2F1dGgtYmFzaWM=",
|
|
463
|
+
"values": {
|
|
464
|
+
"GITHUB_TOKEN": "ghp_live"
|
|
465
|
+
},
|
|
466
|
+
"denied": [],
|
|
467
|
+
"expected": "bAsIc Z2hwX2xpdmU6eC1vYXV0aC1iYXNpYw==",
|
|
468
|
+
"names": [
|
|
469
|
+
"GITHUB_TOKEN"
|
|
470
|
+
]
|
|
471
|
+
},
|
|
472
|
+
{
|
|
473
|
+
"name": "every placeholder in a Basic credential is injected, and the spaces after the scheme are kept",
|
|
474
|
+
"header": "authorization",
|
|
475
|
+
"input": "Basic e3tzZWVrcml0OkdIX1VTRVJ9fTp7e3NlZWtyaXQ6R0lUSFVCX1RPS0VOfX0=",
|
|
476
|
+
"values": {
|
|
477
|
+
"GH_USER": "octocat",
|
|
478
|
+
"GITHUB_TOKEN": "ghp_live"
|
|
479
|
+
},
|
|
480
|
+
"denied": [],
|
|
481
|
+
"expected": "Basic b2N0b2NhdDpnaHBfbGl2ZQ==",
|
|
482
|
+
"names": [
|
|
483
|
+
"GH_USER",
|
|
484
|
+
"GITHUB_TOKEN"
|
|
485
|
+
]
|
|
486
|
+
},
|
|
487
|
+
{
|
|
488
|
+
"name": "a denied name inside a Basic credential aborts the pass",
|
|
489
|
+
"header": "authorization",
|
|
490
|
+
"input": "Basic eC1hY2Nlc3MtdG9rZW46e3tzZWVrcml0OlNPTUVfT1RIRVJ9fQ==",
|
|
491
|
+
"values": {
|
|
492
|
+
"GITHUB_TOKEN": "ghp_live"
|
|
493
|
+
},
|
|
494
|
+
"denied": [
|
|
495
|
+
"SOME_OTHER"
|
|
496
|
+
],
|
|
497
|
+
"error": {
|
|
498
|
+
"code": "denied",
|
|
499
|
+
"name": "SOME_OTHER"
|
|
500
|
+
}
|
|
501
|
+
},
|
|
502
|
+
{
|
|
503
|
+
"name": "an unresolved name inside a Basic credential aborts the pass",
|
|
504
|
+
"header": "authorization",
|
|
505
|
+
"input": "Basic eC1hY2Nlc3MtdG9rZW46e3tzZWVrcml0Ok1JU1NJTkd9fQ==",
|
|
506
|
+
"values": {
|
|
507
|
+
"GITHUB_TOKEN": "ghp_live"
|
|
508
|
+
},
|
|
509
|
+
"denied": [],
|
|
510
|
+
"error": {
|
|
511
|
+
"code": "unresolved",
|
|
512
|
+
"name": "MISSING"
|
|
513
|
+
}
|
|
514
|
+
},
|
|
515
|
+
{
|
|
516
|
+
"name": "a Basic credential with no placeholder passes through byte-identical",
|
|
517
|
+
"header": "authorization",
|
|
518
|
+
"input": "Basic dXNlcjpwYXNz",
|
|
519
|
+
"values": {
|
|
520
|
+
"GITHUB_TOKEN": "ghp_live"
|
|
521
|
+
},
|
|
522
|
+
"denied": [],
|
|
523
|
+
"expected": "Basic dXNlcjpwYXNz",
|
|
524
|
+
"names": []
|
|
525
|
+
},
|
|
526
|
+
{
|
|
527
|
+
"name": "a placeholder standing in for the whole Basic credential is substituted as text",
|
|
528
|
+
"header": "authorization",
|
|
529
|
+
"input": "Basic {{seekrit:GITHUB_BASIC}}",
|
|
530
|
+
"values": {
|
|
531
|
+
"GITHUB_BASIC": "eC1hY2Nlc3MtdG9rZW46Z2hwX2xpdmU="
|
|
532
|
+
},
|
|
533
|
+
"denied": [],
|
|
534
|
+
"expected": "Basic eC1hY2Nlc3MtdG9rZW46Z2hwX2xpdmU=",
|
|
535
|
+
"names": [
|
|
536
|
+
"GITHUB_BASIC"
|
|
537
|
+
]
|
|
538
|
+
},
|
|
539
|
+
{
|
|
540
|
+
"name": "a scheme other than Basic is not decoded",
|
|
541
|
+
"header": "authorization",
|
|
542
|
+
"input": "Bearer e3tzZWVrcml0OkdJVEhVQl9UT0tFTn19",
|
|
543
|
+
"values": {
|
|
544
|
+
"GITHUB_TOKEN": "ghp_live"
|
|
545
|
+
},
|
|
546
|
+
"denied": [],
|
|
547
|
+
"expected": "Bearer e3tzZWVrcml0OkdJVEhVQl9UT0tFTn19",
|
|
548
|
+
"names": []
|
|
549
|
+
},
|
|
550
|
+
{
|
|
551
|
+
"name": "a Basic credential in any other header is not decoded",
|
|
552
|
+
"header": "x-upstream-authorization",
|
|
553
|
+
"input": "Basic eC1hY2Nlc3MtdG9rZW46e3tzZWVrcml0OkdJVEhVQl9UT0tFTn19",
|
|
554
|
+
"values": {
|
|
555
|
+
"GITHUB_TOKEN": "ghp_live"
|
|
556
|
+
},
|
|
557
|
+
"denied": [],
|
|
558
|
+
"expected": "Basic eC1hY2Nlc3MtdG9rZW46e3tzZWVrcml0OkdJVEhVQl9UT0tFTn19",
|
|
559
|
+
"names": []
|
|
560
|
+
},
|
|
561
|
+
{
|
|
562
|
+
"name": "unpadded base64 is not decoded",
|
|
563
|
+
"header": "authorization",
|
|
564
|
+
"input": "Basic eDp7e3NlZWtyaXQ6R0lUSFVCX1RPS0VOfX0",
|
|
565
|
+
"values": {
|
|
566
|
+
"GITHUB_TOKEN": "ghp_live"
|
|
567
|
+
},
|
|
568
|
+
"denied": [],
|
|
569
|
+
"expected": "Basic eDp7e3NlZWtyaXQ6R0lUSFVCX1RPS0VOfX0",
|
|
570
|
+
"names": []
|
|
571
|
+
},
|
|
572
|
+
{
|
|
573
|
+
"name": "base64 with non-zero padding bits is not decoded",
|
|
574
|
+
"header": "authorization",
|
|
575
|
+
"input": "Basic eDp7e3NlZWtyaXQ6R0lUSFVCX1RPS0VOfX1=",
|
|
576
|
+
"values": {
|
|
577
|
+
"GITHUB_TOKEN": "ghp_live"
|
|
578
|
+
},
|
|
579
|
+
"denied": [],
|
|
580
|
+
"expected": "Basic eDp7e3NlZWtyaXQ6R0lUSFVCX1RPS0VOfX1=",
|
|
581
|
+
"names": []
|
|
582
|
+
},
|
|
583
|
+
{
|
|
584
|
+
"name": "the base64url alphabet is not decoded",
|
|
585
|
+
"header": "authorization",
|
|
586
|
+
"input": "Basic Y2l-Ont7c2Vla3JpdDpHSVRIVUJfVE9LRU59fQ==",
|
|
587
|
+
"values": {
|
|
588
|
+
"GITHUB_TOKEN": "ghp_live"
|
|
589
|
+
},
|
|
590
|
+
"denied": [],
|
|
591
|
+
"expected": "Basic Y2l-Ont7c2Vla3JpdDpHSVRIVUJfVE9LRU59fQ==",
|
|
592
|
+
"names": []
|
|
593
|
+
},
|
|
594
|
+
{
|
|
595
|
+
"name": "a Basic credential that does not decode to UTF-8 is not decoded",
|
|
596
|
+
"header": "authorization",
|
|
597
|
+
"input": "Basic /zp7e3NlZWtyaXQ6R0lUSFVCX1RPS0VOfX0=",
|
|
598
|
+
"values": {
|
|
599
|
+
"GITHUB_TOKEN": "ghp_live"
|
|
600
|
+
},
|
|
601
|
+
"denied": [],
|
|
602
|
+
"expected": "Basic /zp7e3NlZWtyaXQ6R0lUSFVCX1RPS0VOfX0=",
|
|
603
|
+
"names": []
|
|
432
604
|
}
|
|
433
605
|
]
|
|
434
606
|
}
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: seekrit-sdk
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.7.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- seekrit
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-
|
|
11
|
+
date: 2026-11-12 00:00:00.000000000 Z
|
|
12
12
|
dependencies: []
|
|
13
13
|
description: |
|
|
14
14
|
Read-path SDK for seekrit, the zero-knowledge secrets manager. Authenticate
|