summaryrefslogtreecommitdiff
path: root/ntor/ntor.go
diff options
context:
space:
mode:
Diffstat (limited to 'ntor/ntor.go')
-rw-r--r--ntor/ntor.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/ntor/ntor.go b/ntor/ntor.go
index 0744d20..eecf038 100644
--- a/ntor/ntor.go
+++ b/ntor/ntor.go
@@ -147,6 +147,10 @@ func NodeIDFromBase64(encoded string) (*NodeID, error) {
return NewNodeID(raw)
}
+// Bytes returns a pointer to the raw NodeID.
+func (id *NodeID) Bytes() *[NodeIDLength]byte {
+ return (*[NodeIDLength]byte)(id)
+}
// Base64 returns the Base64 representation of the NodeID.
func (id *NodeID) Base64() string {