Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Publish IPNS names using a signature instead of private key #8542

Open
dogada opened this issue Nov 5, 2021 · 7 comments
Open

Publish IPNS names using a signature instead of private key #8542

dogada opened this issue Nov 5, 2021 · 7 comments
Labels
need/triage Needs initial labeling and prioritization

Comments

@dogada
Copy link

dogada commented Nov 5, 2021

To use /api/v0/name/publish I need to import private key to node first. For scenarios like in https://github.com/ipfs-shipyard/js-did-ipid I will prefer to keep my private key in wallet and sent to HTTP API an signature as proof of ownership of this key. So the IPFS node will not have access to private key but will be able to publish IPNS names still.

@johnnymatthews
Copy link
Contributor

Hi @dogada. Thanks for this comment. This sounds like a feature request for Go-IPFS, rather that a docs task. Or am I misunderstanding your comment?

@dogada
Copy link
Author

dogada commented Nov 8, 2021 via email

@lidel lidel transferred this issue from ipfs/ipfs-docs Nov 9, 2021
@ipfs ipfs deleted a comment from welcome bot Nov 9, 2021
@lidel lidel added the need/triage Needs initial labeling and prioritization label Nov 9, 2021
@Stebalien
Copy link
Member

This is already possible by sending a request to ipfs dht put. However:

  1. This won't (and can't) republish records when they expire.
  2. You'll need to manually construct your IPNS record.

@dogada
Copy link
Author

dogada commented Nov 16, 2021

Thanks, interesting. Manually construct your IPNS record is ok. I didn't understand however why I can't republish the record? Can I manually call ipfs dht put with new timestamp every 12 hours for example?

@aschmahmann
Copy link
Contributor

aschmahmann commented Nov 16, 2021

I didn't understand however why I can't republish the record? Can I manually call ipfs dht put

Sort of

with new timestamp every 12 hours for example?

No


@dogada you can do it situationally. If the reason you are republishing your record is because the DHT servers have a maximum duration they'll keep your record for (currently 36hr) then you can just call ipfs dht put with the record again. However, if you are republishing because the lifetime of the record expired then you need to create a new signed record.

While you could have a very large record lifetime there are some tradeoffs involved in that in a non-consensus network it's possible a user could end up with an older record and think it's the latest. For example, if nobody publishes your record into the DHT for a week, then someone publishes a record from last year that still has a valid lifetime new users might end up seeing the record from last year. How the tradeoffs are balanced here is pretty situational.

@dogada
Copy link
Author

dogada commented Nov 18, 2021

Thanks @aschmahmann, I understand the tradeoffs and the reason for the maximum lifetime of the record, but what is recommended approach to link a permanent name to the actual CID. Say, I can update my blog, stored in IPFS, once a week, and hence I need to change IPNS binding each time I obtain new blog's CID. Then I need to republish IPNS record in DHT every 36 hours? From end-user perspective it may be easy to use DNSLink and point domain to a CID directly (/ipfs/$CID) than to IPNS link (/ipns/$HASH). What do you think?

@T0admomo
Copy link

T0admomo commented Jan 31, 2022

The combined limitation of both forced 36 hours renewal and requiring the original publisher be online in order to renew creates a bottleneck on the usefulness of IPNS in my opinion, and clearly creates a single point of failure. Has the possibility been considered of configuring an approved peer list of signers who can also renew the IPNS record in case the original publisher is offline? Or can this otherwise be circumvented by running ipfs-clusters?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
need/triage Needs initial labeling and prioritization
Projects
None yet
Development

No branches or pull requests

6 participants