Socket connection verification
Disclosed is a method and apparatus for verifying socket connections. The method includes receiving a socket connection request and determining a process executable that initiated the socket connection request. The method further includes determining, by a processing device, whether verification data associated with the process executable corresponds to expected verification data of the process executable. Finally, the method includes in response to the verification data corresponding to the expected verification data, permitting a socket connection corresponding to the socket connection request.
1 . A method comprising:
receiving, at a second application executed by a processing device, a socket connection request to connect a first application executed by the processing device to the second application;
determining, by the processing device, a process executable that initiated the socket connection request, wherein the process executable operates within a local process or software process within the first application;
determining, by the processing device, whether verification data associated with the process executable corresponds to expected verification data of the process executable; and
in response to the verification data corresponding to the expected verification data, permitting, by the processing device, a socket connection corresponding to the socket connection request and the socket connection between the first application executed by the processing device and the second application executed by the processing device.
2 . The method of claim 1 , further comprising in response to the verification data not corresponding to the expected verification data, terminating the socket connection corresponding to the socket connection request.
3 . The method of claim 1 , wherein the verification data includes a certificate or signature that validates that the process executable is authentic.
4 . The method of claim 3 , wherein the expected verification data includes a predefined list of one or more known certificates or known signatures, each associated with a verified process executable, and wherein determining whether the verification data corresponds to the expected verification data includes determining whether the certificate or signature is on the predefined list of one or more known certificates or known signatures.
5 . The method of claim 1 , wherein the process executable comprises a first process executable, the verification data comprises first verification data, the expected verification data comprises first expected verification data, the socket connection request comprises a first socket connection request, the socket connection comprises a first socket connection, and the method further comprises:
determining whether a second process executable that initiated a second socket connection request includes second verification data; and
in response to the second process executable not having the second verification data, terminating the second socket connection corresponding to the second socket connection request; and
in response to the second process executable having the second verification data, extracting the second verification data and comparing the second verification data to second expected verification data to determine whether the second verification data associated with the second process executable corresponds to the second expected verification data of the second process executable.
6 . The method of claim 1 , further comprising extracting the verification data of the process executable and storing the verification data in memory and associating the stored verification data with the socket connection.
7 . The method of claim 1 , further comprising filtering traffic communicated across the socket connection based on the verification data.
8 . An apparatus comprising:
a memory to store expected verification data of a process executable; and
a processing device operatively coupled to the memory to:
execute a first application;
execute a second application;
receive, at the second application, a socket connection request to connect the first application to the second application;
determine the process executable that initiated the socket connection request, wherein the process executable operates within a local process or software process within the first application;
determine whether verification data associated with the process executable corresponds to the expected verification data of the process executable; and
in response to the verification data corresponding to the expected verification data, permit a socket connection corresponding to the socket connection request and the socket connection between the first application and the second application.
9 . The apparatus of claim 8 , wherein the processing device is further to, in response to the verification data not corresponding to the expected verification data, terminate the socket connection corresponding to the socket connection request.
10 . The apparatus of claim 8 , wherein the verification data includes a certificate or signature that validates that the process executable is authentic.
11 . The apparatus of claim 10 , wherein the expected verification data includes a predefined list of one or more known certificates or known signatures, each associated with a verified process executable, and wherein the processing device is further to determine whether the certificate or signature is on the predefined list of one or more known certificates or known signatures.
12 . The apparatus of claim 8 , wherein the process executable comprises a first process executable, the verification data comprises first verification data, the expected verification data comprises first expected verification data, the socket connection request comprises a first socket connection request, the socket connection comprises a first socket connection, and the processing device is further to:
determine whether a second process executable that initiated a second socket connection request includes second verification data; and
in response to the second process executable not having the second verification data, terminate the second socket connection corresponding to the second socket connection request; and
in response to the second process executable having the second verification data, extract the second verification data and compare the second verification data to second expected verification data to determine whether the second verification data associated with the second process executable corresponds to the second expected verification data of the second process executable.
13 . The apparatus of claim 8 , wherein the processing device is further to extract the verification data of the process executable and store the verification data in the memory and associate the stored verification data with the socket connection.
14 . The apparatus of claim 8 , wherein the processing device is further to filter traffic communicated across the socket connection based on the verification data.
15 . A non-transitory computer readable storage medium to store instructions executable by a processing device, cause the processing device to:
receive, at a second application executed by the processing device, a socket connection request to connect a first application executed by the processing device to the second application;
determine, by the processing device, a process executable that initiated the socket connection request, wherein the process executable operates within a local process or software process within the first application;
determine, by the processing device, whether verification data associated with the process executable corresponds to expected verification data of the process executable, the expected verification data stored in a memory operatively coupled to the processing device; and
in response to the verification data corresponding to the expected verification data, permit, by the processing device, a socket connection corresponding to the socket connection request and the socket connection between the first application executed by the processing device and the second application executed by the processing device.
16 . The non-transitory computer readable storage medium of claim 15 , wherein the processing device is further to, in response to the verification data not corresponding to the expected verification data, terminate the socket connection corresponding to the socket connection request.
17 . The non-transitory computer readable storage medium of claim 15 , wherein the verification data includes a certificate or signature that validates that the process executable is authentic.
18 . The non-transitory computer readable storage medium of claim 15 , wherein the processing device is further to filter traffic communicated across the socket connection based on the verification data.
19 . The non-transitory computer readable storage medium of claim 15 , wherein the process executable comprises a first process executable, the verification data comprises first verification data, the expected verification data comprises first expected verification data, the socket connection request comprises a first socket connection request, the socket connection comprises a first socket connection, and the processing device is further to;
determine whether a second process executable that initiated a second socket connection request includes second verification data; and
in response to the second process executable not having the second verification data, terminate the second socket connection corresponding to the second socket connection request; and
in response to the second process executable having the second verification data, extract the second verification data and compare the second verification data to second expected verification data to determine whether the second verification data associated with the second process executable corresponds to the second expected verification data of the second process executable.
20 . The non-transitory computer readable storage medium of claim 15 , wherein the processing device is further to extract the verification data of the process executable and store the verification data in the memory and associate the stored verification data with the socket connection.