You are reading content from Scuttlebutt
@Dominic %bZ46gmBkoNrrGZyIF6fBttnAY7KlY6r0XfyNcwXiVqU=.sha256
Re: %z28ZLyE7O

@mix this would be very simple to implement. there would be two parts: you'd need to have an sbot plugin that did something like:

sbot.auth.hook(function (fn, args) {
  var id = args[0] //the id which is trying to auth.
  var cb = args[1]
  checkIsWithInNHops(sbot.id, id, 2, function (err, within) {
     if(err || !isWithinHops) cb(new Error('stranger'))
     else {
       //fall through to other auth methods
       fn.apply(this, args)
     } 
  })
})

see also the same thing in the block plugin: https://github.com/ssbc/scuttlebot/blob/master/plugins/block.js#L57-L60

And then you'd need gossip to just not connect to pubs outside some hop radius.. We don't have a similarily simple way to change who you connect to there... but @piet is working on that and we mentioned this case.

Join Scuttlebutt now