Redhat installing apache
ServerName sets the domains for which this virtual host serves content. To set multiple domains, add the ServerAlias parameter to the configuration and specify the additional domains separated with a space in this parameter. ErrorLog sets the path to the error log of the virtual host. Apache uses the first virtual host found in the configuration also for requests that do not match any domain set in the ServerName and ServerAlias parameters.
This also includes requests sent to the IP address of the server. Append a similar virtual host configuration for the example. Note that you must install the policycoreutils-python-utils package to run the restorecon command. The gssproxy service allows to implement privilege separation for the httpd server, which optimizes this process from the security point of view. This step sets permissions to , thus only the root user has access to the keytab file. The apache user does not. Restart and enable the gssproxy service:.
Reload the systemd configuration:. The server name must match the entry set in the Common Name field of the certificate. To configure this, add the ServerAliases parameter with corresponding names:. Set the paths to the private key, the server certificate, and the CA certificate:. For security reasons, configure that only the root user can access the private key file:.
If the private key was accessed by unauthorized users, revoke the certificate, create a new private key, and request a new certificate. Otherwise, the TLS connection is no longer secure. Open port in the local firewall:. If you protected the private key file with a password, you must enter this password each time when the httpd service starts. Follow the procedure if your environment requires to enable only specific TLS protocol versions, for example:.
For example, to enable only the TLSv1. Use the following command to verify that the server supports TLSv1. Use the following command to verify that the server does not support TLSv1. If the server does not support the protocol, the command returns an error:. By default, the Apache HTTP Server uses the system-wide crypto policy that defines safe default values, which are also compatible with recent browsers.
Follow the procedure if your environment requires specific ciphers. Use the nmap utility to display the supported ciphers:. Client certificate authentication enables administrators to allow only users who authenticate using a certificate to access resources on the web server. For example, in Firefox, set the security. For further details, see Transport Layer Security version 1.
The error indicates that the web server requires a client certificate authentication. Pass the client private key and certificate, as well as the CA certificate to curl to access the same URL with client authentication:. If the request succeeds, curl displays the index. This manual provides a detailed documentation of, for example:. To restrict access to a specific IP range, such as the Being a modular application, the httpd service is distributed along with a number of Dynamic Shared Objects DSO s , which can be dynamically loaded or unloaded at runtime as necessary.
After loading the module, restart the web server to reload the configuration. To create a new DSO module, make sure you have the httpd-devel package installed.
To do so, enter the following command as root :. This package contains the include files, the header files, and the APache eXtenSion apxs utility required to compile a module. If the build was successful, you should be able to load the module the same way as any other module that is distributed with the Apache HTTP Server.
To extract the private key, you must temporarily export the key to a PKCS 12 file:. Use the nickname of the certificate associated with the private key, to export the key to a PKCS 12 file:. Note that you must set a password on the PKCS 12 file. You need this password in the next step.
Follow Section 1. Chapter 1. See httpd. A new httpd-init. For more details on ListenFree , see the following table: Table 1. If any third-party modules are used, ensure they are compatible with a threaded MPM. If suexec is used, ensure user and group IDs meet the new minimums. Table 1. Procedure To start the httpd service, enter: systemctl start httpd To stop the httpd service, enter: systemctl stop httpd To restart the httpd service, enter: systemctl restart httpd.
Additional resources For further details about configuring Apache and adapting the service to your environment, refer to the Apache manual. For details about installing the manual, see Section 1. For details about using or adjusting the httpd systemd service, see the httpd. Configuring Apache name-based virtual hosts. Before the service is added to the cluster configuration, ensure that the Apache HTTP Server directories are not mounted.
Then, on one node, invoke the Cluster Configuration Tool to add the service, as follows. This example assumes a failover domain named httpd-domain was created for this service. Select the Resources tab and click Create a Resource. The Resources Configuration properties dialog box is displayed.
Select Script form the drop down menu. Click Create a Resource. In the Resource Configuration dialog, select File System from the drop-down menu. Enter the Name for the resource for example, httpd-content. Choose ext3 from the File System Type drop-down menu.
Choose IP Address from the drop-down menu. Make sure that the Monitor Link checkbox is left checked. Click Create a Service.
Type a Name for the service in the Add a Service dialog. In the Service Management dialog, select a Failover Domain from the drop-down menu or leave it as None. Click the Add a Shared Resource to this service button.
0コメント