credentials
यह क्या करती है
यह smolvm वर्चुअल मशीन के अंदर चल रहे प्रोग्राम को आपके बताए वेब पतों पर आपकी API key इस्तेमाल करने देती है, बिना key को पढ़ सके। यह उन लोगों के लिए है जिनके एजेंट या भरोसे के बाहर कोड को पेड सेवाएँ कॉल करनी हैं।
कब इस्तेमाल करें
- ✓जब मशीन के अंदर एजेंट को आपकी key से API कॉल करना हो।
- ✓जब आपको जानना हो कि key मशीन से बाहर कैसे रह सकती है।
- ✓जब आपको यह प्रमाण चाहिए कि गुप्त जानकारी कभी मशीन तक नहीं पहुँची।
Skill का लिंक
https://github.com/smol-machines/smolvm/blob/main/docs/credentials/SKILL.mdइसे कॉपी करके अपने AI (Claude, ChatGPT या Cursor) में पेस्ट करें और निर्देशों का पालन करने को कहें।
कैसे इस्तेमाल करें
सबसे आसान तरीका: मैसेज कॉपी करके अपने AI में पेस्ट करें। वह skill पढ़कर निर्देशों का पालन करेगा।
पेस्ट करने के लिए तैयार मैसेज
Claude Code, Codex या Cursor के लिए: प्रोजेक्ट फ़ोल्डर में चलाएँ और skill इंस्टॉल हो जाएगी।
SKILL.md डाउनलोड करें और अपने एजेंट के skills फ़ोल्डर में रखें।
AI से क्या माँगें: उदाहरण
“मेरे एजेंट को मेरी key से हमारी भुगतान API कॉल करने दीजिए, लेकिन पक्का कीजिए कि key मशीन के अंदर कभी कॉपी न हो।”
हर हफ़्ते 5 नई skills, 1 मिनट में पढ़ें।
यह कैसे काम करती है
मशीन असली key की जगह एक placeholder रखती है। होस्ट बाहर जाते समय असली मान डालता है, केवल उन होस्ट के लिए जिन्हें आपने नामित किया है, और स्किल जाँचती है कि मान कभी मशीन के अंदर नहीं गया।
तकनीकी सामग्री (मूल SKILL.md)
लेखक का मूल टेक्स्ट, अंग्रेज़ी में, सीधे GitHub से।
A credential the machine can use and never hold
Verified on smolvm v1.29.0 on macOS arm64, 2026-10-15, and on v1.18.2 on Linux aarch64, 2026-09-24, for everything that
is decided on the host; on v1.29.0 on macOS arm64 the substituted value also arrived at a real API
that echoes the headers it received, a dummy value. Done means the guest's variable is a placeholder, the value
is nowhere in the guest, the machine's record or smolvm's database, TLS to the bound host goes
through the machine's own CA, and a placeholder anywhere but a request header is refused before it
leaves the host (from v1.27.0 a binding with :body also substitutes into a form body).
The Linux runs used the scripts of their date; this version's preflight and cleanup scripts ran
on Linux aarch64 on v1.22.2 on 2026-10-03.
docs/credential-substitution.md in the smolvm repository is how the feature works: bindings,
where the value comes from, what the guest sees, what happens to each request, and the limits.
README.md has what was measured beside it. This file is how to set it up and prove it.
Procedure
- [ ] 1. preflight.sh the flag, the network backend, the host variable
- [ ] 2. create-credentialed.sh a machine bound to one host
- [ ] 3. verify-containment.sh the value stays out; the interceptor is on the path
- [ ] 4. your own request the first call that sends the value
- [ ] 5. cleanup.sh
1. Preflight. Read-only, and it never prints the value or its length.
export API_TOKEN=... # however your secrets manager hands it over
scripts/preflight.sh --var API_TOKEN --host api.example.com
Every script here reads the value from its own environment, so keep it exported in the shell that
runs create-credentialed.sh and verify-containment.sh as well as this one.
has_credential_flag=yes
default_backend=virtio-net
tsi_stream_intercept=yes
host_var_set=yes
host_form=ok
memory_required_mib=1024
result=ready
tsi_stream_intercept is read from the symbols of the bundled libkrun: a binding selects virtio-net
by default, and --net-backend tsi carries a credential only when libkrun exports
krun_set_stream_intercept, which both v1.18.2 release libraries do. host_form=rejected means the
host is neither a lowercase DNS name nor, from v1.26.0, a wildcard such as *.example.com; create
would refuse it anyway, with a clearer message.
2. Create the machine. The value is read from the environment of this command's machine start, and that is the value the machine uses until its next start.
scripts/create-credentialed.sh --var API_TOKEN --host api.example.com
workload_ready_after_s=1
guest_sees=placeholder
binding=api-token host=api.example.com
result=up
The command it runs is smolvm machine create ... --credential api-token=API_TOKEN@api.example.com
and then machine start. --credential implies --net. In a Smolfile the same binding is a
[[network.credentials]] table, in docs/credential-substitution.md.
3. Prove the value stayed out. Nothing this sends carries the placeholder where it would be
substituted, so the value goes nowhere during the check. On an Alpine guest it adds openssl and
curl with apk, which step 4 then uses. Run it on the machine create-credentialed.sh made, before
any workload of yours runs in it: the guest search hands the value to a grep in the guest for the
length of the search, so a workload that can replace grep could read it.
scripts/verify-containment.sh --var API_TOKEN --host api.example.com --other-host example.org
guest_variable=ok (placeholder)
value_in_guest=ok (0)
value_in_record=ok (0)
interception=ok (on)
passthrough=ok (real)
query_refused=ok (403)
refusal_text=smolvm credentials: placeholders are substituted in request headers only
result=contained
value_in_guest hands the value to a grep inside the guest on standard input for the length of
the search, and looks in every process environment and the writable trees inside the guest;
value_in_record searches the machine's directory and smolvm's database on the host;
interception reads the issuer of the bound host's certificate as the guest sees it, which is
smolvm <machine> credential CA, while --other-host keeps its real issuer.
4. Use it. The workload sends the placeholder in a header, exactly where the real key would go.
smolskill-cred is the machine create-credentialed.sh makes unless you
अक्सर पूछे जाने वाले सवाल
key किन वेबसाइटों के साथ इस्तेमाल हो सकती है?
केवल वे HTTPS होस्ट, जिन्हें आप सेटअप के समय नामित करें।
मैं कैसे जानूँ कि key मशीन के अंदर नहीं है?
स्किल में एक जाँच है जो मशीन, उसकी सेटिंग्स और smolvm डेटाबेस में मान खोजती है।
यह किन कंप्यूटरों पर जाँचा गया?
स्किल उन macOS और Linux मशीनों को उनके संस्करणों के साथ सूचीबद्ध करती है, जिन पर इसे परखा गया।
जानकारी
लेखक का मूल विवरण
Gives a workload in a smolvm machine an API key or token it can use but never read, by binding the credential to named HTTPS hosts so the guest holds only a placeholder and the host substitutes the value on the way out, then proves on the host that the value never entered the machine. Use when an agent or untrusted code inside a machine has to call an API with your key; when deciding between a credential binding and --secret-env; when a request from a credentialed machine comes back 403 or 502 from smolvm itself; or when you need evidence that a key stayed out of a machine. Do not use it for a
repo: smol-machines/smolvm
लोकप्रियता
- GitHub स्टार
- 6.9k
- रैंकिंग में स्थान
- #13716
- लाइसेंस
- Apache-2.0
- अपडेट की गई
- 2/11/2026
कमेंट
- …
इस repository की और skills
branch-and-checkpoint
6.9kयह आपके एजेंट को चल रही smolvm वर्चुअल मशीन को चेकपॉइंट के रूप में सहेजने, बाद में वापस लाने, रोकने और फिर चालू करने, और उसे कॉपी में बाँटने में मदद करती है।
coding-agent
6.9kयह आपके एजेंट को smolvm की सुरक्षित वर्चुअल मशीन के अंदर Claude Code जैसे कोडिंग एजेंट चलाने में मदद करती है, जिसमें आपका प्रोजेक्ट फ़ोल्डर माउंट होता है।
dev-env
6.9kयह आपके एजेंट को smolvm की डेव मशीन में इंस्टॉल किए टूल बनाए रखना सिखाती है, ताकि वह जल्दी रीस्टार्ट हो और सत्रों के बीच पैकेज बने रहें।
docker-in-machine
6.9kयह आपके एजेंट को smolvm वर्चुअल मशीन के अंदर Docker daemon चलाने में मदद करती है, ताकि टेस्ट, बिल्ड और कंटेनर शुरू करने वाले एजेंट वहाँ काम कर सकें।
मिलती-जुलती skills
reverse-engineer-anything
422kयह आपके एजेंट को REA टूल से शिप हुई ऐप्स और पैकेज को अंदर से समझने, वर्ज़न की तुलना करने या दोबारा बनाने में मदद करती है।
1password
394kयह आपके एजेंट को 1Password CLI सेट करने, साइन इन करने और सीक्रेट्स की वैल्यू चैट में छापे बिना उन्हें पढ़ने या इस्तेमाल करने में मदद करती है।
healthcheck
394kयह आपके एजेंट को उस कंप्यूटर या सर्वर का सुरक्षा ऑडिट करने देती है जिस पर OpenClaw चलता है, जिसमें SSH, firewall, अपडेट और बैकअप शामिल हैं, और फिर सुरक्षित सुधार सुझाती है।