sk_vs = self.get_or_create_private_config("node.privkey", _make_key)
sk,vk_vs = keyutil.parse_privkey(sk_vs.strip())
self.write_config("node.pubkey", vk_vs+"\n")
- self._server_key = sk
+ self._node_key = sk
def _init_permutation_seed(self, ss):
seed = self.get_config_from_file("permutation-seed")
else:
# otherwise, we're free to use the more natural seed of our
# pubkey-based serverid
- vk_bytes = self._server_key.get_verifying_key_bytes()
+ vk_bytes = self._node_key.get_verifying_key_bytes()
seed = base32.b2a(vk_bytes)
self.write_config("permutation-seed", seed+"\n")
return seed.strip()
ann = {"anonymous-storage-FURL": furl,
"permutation-seed-base32": self._init_permutation_seed(ss),
}
- self.introducer_client.publish("storage", ann, self._server_key)
+ self.introducer_client.publish("storage", ann, self._node_key)
d.addCallback(_publish)
d.addErrback(log.err, facility="tahoe.init",
level=log.BAD, umid="aLGBKw")
f.close()
return int(seqnum)
- ic.publish("sA", {"key": "value1"}, c._server_key)
+ ic.publish("sA", {"key": "value1"}, c._node_key)
self.failUnlessEqual(read_seqnum(), 1)
self.failUnless("sA" in outbound)
self.failUnlessEqual(outbound["sA"]["seqnum"], 1)
# publishing a second service causes both services to be
# re-published, with the next higher sequence number
- ic.publish("sB", {"key": "value2"}, c._server_key)
+ ic.publish("sB", {"key": "value2"}, c._node_key)
self.failUnlessEqual(read_seqnum(), 2)
self.failUnless("sB" in outbound)
self.failUnlessEqual(outbound["sB"]["seqnum"], 2)