Last modified: June 11, 2024

This article is written in: 🇺🇸

Utilities

These notes discuss various tools that can be used on Linux systems for tasks such as taking screenshots, recording screens, preparing bootable sticks, and detecting malware. It provides brief explanations of each tool and includes installation and usage instructions.

Taking Screenshots with Scrot

Scrot is a command-line utility for taking screenshots in Linux. It allows you to capture the entire screen, a specific window, or a selected area of the screen. Scrot is available in most Linux distributions, and you can install it using the package manager of your distribution.

To take a screenshot of the entire screen, use the following command:

scrot screenshot.png

This will save the screenshot as a PNG image in the current working directory. If you want to specify a different directory or file name, use the -f option followed by the path and file name of your choice:

scrot -f /path/to/screenshot.png

To take a screenshot of a specific window, use the -u option followed by the window title or ID:

scrot -u "Window Title" screenshot.png

To take a screenshot of a selected area of the screen, use the -s option:

scrot -s screenshot.png

This will allow you to draw a rectangle around the area you want to capture using the mouse.

Scrot also supports a number of additional options, such as -b to include window borders in the screenshot, -d to specify a delay before taking the screenshot, and -e to execute a command after the screenshot is taken. For example, the following command will take a screenshot of the current window with borders, wait for 3 seconds, and then save the screenshot to the Desktop:

scrot -b -d 3 screenshot.png -e 'mv $f ~/Desktop/'

Recording the Screen with Vokoscreen

Vokoscreen is a graphical tool for recording screencasts in Linux. It allows you to capture the entire screen, a specific window, or a selected area of the screen, and also supports the capture of audio and webcam video.

To install Vokoscreen on a Debian-based system, use the following command:

apt install vokoscreen

To start the program, simply run the vokoscreenNG command. This will open the Vokoscreen window, which provides a number of options for configuring the screen recording.

Screenshot from 2022-09-21 11-15-03

To start the recording, click on the "Start" button and select the area of the screen you want to capture. You can also choose to record audio and webcam video, as well as specify a file name and location for the recording. When you are finished, click on the "Stop" button to end the recording.

Preparing a Bootable USB Stick with USBImager

USBImager is a graphical utility for creating bootable USB sticks in Linux. It allows you to write an image file to a USB drive, making it possible to boot a computer from the USB drive.

Screenshot from 2022-09-06 22-47-32

Malware Detection with Maldet

One tool that can be used for malware detection is Maldet (short for Linux Malware Detect). Maldet is an open-source antivirus and malware scanning tool that uses a combination of signature-based and heuristic-based detection methods to identify and remove malware. It is specifically designed to detect and remove malware that targets Linux systems, and is regularly updated with the latest malware definitions.

Installation

To install Maldet on a Debian-based system, use the following commands:

wget http://www.rfxn.com/downloads/maldetect-current.tar.gz
tar xvfvz maldetect-current.tar.gz
cd maldetect-2.1.1 && sudo ./install.sh

This will download and extract the latest version of Maldet, and then run the installation script to install the software on the system.

Scanning for malware

To scan for malware on a Linux system using Maldet, use the following command:

maldet --scan-all /path/to/directory

Replace /path/to/directory with the path of the directory you want to scan. You can also use the --scan-all flag to scan the entire system.

For example, to scan the home directory of the current user, use the following command:

maldet --scan-all ~

The scan may take some time, depending on the size of the directory and the number of files it contains. When the scan is complete, Maldet will output a report ID, which can be used to view the scan report and take further action on any infected files that were detected.

Viewing the scan report

To view the scan report for a particular scan, use the following command:

maldet --report ID

Replace ID with the report ID of the scan you want to view. The report will show a list of all the files that were scanned, along with any infected files that were detected.

Quarantining infected files

If Maldet detects any infected files during a scan, you can use the following command to quarantine them:

maldet -q ID

Replace ID with the report ID of the scan you want to quarantine the infected files for. This will move the infected files to a quarantine directory, where they can be safely removed or further examined.

It is important to regularly scan for malware and take appropriate action to prevent it from infecting your system. Maldet is a powerful tool that can help you do this effectively and efficiently on Linux systems.

Table of Contents

  1. Utilities
  2. Taking Screenshots with Scrot
  3. Recording the Screen with Vokoscreen
  4. Preparing a Bootable USB Stick with USBImager
  5. Malware Detection with Maldet
    1. Installation
    2. Scanning for malware
    3. Viewing the scan report
    4. Quarantining infected files