Re: How can I protect a service by SELinux?

Lukas Vrabec <[email protected]>
Newsgroups gmane.linux.redhat.fedora.selinux
Organization Red Hat, Inc.
Message-ID <[email protected]>
Hi Jason,

For "vsftpd" service we have ftpd_t SELinux policy by default shipped in
distribution SELinux policy on all currently supported Fedoras.

To confirm that vsftpd is confined by SELinux you could execute:

# ps -efZ | grep vsftpd
system_u:system_r:ftpd_t:s0-s0:c0.c1023 root 1109  1  0 08:39 ?
00:00:00 /usr/sbin/vsftpd /etc/vsftpd/vsftpd.conf
unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 root 1112 919  0
08:39 pts/0 00:00:00 grep --color=auto vsftpd

Please see that vsftpd with pid (in my case) 1109 is running under
"system_u:system_r:ftpd_t:s0-s0:c0.c1023" where the important part is
"ftpd_t". So this process is confined by SELinux and ftpd policy is used.

I tried to start "vsftpd" on my Fedora 30 system and service started
without any issue with SELinux in enforcing state.

Could you please try to start vsftpd:
# systemctl start vsftpd

and then attach output of:
# ausearch -m AVC -ts boot

Thanks,
Lukas.

On 8/12/19 7:47 AM, Jason Long wrote:
> Hello,
> I installed "vsftpd" service, but by default SELinux blocked it. I
> changed SELinux configuration by "setsebool -P ftpd_full_access 1", but
> I guess its mean that SELinux can't protect my "vsftpd" service. How can
> I use "vsftpd" service with SELinux enabled?
> 
> Thanks.
> 
> _______________________________________________
> selinux mailing list -- [email protected]
> To unsubscribe send an email to [email protected]
> Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
> List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
> List Archives: https://lists.fedoraproject.org/archives/list/[email protected]
> 


-- 
Lukas Vrabec
Senior Software Engineer, Security Technologies
Red Hat, Inc.

_______________________________________________
selinux mailing list -- [email protected]
To unsubscribe send an email to [email protected]
Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/[email protected]
signature.asc (application/pgp-signature, 488 B)
-----BEGIN PGP SIGNATURE-----

iQEzBAEBCAAdFiEE3wrP3ArXoyYgAS7LRyAaxC8pzgYFAl1RZHQACgkQRyAaxC8p
zgZLYAf/YXkZ6m20LSD1wZyN4ON/nUb3Aa1fkxY0OA318N++Q7OXa5OjH1If9Ond
k7iTe7PNtYkWFRhMLrv/kV27WoYW2LhKETDNrPVQbuklladyCOda3W/bb3qJ7TXf
NBie6vZJ2/v5DsDX4+1Hsefi+bhbeqr6td4HmVYt9Sun5/eU8fw/um0Aa1WP/gRE
vI+QkS2rmVem7kVTE2NQ6PPm4Wgx87Nk7WXAIE4SI/ESP4+qu6jscum+2VKS1wJb
Dj7dMCN2ZQJkNF0C2BF6jIiT0TXJWF0oKaRdyxyLjg4IChUhY/use/4Tz3rM7upS
PDqrhyToxQmXF3dAqiKUAbfb8DQ9eg==
=hP2r
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.