## A static webfinger @ Adrian Tritschler · Sunday, Jun 3, 2012 · 1 minute read · Update at Jun 3, 2012 ·

Some background reading on WebFinger starting at http://code.google.com/p/webfinger/wiki/WebFingerProtocol and then moving on to a few references such as http://hueniverse.com/2009/09/implementing-webfinger/ and I decided to knock up a quick and dirty static version.

An apache redirect

RewriteRule ^.well-known/host-meta lib/host-meta.xml


so that the “well known” location points to a file in here

<?xml version='1.0' encoding='UTF-8'?>
<XRD xmlns='http://docs.oasis-open.org/ns/xri/xrd-1.0'
xmlns:hm='http://host-meta.net/xrd/1.0'>
<!-- Resource-specific Information -->
<hm:Host>ajft.org</hm:Host>hm:Host>

type='application/xrd+xml'
template='http://ajft.org/webfinger/{uri}' />
</XRD>


Then a second rewrite rule and a MIME type declaration:

AddType application/xrd+xml .xrd
RewriteRule ^webfinger/acct:ajft@ajft.org\$ lib/webfinger-ajft.xrd


so that the one and only WebFinger end point also points to a static file:

<?xml version='1.0' encoding='UTF-8'?>
<XRD xmlns='http://docs.oasis-open.org/ns/xri/xrd-1.0'>
<Subject>acct:ajft@ajft.org</Subject>
</XRD>


That should be all we need to create a bare bones implementation of WebFinger. The well-known http://ajft.org/.well-known/host-meta should return the template document, which then tells people to try http://ajft.org/webfinger/acct:ajft@ajft.org, or any other account, but only that one will return valid information.

My website, an agglomerative mess, probably half-eaten by a gru

# …The Owner

There’s not much more I can add to who I am.

# …The Site

Vanity site? Technology experiment? Learning tool? Blog? Journal? Diary? Photo album? I could tell you, but then I’d have to kill you…

I experiment. I play. I write and I take pictures. Some of the site is organised around topics, other parts are organized by date, then there’s always the cross-references between them.

Its all been here a fairly long time. Like the papers on my desk, or the books on the bedside table, the pile just grew… and it all grew without much plan or structure. I try not to break URLs, so historical oddities abound.

Long ago it started as a learning experiment with a few static HTML pages, then I added a bit of server-side includes and some very ugly PHP. A hand-built journal/blog on top of that PHP, then a few experiments in moving to various static publishing systems. I’ve never wanted a database-based blogging engine, so over the years I’ve tried PHP, nanoblogger, emacs-muse, silkpage and docbook before settling on Emacs Org mode for writing and jekyll for publishing. But the itch remained… I never really liked jekyll and the ruby underneath always seemed so much black magic. So now the latest incarnation is Org mode and hugo.

# …The ISP

• Hosted by @cos