Displaying 2 results from an estimated 2 matches for "rawsox".
2008 Mar 03
1
Unable open raw socket in CentOS 5 - SE Linux and kernel capability interaction?
...>
int
main(void)
{
	int fd = socket(PF_INET, SOCK_RAW, IPPROTO_TCP);
	if (-1 == fd)
	{
		printf("Failed to open raw socket: %d=%s\n", errno, strerror(errno));
	}
	else
	{
		printf("Socket opened successfully\n");
		close(fd);
	}
	return 0;
}
SElinux .te file
policy_module(rawsox,1.0.0)
########################################
# Declarations
type rawsox_t;
type rawsox_exec_t;
domain_type(rawsox_t)
domain_entry_file(rawsox_t, rawsox_exec_t)
domain_auto_trans(unconfined_t,rawsox_exec_t,rawsox_t)
########################################
# Rawsox local policy
# these two di...
2008 Mar 07
1
Unable open raw socket in CentOS 5 - SE Linux and kernelcapability interaction?
...no, 
>> strerror(errno));
>>     }
>>     else
>>     {
>>         printf("Socket opened successfully\n");
>>         close(fd);
>>     }
>>     return 0;
>> }
>>
>>
>> SElinux .te file
>>
>> policy_module(rawsox,1.0.0)
>>
>> ########################################
>> # Declarations
>>
>> type rawsox_t;
>> type rawsox_exec_t;
>> domain_type(rawsox_t)
>> domain_entry_file(rawsox_t, rawsox_exec_t)
>> domain_auto_trans(unconfined_t,rawsox_exec_t,rawsox_t)...