MCPcopy Create free account
hub / github.com/cppla/ServerStatus / tupd

Function tupd

clients/client-linux.py:154–167  ·  view source on GitHub ↗

tcp, udp, process, thread count: for view ddcc attack , then send warning :return:

()

Source from the content-addressed store, hash-verified

152 return NET_IN, NET_OUT
153
154def tupd():
155 '''
156 tcp, udp, process, thread count: for view ddcc attack , then send warning
157 :return:
158 '''
159 s = subprocess.check_output("ss -t|wc -l", shell=True)
160 t = int(s[:-1])-1
161 s = subprocess.check_output("ss -u|wc -l", shell=True)
162 u = int(s[:-1])-1
163 s = subprocess.check_output("ps -ef|wc -l", shell=True)
164 p = int(s[:-1])-2
165 s = subprocess.check_output("ps -eLf|wc -l", shell=True)
166 d = int(s[:-1])-2
167 return t,u,p,d
168
169def get_network(ip_version):
170 if(ip_version == 4):

Callers 1

client-linux.pyFile · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected