Ipns name resolution

This branch is not yet complete, but before i move forward, the name resolution code (in namesys) needs some critiquing. There are also a decent number of bugfixes in this branch that i ran into while trying to get the code to a point where i could test ipns.
Yeah. Thinking either

```
type NSResolver interface {
  CanResolve(name string)
  Resolve(name string) (string, error)
}
```

but since Resolve has to perform the same check anyway (ie. return an error if it can't resolve the name), might as well reduce the API footprint:

```
type NSResolver interface {
  Resolve(name string) (string, error)
}
```