0

Before anything, please excuse my clear confusion over what is probably a non-issue. Computer security is definitely not my expertise, so any and all help is appreciated.

I recently installed a Python package through pip that does not have many github stars and from a relatively unknown author (https://github.com/realiti4/pip-upgrade). Through its execution I got an user access error, so I ran the command on a CMD with admin privileges to try to fix the problem. I then realized I just ran code from an unknown source with admin privileges, which really is not a good idea.

Because I am not proficient enough at programming to really understand the github source, I can't tell if the code is "clean" or if it might have done something to my computer. Please note I have nothing against this specific package or its author; if anything, their package seems very useful, which is why I tried to use it in the first place. The burden lies on me for messing with things that I do not understand.

My question is: is there anything I can do to check that my computer isn't compromised (e.g., would a whole-system scan with Windows Defender be enough)? I am almost certain that the package I mentioned is safe and I'm making a storm out of a glass of water, but I'm worried since I would not be able to identify any suspicious source code by looking at it due to my lack of knowledge.

In summary: I'd be thankful for any indication that the package is indeed safe, or for a method by which I may check I'm not compromised. Furthermore, any advice on "staying safe" when installing and using python packages is appreciated.

7
  • Your Python maybe installed in admin directory instead of user directory so it asked admin privileges to update global python modules.
    – defalt
    Sep 16, 2022 at 9:54
  • Python is installed in a folder in the root of my C drive, so even though it's not in a user directory I don't think that is the issue. Also, the package didn't really ask me to run as admin; I ran it as admin to troubleshoot the issue. Sep 16, 2022 at 9:57
  • I'm not worried about getting the package to work, but rather knowing if the package is safe to use and would not cause issues even if executed as an admin as I did Sep 16, 2022 at 9:58
  • I don't see any malicious activity with it. It just updates modules all at once like poetry update does.
    – defalt
    Sep 16, 2022 at 10:20
  • 1
    We can't assess or analyse code or a library. So, the question would boil down to "how can I check if my system is compromised?" The general answer to that is to run an anti-virus on the system by booting it from an external drive.
    – schroeder
    Sep 16, 2022 at 10:34

1 Answer 1

0

There is a cool tool called loki. It is a IoC scanner (indicator of compromise) that could help you, to determine if you are compromised or not. It is more responsible then a antivirus scanner.

I don't see any malicious activity in your python program.

2
  • What do you mean by "more responsible" in this context? Sep 18, 2022 at 22:58
  • Loki is built only to determine whether you are compromised or not. It checks various parameters like hashes and file contents and others. Therefore, it is more responsible and accurate than some virus scanners.
    – w3ich3rt
    Sep 19, 2022 at 6:14

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .