0.6.1 • Published 2 years ago

hipr v0.6.1

Weekly downloads
-
License
ISC
Repository
github
Last release
2 years ago

hipr

A recursive resolver with middleware. Made for HIP-5 protocols.

CLI Usage

First install the hipr CLI

npm i -g hipr

Then to install middleware, like hipr-hyperzone and hipr-ipfs, run

hipr install hipr-hyperzone hipr-ipfs

Then boot up a server running the middleware with

hipr hipr-hyperzone:hipr-ipfs

By default, hipr will create a server that listens on port 53 and expects Bob wallet to be running a root server on port 9891, but you can override these defaults. For example, if you are running hsd or hnsd, you can use the authoritative server running (by default) on port 5349

hipr hipr-ipfs:hipr-hyperzone :5333 :5349

and listen on 127.0.0.1:5333.

Middleware should be :-separated as the first argument. Note that order may matter. In the above example, ipfs zone files will take priority over hyperzones.

Middleware

  • _hyperzone for resolving records from Hyperzones
  • _ipfs for resolving zone files from IPFS
  • _aliasing for trustless SLDs on Handshake
  • _eth for resolving from Ethereum via ENS (like .badass domains)

API

const { RecursiveServer } = require('hipr') 
const server = new RecursiveServer(options)

server.use(':data._:protocol.', async ({ data, protocol }, name, type) => {
  const zone = await fetchZone(protocol, data)
  return zone.resolve(name, type)
})

server.bind(53)
0.1.10

2 years ago

0.3.0

2 years ago

0.2.1

2 years ago

0.2.0

2 years ago

0.4.5

2 years ago

0.1.8

2 years ago

0.5.3

2 years ago

0.4.4

2 years ago

0.1.7

2 years ago

0.1.9

2 years ago

0.5.0

2 years ago

0.4.1

2 years ago

0.2.3

2 years ago

0.1.4

2 years ago

0.4.0

2 years ago

0.2.2

2 years ago

0.1.3

2 years ago

0.6.1

2 years ago

0.5.2

2 years ago

0.4.3

2 years ago

0.2.5

2 years ago

0.1.6

2 years ago

0.6.0

2 years ago

0.5.1

2 years ago

0.4.2

2 years ago

0.2.4

2 years ago

0.1.5

2 years ago

0.1.2

2 years ago

0.1.1

2 years ago

0.1.0

2 years ago