I have a small web server (CentOS 8) that runs a small php & mysql app. It also runs runs Nagios, BIND, and Postfix running as a secondary MX.
Everything seems to "work", and I've never noticed any problems. I'm able to load Nagios and the other php app over port 443. If I load the URLs over port http / port 80, Apache is configured to redirect to 443, and does that equally well.
However, selinux routinely logs the following AVC, indicating some issue on port 80:
time->Sat Dec 12 01:55:16 2020
type=AVC msg=audit(1607756116.608:1381369): avc: denied { name_connect } for pid=631936 comm="httpd" dest=80 scontext=system_u:system_r:httpd_t:s0 tcontext=system_u:object_r:http_port_t:s0 tclass=tcp_socket permissive=0
Looking at /var/log/httpd/error_log
, I see a corresponding Permission Denied for the same pid at the same time:
[Sat Dec 12 01:55:16.608941 2020] [core:warn] [pid 631936] (13)Permission denied: AH00056: connect to listener on [::]:80
Is there a way for me to track down, what exactly, Apache is trying to do that is getting blocked? As I mentioned, nothing seems to be broken, so I haven't tried to build a module to allow this. But I'd like to find the root cause of the AVC denied message here, and either:
- Allow it if it is harmless and should actually be allowed, OR
- Configure Apache to stop trying to do whatever it is that it is trying to do