ZPanel y Sentora en CentOS 6 x64
ZPanel, un panel de control de alojamiento web popular, se bifurcó en 2014 a un nuevo proyecto llamado Sentora. Aprende a instalar Sentora en tu servidor con este tutorial.
Linux capabilities are special attributes in the Linux kernel that grant processes and binary executables specific privileges that are normally reserved for processes whose effective user ID is 0 (The root user, and only the root user, has UID 0).
This article will explain some of the available capabilities, their uses and how to set and remove them. Please note that setting capabilities on executables has the potential to compromise the security of your system. As such, you should consider testing on a non-production system before implementing capabilities in production.
Essentially, the goal of capabilities is to divide the power of 'root' into specific privileges, so that if a process or binary that has one or more capability is exploited, the potential damage is limited when compared to the same process running as root.
Capabilities can be set on processes and executable files. A process resulting from the execution of a file can gain the capabilities of that file.
The capabilities implemented on Linux are numerous, and many have been added since their original release. Some of them are as follows:
CAP_CHOWN: Make changes to the User ID and Group ID of filesCAP_DAC_OVERRIDE: Override DAC (Discretionary Access Control). For example, vto bypass read/write/execute permission checks.CAP_KILL: Bypass permission checks for sending signals to processes.CAP_SYS_NICE: Raise the niceness of processes (An explanation of niceness can be found here)CAP_SYS_TIME: Set the system and real-time hardware clockFor the full list, run man 7 capabilities.
Capabilities are assigned in sets, namely "permitted", "inheritable", "effective" and "ambient" for threads, and "permitted", "inheritable" and "effective" for files. These sets define different complex behaviors, their full explanation is beyond the scope of this article.
When setting capabilities on file, we will almost always use "permitted" and "effective", for example CAP_DAC_OVERRIDE+ep. Notice the +ep, which denotes the aforementioned sets.
There are two main tools, getcap and setcap which can respectively view and set these attributes.
libcap2-bin package, which can be installed with: apt install libcap2-binlibcap package is needed: yum install libcaplibcap as well: pacman -S libcapTo view if a file has any capability set, you can simply run getcap /full/path/to/binary, for example:
root@demo:~# getcap /usr/bin/ping
/usr/bin/ping = cap_net_raw+ep
root@demo:~# getcap /usr/bin/rcp
/usr/bin/rcp = cap_net_bind_service+ep
If you'd like to find out which capabilities are already set on your system, you can search your whole file-system recursively with the following command:
getcap -r /
Due to the fact that virtual file-systems (such as /proc) do not support these operations, the command above will produce thousands of errors, so for a cleaner output use the following:
getcap -r / 2>/dev/null
To set a particular capability on a file, use setcap "capability_string" /path/to/file.
To remove all capabilities from a file, use setcap -r /path/to/file.
For demonstration we'll create a blank file in the current directory, give it a capability, and remove it. Start with the following:
root@demo:~# touch testfile
root@demo:~# getcap testfile
The second command produces no output, meaning this file does not have any capability.
Next, set a capability for the file:
root@demo:~# setcap "CAP_CHOWN+ep" testfile
root@demo:~# getcap testfile
testfile = cap_chown+ep
"CAP_CHOWN+ep" was used as an example, but any other can be assigned in this manner.
Now, remove all capabilities from testfile:
root@demo:~# setcap -r testfile
root@demo:~# getcap testfile
Again, there will be no output, because "CAP_CHOWN+ep" was removed.
Capabilities have many potential uses and can help to tighten the security of your systems. If you use the SUID bit on your executables, consider replacing it with the specific capability needed.
ZPanel, un panel de control de alojamiento web popular, se bifurcó en 2014 a un nuevo proyecto llamado Sentora. Aprende a instalar Sentora en tu servidor con este tutorial.
Aprende cómo instalar Vtiger CRM, una aplicación de gestión de relaciones con el cliente, en CentOS 7 para aumentar tus ventas y mejorar el servicio al cliente.
Esta guía completa le mostrará cómo configurar un servidor Counter-Strike 1.6 en Linux, optimizando el rendimiento y la seguridad para el mejor juego. Aprende los pasos más recientes aquí.
Los ataques de ransomware van en aumento, pero ¿puede la IA ayudar a lidiar con el último virus informático? ¿Es la IA la respuesta? Lea aquí, sepa que la IA es una bendición o una perdición
ReactOS, un sistema operativo de código abierto y gratuito, está aquí con la última versión. ¿Puede satisfacer las necesidades de los usuarios de Windows de hoy en día y acabar con Microsoft? Averigüemos más sobre este estilo antiguo, pero una experiencia de sistema operativo más nueva.
Whatsapp finalmente lanzó la aplicación de escritorio para usuarios de Mac y Windows. Ahora puede acceder a Whatsapp desde Windows o Mac fácilmente. Disponible para Windows 8+ y Mac OS 10.9+
Lea esto para saber cómo la Inteligencia Artificial se está volviendo popular entre las empresas de pequeña escala y cómo está aumentando las probabilidades de hacerlas crecer y dar ventaja a sus competidores.
Recientemente, Apple lanzó macOS Catalina 10.15.4, una actualización complementaria para solucionar problemas, pero parece que la actualización está causando más problemas que conducen al bloqueo de las máquinas Mac. Lee este artículo para obtener más información
13 Herramientas comerciales de extracción de datos de Big Data
Nuestra computadora almacena todos los datos de una manera organizada conocida como sistema de archivos de diario. Es un método eficiente que permite a la computadora buscar y mostrar archivos tan pronto como presiona buscar.