Fix potential username collisions when checking app status

This commit is contained in:
liaralabs 2020-03-12 11:19:17 -07:00
parent 376d60a453
commit 16c4197122

View file

@ -135,7 +135,8 @@ def apps_status(username):
def is_process_running(procs, username, application):
result = False
for p in procs:
if username.lower() in str(p).lower():
p = p.decode('utf-8').split()
if username.lower() == str(p[0]).lower():
if application.lower() in str(p).lower():
result = True
return result