Definición
La System call chmod()
cambia los bits de modos de acceso
#include <sys/stat.h>
int chmod(const char *pathname, mode_t mode);
int fchmod(int fd, mode_t mode);
S_IRUSR (00400)
read by ownerS_IWUSR (00200)
write by ownerS_IXUSR (00100)
execute/search by owner (“search” applies for directories, and means that entries within the directory can be accessed)S_IRGRP (00040)
read by groupS_IWGRP (00020)
write by groupS_IXGRP (00010)
execute/search by groupS_IROTH (00004)
read by othersS_IWOTH (00002)
write by othersS_IXOTH (00001)
execute/search by others
La única diferencia entre ambas system calls es la forma en que se accede al Archivo en cuestión