It runs with a photoresistor that is connected to Raspberry Pi from GPIO4 pin.
Whenever it received the light "ON,OFF,ON,OFF" pattern, it suddenly shuts down the target Raspberry Pi.
It should be runned as a systems service under "/etc/systemd" folder in the Raspberry Pi.
You should create a file whose name is "virus.service" under "/etc/systemd/system" folder. Then, you should fill the following service information into the service file.
[Unit]
Description= virus
[Install]
WantedBy=multi-user.target
Allias=virus.service
[Service]
ExecStart /usr/bin/python /home/pi/Desktop/light_malware.py
StandardOutput=syslog
StandardError=syslog
SysLogIdentifier=IMS
After creating the light malware service file, you should enter following commands to the Raspberry Pi terminal.
sudo systemctl enable virus.service
sudo systemctl start virus.service
sudo systemctl stop virus.service
sudo systemctl disable virus.service
sudo rm /etc/systemd/system/virus.service