30817:password-manager
Password manager
covers4111
- signed by
- npub1kg4sd...quw5te
- published
- 2025-10-05
- event
- 20cb1b25f0...2e30
NIP-XX
Password manager
draft optional
This NIP defines a standard for storing secrets.
Templates
Secret
{
"id": "<random id>", // for versioning
"title": "<secrettitle>",
"fields": ["<field 1>", "<field 2>", "<field 3>", "..."],
"urls": ["<website url>"],
"note": "<note content>"
}
Fields
Text
{
"name": "<field name>",
"kind": "text",
"value": "<visible text>"
}
Secret text
Same as Text, but the client MUST hide the value.
{
"name": "<field name>",
"kind": "secret",
"value": "<field value>"
}
OTP
{
"name": "OTP",
"kind": "otp",
"value": {
"type": "<totp|hotp>",
"secret": "<otp secret>",
"algorithm": "<SHA1|SHA256|SHA512>",
"digits": 6,
"period": 30,
"counter": 0,
}
}
Sending to relays
The content must be json stringified and then encrypted using NIP-44.
{
"kind": 4111,
"content": "nip44.encrypt(JSON.stringify(<secret>))"
}
Secret sharing
To share a secret you must add a "p" tag with the recipient pubkey and you must encrypt the content using NIP-44 and his pubkey.
{
"kind": 4111,
"tags": [
["p", "<recipient pubkey>"],
],
"content": "nip44.encrypt(JSON.stringify(<secret>), <recipient pubkey>)"
}
Delete a secret
Use NIP-09 to delete a secret.
Example
Create a secret
{
"id": "XkjfyZQEJvsy2Fkz",
"title": "Github",
"fields": [
{
"name": "Name",
"kind": "text",
"value": "Bob"
},
{
"name": "Email",
"kind": "text",
"value": "bob@nostr-mail.com"
},
{
"name": "Password",
"kind": "secret",
"value": "=[s8p!Nd#KCX6(@r"
},
{
"name": "OTP",
"kind": "otp",
"value": {
"type": "totp",
"secret": "JBSWY3DPEHPK3PXP",
"algorithm": "SHA1",
"digits": 6,
"period": 30
}
}
],
"note": "My main github account"
}
Update a secret
{
"id": "XkjfyZQEJvsy2Fkz", // keep the same id
"title": "Github",
"urls": ["https://github.com"], // update
"fields": [
{
"name": "Name",
"kind": "text",
"value": "Bob"
},
{
"name": "Email",
"kind": "text",
"value": "bob@nostr-mail.com"
},
{
"name": "Password",
"kind": "secret",
"value": "=[s8p!Nd#KCX6(@r"
},
{
"name": "OTP",
"kind": "otp",
"value": {
"type": "totp",
"secret": "JBSWY3DPEHPK3PXP",
"algorithm": "SHA1",
"digits": 6,
"period": 30
}
}
],
"note": "My github account" // update
}
Cited links
github.com
nips/44.md at master · nostr-protocol/nips
Nostr Implementation Possibilities. Contribute to nostr-protocol/nips development by creating an account on GitHub.
github.com
nips/09.md at master · nostr-protocol/nips
Nostr Implementation Possibilities. Contribute to nostr-protocol/nips development by creating an account on GitHub.
Discussion
Connect a key to comment.