mirror of https://github.com/M66B/NetGuard.git
Native FIN hack
This commit is contained in:
parent
7a41f35e74
commit
b71e675e82
|
@ -939,6 +939,14 @@ void handle_tcp(JNIEnv *env, jobject instance, const struct arguments *args,
|
||||||
cur->remote_seq - cur->remote_start,
|
cur->remote_seq - cur->remote_start,
|
||||||
ntohl(tcphdr->ack_seq) - cur->local_start,
|
ntohl(tcphdr->ack_seq) - cur->local_start,
|
||||||
cur->local_seq - cur->local_start);
|
cur->local_seq - cur->local_start);
|
||||||
|
// TODO hack
|
||||||
|
if (cur->state == TCP_FIN_WAIT1) {
|
||||||
|
__android_log_print(ANDROID_LOG_ERROR, TAG, "FIN hack");
|
||||||
|
if (writeTCP(cur, NULL, 0, 1, 0, 0, 0, args->tun) < 0) // ACK
|
||||||
|
__android_log_print(ANDROID_LOG_ERROR, TAG,
|
||||||
|
"write ACK error %d: %s",
|
||||||
|
errno, strerror((errno)));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue