advanced use cases for webfinger

50 visualizzazioni
Passa al primo messaggio da leggere

Melvin Carvalho

da leggere,
18 ago 2013, 19:24:3218/08/13
a webf...@googlegroups.com
Hi All

I have a couple of use cases that I'm unsure webfinger can easily handle, so I propose a possible solution.

1. Unordered Friends list

I want to add a list of friend links to my webfinger record.  The webfinger spec requires that links are ordered by preference.  To be honest, I barely would know how to order my friends in real life, let alone on a computer, so I dont think webfinger can easily handle this case. 

2. Nested Properties

I've seen quite a few people use webfinger with nesting.  Ie links and properties inside other links and properties.  While JSON allows this, the spec seems to suggest that the key value pairs in webfinger associated with a subject are at most one level deep.

For example I would wish to put in my public key, which has a modulus and an exponent, associated with my account.  But it would seem that would be difficult or impossible to express in JRD.


Solution

If you dont require nesting or unordered lists, JRD could be a good fit.   But if you need either of these two use cases to additionally support another serialization allows these features (e.g. JSON-LD). 

Paul E. Jones

da leggere,
19 ago 2013, 12:37:2319/08/13
a webf...@googlegroups.com

Melvin,

 

webFinger is intended to provide information about a URI and it does that through a deliberately simple set of properties and links.  The intent is that if there is a lot of information to convey, then WebFinger should just be used to point to that information.

 

I would not suggest putting an entire friend list in WebFinger.  Rather, if you wish to share the list of friends you have, there should be a single link relation of type “portable-contacts” (or whatever) with a pointer to some document that contains that information (e.g., a Portable Contacts document http://portablecontacts.net/draft-schema.html).

 

The other example has to do with public key information.  That example sounds like it could be done with WebFinger, but I’d have to see the details.  Even if it can, it might still be better to just use WebFinger to point to a file.  Let’s say, for example, that I’d like to share my OpenPGP public key via WebFinger.  Perhaps the best way would be to have a link of type “OpenPGP” with an href pointing to the public key file.

 

Paul

 

--
 
---
You received this message because you are subscribed to the Google Groups "WebFinger" group.
To unsubscribe from this group and stop receiving emails from it, send an email to webfinger+...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Melvin Carvalho

da leggere,
19 ago 2013, 12:52:0519/08/13
a webf...@googlegroups.com
On 19 August 2013 18:37, Paul E. Jones <pau...@packetizer.com> wrote:

Melvin,

 

webFinger is intended to provide information about a URI and it does that through a deliberately simple set of properties and links.  The intent is that if there is a lot of information to convey, then WebFinger should just be used to point to that information.

 

I would not suggest putting an entire friend list in WebFinger.  Rather, if you wish to share the list of friends you have, there should be a single link relation of type “portable-contacts” (or whatever) with a pointer to some document that contains that information (e.g., a Portable Contacts document http://portablecontacts.net/draft-schema.html).


Thanks for the clarification, this is as I suspected.  I havent looked at PoCo lately, maybe this a viable choice.
 

 

The other example has to do with public key information.  That example sounds like it could be done with WebFinger, but I’d have to see the details.  Even if it can, it might still be better to just use WebFinger to point to a file.  Let’s say, for example, that I’d like to share my OpenPGP public key via WebFinger.  Perhaps the best way would be to have a link of type “OpenPGP” with an href pointing to the public key file.


I was using a public key to illustrate the idea of nested properties.  Eg  <#me> has-a <#key> has-a <#modulus>

I am seeing nested properties in the wild with webfinger already, for example Nick's JRD which follows the remoteStorage protocol:

http://silverbucket.github.io/webfinger.js/demo/

[[
{
  "subject": "acct:ni...@silverbucket.net",
  "links": [
    {
      "href": "https://storage.5apps.com/silverbucket",
      "rel": "remotestorage",
      "type": "https://www.w3.org/community/rww/wiki/read-write-web-00#simple",
      "properties": {
        "http://tools.ietf.org/html/rfc6749#section-4.2": "https://5apps.com/rs/oauth/silverbucket"
      }
    },
    {
      "rel": "http://webfinger.net/rel/avatar",
      "href": "https://www.silverbucket.net/img/avatar.png"
    },
    {
      "rel": "http://webfinger.net/rel/profile-page",
      "href": "https://silverbucket.net"
    },
    {
      "rel": "http://packetizer.com/rel/blog",
      "href": "http://blog.silverbucket.net"
    },
    {
      "rel": "http://schemas.google.com/g/2010#updates-from",
      "href": "https://twitter.com/slvrbckt"
    }
  ]
}

]]
 
As you can see we have a properties attribute *inside* a links attribute (what I call nesting).  While this is valid JSON, I think it would not be supported by JRD, hence an alternative approach would be better?

Paul E. Jones

da leggere,
19 ago 2013, 13:13:0319/08/13
a webf...@googlegroups.com

Melvin,

 

It is legal to have properties associated with specific array elements in the links array like this.  The below syntax is valid JRD syntax.  It looks pretty simple and is probably a proper use of the “properties”  member.

Melvin Carvalho

da leggere,
19 ago 2013, 13:59:3019/08/13
a webf...@googlegroups.com
On 19 August 2013 19:13, Paul E. Jones <pau...@packetizer.com> wrote:

Melvin,

 

It is legal to have properties associated with specific array elements in the links array like this.  The below syntax is valid JRD syntax.  It looks pretty simple and is probably a proper use of the “properties”  member.


Got it, thanks, so you can nest properties but not links...

Paul E. Jones

da leggere,
19 ago 2013, 15:23:0319/08/13
a webf...@googlegroups.com

Properties are just strings.  If they happen to have a URI inside, there is no means of indicating that.

Rispondi a tutti
Rispondi all'autore
Inoltra
0 nuovi messaggi