Identifying non-package executables (Debian)

👉 Overview


👀 What ?

Identifying non-package executables in Debian relates to the process of distinguishing executables that are not part of the official Debian package management system. These executables can be potential security risks as they might not have been vetted through the Debian packaging system which ensures the software's integrity and security.

🧐 Why ?

This topic is vital for ensuring the security and integrity of a Debian system. Non-package executables can pose a security risk as they aren't subject to the rigorous vetting process of the Debian package management system. They might contain malicious code, or have vulnerabilities that have been patched in the official Debian packages. Understanding this topic can help system administrators and security professionals maintain the integrity and security of their Debian systems.

⛏️ How ?

To identify non-package executables in Debian, a tool like 'debsums' can be used. Debsums can verify the integrity of installed package files against MD5 checksums installed by the package, or generated from a .deb archive. Files that don't match any package are potentially suspicious and should be investigated further. To use debsums, first install it using the command: 'sudo apt-get install debsums'. Then use the command 'sudo debsums -ce' to check all executables not owned by any package.

⏳ When ?

Identifying non-package executables is an ongoing process that should be done regularly as part of system maintenance. It became a common practice with the development of package management systems which brought a structured approach to software installation, upgrades, and removal.

⚙️ Technical Explanations


When software is installed on a Debian system through its package management system, it undergoes a rigorous process to ensure its security and integrity. The details of the installed package, such as its name, version, and the files it installs, are then recorded in a database. This allows the system to keep track of all officially installed software and aids in maintaining the system's security.

However, not all executables on a Debian system come from the package management system. These are referred to as non-package executables. They could have been installed manually, through a third-party installer, or even by a malicious actor. Unlike package executables, these non-package executables aren't recorded in the Debian package database. This means they haven't been through the same vetting process, which can pose a potential security risk. They might contain malicious code or have vulnerabilities that have been patched in the official Debian packages.

To ensure the security and integrity of a Debian system, it's crucial to identify these non-package executables. This involves comparing the executables present on the system with the records in the Debian package database.

A tool like 'debsums' can be used to facilitate this process. 'Debsums' can verify the integrity of installed package files against MD5 checksums installed by the package or generated from a .deb archive. Files that don't match any package are potentially suspicious and should be investigated further. To use 'debsums', it first needs to be installed using the command: 'sudo apt-get install debsums'. Then the command 'sudo debsums -ce' can be used to check all executables not owned by any package.

While not all non-package executables are harmful, they should be thoroughly investigated. They could be completely benign and necessary for certain software to function, or they could be malicious or have unpatched vulnerabilities. By regularly identifying and evaluating non-package executables, system administrators and security professionals can greatly enhance the security and integrity of their Debian systems.

For instance, you suspect that there might be non-package executables on your Debian system. Here is a step-by-step guide to identifying and examining these executables:

  1. Install debsums: Start by installing the 'debsums' tool which will help in this process. Open your terminal and type the following command:
sudo apt-get install debsums

  1. Run debsums: After installation, run the following command to identify all executables not owned by any package:
sudo debsums -ce

The '-ce' option tells debsums to check only executables and report on those not owned by any package.

  1. Examine the output: If there are non-package executables on your system, they will be listed in the terminal. For example, you might see something like this:
/usr/local/bin/example_executable

This indicates that 'example_executable' in the '/usr/local/bin' directory is not owned by any package.

  1. Investigate the executable: You should then investigate why this executable is not part of any package. It could be a program that you manually installed, or it might be something potentially harmful. Use your best judgment and any available resources to determine the nature of the executable.
  2. Repeat the process: Regularly run this process to ensure the security and integrity of your Debian system.

Remember, non-package executables aren't necessarily harmful, but they should always be investigated to ensure the security of your system.

🖇️ Références


We use cookies

We use cookies to ensure you get the best experience on our website. For more information on how we use cookies, please see our cookie policy.