Protocol - mangei/onion-routing GitHub Wiki

Every Request is a POST request to /request to the request target.

A full message would like the following:

encrypted Request:
{
    "payload": "<encrypted>",
}

decrypted Request:
{
    "payload": "<encryptedForNextNode>",
    "target": {
        "ip": "12.13.15.16",
        "port": "1718"
    },
    "service": {
        "url": "",
        "method": "",
        "data": "",
        "originator_public_key": ""
    }
}

Properties: ("payload", "target") XOR "service"

  • "payload" and "target" are information for the next node
  • "service" is information for the last node
  • each node has to check if "service" exists, otherwise "payload" and "target" must exist to forward the message

Originator Request Message:

{
	"payload": "<encryptedForEntryNode>"
}

Entry Node gets:

{
    "payload": "<encryptedForIntermediaryNode>",
    "target": {
        "ip": "12.13.15.16",
        "port": "1718"
    }
}

Entry Node sends to target:

{
	"payload": "<encryptedForIntermediaryNode>"
}

IntermediaryNode Node gets:

{
    "payload": "<encryptedForExitNode>",
    "target": {
        "ip": "12.13.15.16",
        "port": "1718"
    }
}

IntermediaryNode Node sends to target:

{
	"payload": "<encryptedForExitNode>"
}

Exit Node gets:

{
    "service": {
        "url": "",
        "method": "",
        "data": "",
        "originator_public_key": ""
    }
}
⚠️ **GitHub.com Fallback** ⚠️