- return send_request(c, "%d %s %d.%d", ID, myself->connection->name,
- myself->connection->protocol_major, myself->connection->protocol_minor);
-}
-
-bool id_h(connection_t *c, char *request) {
- char name[MAX_STRING_SIZE];
-
- if(sscanf(request, "%*d " MAX_STRING " %d.%d", name, &c->protocol_major, &c->protocol_minor) < 2) {
- logger(LOG_ERR, "Got bad %s from %s (%s)", "ID", c->name,
- c->hostname);
- return false;
- }
-
- /* Check if this is a control connection */
-
- if(name[0] == '^' && !strcmp(name + 1, controlcookie)) {
- c->status.control = true;
- c->allow_request = CONTROL;
- c->last_ping_time = time(NULL) + 3600;
- return send_request(c, "%d %d %d", ACK, TINC_CTL_VERSION_CURRENT, getpid());
- }