Terminating a Connection

There are two ways to terminate a connection using modem commands: You can close the connection, or abort it. The two are not the same, when it comes to TCP connections.

Closing a Connection

The Close Connection (CC) instruction uses the proper termination sequence for TCP connections (FIN-ACK-FIN-ACK), and thus closes the connection in an orderly fashion. It is recommended to use this instruction.

Aborting a Connection

The Abort Connection (CA) instruction uses an RST packet to terminate a TCP connection. This is one-sided termination, and is usually less recommended.

Terminating UDP "Connections"

UDP is a connectionless protocol. The data "connection" the DS uses is merely a stream of packets, as described under UDP Data "Connections" . Thus, you can either abort or close such a "connection" -- the action performed is identical in both cases.

note_tip-wt

Remember! Commands are asynchronous -- just because you told the DS to terminate the connection, and it answered back "A" doesn't mean the connection has actually been terminated. See Finding Out Connection Status (X).