selinux is blocking port 8332. Now I want to unlock it. But what porttype do I have to use for an rpc connection? This is the message I get:

SELinux is preventing /usr/sbin/php-fpm from name_connect access on the tcp_socket port 8332.

*****  Plugin connect_ports (85.9 confidence) suggests   *********************

If you want to allow /usr/sbin/php-fpm to connect to network port 8332
Then you need to modify the port type.
# semanage port -a -t PORT_TYPE -p tcp 8332
    waarin PORT_TYPE een van de volgende is: dns_port_t, dnssec_port_t, http_port_t, kerberos_port_t, ocsp_port_t.

After some searching I finally found the answer. Just run this command:

sudo setsebool -P httpd_can_network_connect 1

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.