package Protocol.Data.AuthHiddenService;
import "ControlChannel.proto";

extend Control.OpenChannel {
    optional bytes client_cookie = 7200;    // 16 random bytes
}

extend Control.ChannelResult {
    optional bytes server_cookie = 7200;      // 16 random bytes
}

message Packet {
    optional Proof proof = 1;
    optional Result result = 2;
}

message Proof {
    optional bytes public_key = 1;      // DER encoded public key
    optional bytes signature = 2;       // RSA signature
}

message Result {
    required bool accepted = 1;
    optional bool is_known_contact = 2;
}
